Esempio n. 1
0
        /// <summary>
        /// Instantiate a carrier of the specified protocol and passing in the signal initialization action.
        /// Often used for instantiating carriers passed as the Row parameter to the persistence receptor.
        /// </summary>
        protected ICarrier InstantiateCarrier(string protocol, Action <dynamic> initializeSignal)
        {
            ISemanticTypeStruct semStruct = rsys.SemanticTypeSystem.GetSemanticTypeStruct(protocol);
            dynamic             signal    = rsys.SemanticTypeSystem.Create(protocol);

            initializeSignal(signal);
            ICarrier rowCarrier = rsys.CreateInternalCarrier(semStruct, signal);

            return(rowCarrier);
        }
Esempio n. 2
0
        /// <summary>
        /// Creates the carrier (as an internal carrier, not exposed to the system) for containing
        /// our record information.  Assuming only an update, this sets only the EventDateTime field.
        /// </summary>
        protected ICarrier CreateRow()
        {
            // Create the type for the updated data.
            ISemanticTypeStruct rowProtocol = rsys.SemanticTypeSystem.GetSemanticTypeStruct("LastEventDateTime");
            dynamic             rowSignal   = rsys.SemanticTypeSystem.Create("LastEventDateTime");

            rowSignal.EventDateTime = LastEventTime;
            ICarrier rowCarrier = rsys.CreateInternalCarrier(rowProtocol, rowSignal);

            return(rowCarrier);
        }