Esempio n. 1
0
        protected ShipmentMethodTypeStateDeleted NewShipmentMethodTypeStateDeleted(long version, string commandId, string requesterId)
        {
            var stateEventId = new ShipmentMethodTypeEventId(_state.ShipmentMethodTypeId, version);
            var e            = NewShipmentMethodTypeStateDeleted(stateEventId);

            e.CommandId = commandId;

            e.CreatedBy = (string)requesterId;
            e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>();

            return(e);
        }
Esempio n. 2
0
        protected virtual IShipmentMethodTypeStateDeleted Map(IDeleteShipmentMethodType c)
        {
            var stateEventId = new ShipmentMethodTypeEventId(c.ShipmentMethodTypeId, c.Version);
            IShipmentMethodTypeStateDeleted e = NewShipmentMethodTypeStateDeleted(stateEventId);

            e.CommandId = c.CommandId;


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>();


            return(e);
        }
Esempio n. 3
0
        protected virtual IShipmentMethodTypeStateCreated Map(ICreateShipmentMethodType c)
        {
            var stateEventId = new ShipmentMethodTypeEventId(c.ShipmentMethodTypeId, c.Version);
            IShipmentMethodTypeStateCreated e = NewShipmentMethodTypeStateCreated(stateEventId);

            e.Description = c.Description;
            e.SequenceNum = c.SequenceNum;
            e.Active      = c.Active;
            e.CommandId   = c.CommandId;


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>();
            var version = c.Version;


            return(e);
        }
Esempio n. 4
0
        public override bool Equals(object obj)
        {
            if (Object.ReferenceEquals(this, obj))
            {
                return(true);
            }

            ShipmentMethodTypeEventId other = obj as ShipmentMethodTypeEventId;

            if (other == null)
            {
                return(false);
            }

            return(true &&
                   Object.Equals(this.ShipmentMethodTypeId, other.ShipmentMethodTypeId) &&
                   Object.Equals(this.Version, other.Version)
                   );
        }
Esempio n. 5
0
 protected ShipmentMethodTypeEventBase(ShipmentMethodTypeEventId stateEventId)
 {
     this.ShipmentMethodTypeEventId = stateEventId;
 }
Esempio n. 6
0
 public ShipmentMethodTypeStateDeleted(ShipmentMethodTypeEventId stateEventId) : base(stateEventId)
 {
 }
Esempio n. 7
0
 public ShipmentMethodTypeStateMergePatched(ShipmentMethodTypeEventId stateEventId) : base(stateEventId)
 {
 }
Esempio n. 8
0
 protected ShipmentMethodTypeStateEventBase(ShipmentMethodTypeEventId stateEventId) : base(stateEventId)
 {
 }
Esempio n. 9
0
 private ShipmentMethodTypeStateDeleted NewShipmentMethodTypeStateDeleted(ShipmentMethodTypeEventId stateEventId)
 {
     return(new ShipmentMethodTypeStateDeleted(stateEventId));
 }
Esempio n. 10
0
 private ShipmentMethodTypeStateMergePatched NewShipmentMethodTypeStateMergePatched(ShipmentMethodTypeEventId stateEventId)
 {
     return(new ShipmentMethodTypeStateMergePatched(stateEventId));
 }