Ejemplo n.º 1
0
        protected virtual IUomTypeStateMergePatched Map(IMergePatchUomType c)
        {
            var stateEventId            = new UomTypeEventId(c.UomTypeId, c.Version);
            IUomTypeStateMergePatched e = NewUomTypeStateMergePatched(stateEventId);

            e.ParentTypeId = c.ParentTypeId;
            e.HasTable     = c.HasTable;
            e.Description  = c.Description;
            e.Active       = c.Active;
            e.IsPropertyParentTypeIdRemoved = c.IsPropertyParentTypeIdRemoved;
            e.IsPropertyHasTableRemoved     = c.IsPropertyHasTableRemoved;
            e.IsPropertyDescriptionRemoved  = c.IsPropertyDescriptionRemoved;
            e.IsPropertyActiveRemoved       = c.IsPropertyActiveRemoved;

            e.CommandId = c.CommandId;


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

            var version = c.Version;


            return(e);
        }
Ejemplo n.º 2
0
        protected UomTypeStateDeleted NewUomTypeStateDeleted(long version, string commandId, string requesterId)
        {
            var stateEventId = new UomTypeEventId(_state.UomTypeId, version);
            var e            = NewUomTypeStateDeleted(stateEventId);

            e.CommandId = commandId;

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

            return(e);
        }
Ejemplo n.º 3
0
        protected virtual IUomTypeStateDeleted Map(IDeleteUomType c)
        {
            var stateEventId       = new UomTypeEventId(c.UomTypeId, c.Version);
            IUomTypeStateDeleted e = NewUomTypeStateDeleted(stateEventId);

            e.CommandId = c.CommandId;


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


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

            UomTypeEventId other = obj as UomTypeEventId;

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

            return(true &&
                   Object.Equals(this.UomTypeId, other.UomTypeId) &&
                   Object.Equals(this.Version, other.Version)
                   );
        }
Ejemplo n.º 5
0
 protected UomTypeStateEventDtoBase(UomTypeEventId stateEventId)
 {
     this.UomTypeEventId = stateEventId;
 }
Ejemplo n.º 6
0
 private UomTypeStateDeleted NewUomTypeStateDeleted(UomTypeEventId stateEventId)
 {
     return(new UomTypeStateDeleted(stateEventId));
 }
Ejemplo n.º 7
0
 private UomTypeStateMergePatched NewUomTypeStateMergePatched(UomTypeEventId stateEventId)
 {
     return(new UomTypeStateMergePatched(stateEventId));
 }
Ejemplo n.º 8
0
 public UomTypeStateDeleted(UomTypeEventId stateEventId) : base(stateEventId)
 {
 }
Ejemplo n.º 9
0
 public UomTypeStateMergePatched(UomTypeEventId stateEventId) : base(stateEventId)
 {
 }
Ejemplo n.º 10
0
 public UomTypeStateCreated(UomTypeEventId stateEventId) : base(stateEventId)
 {
 }
Ejemplo n.º 11
0
 protected UomTypeStateEventBase(UomTypeEventId stateEventId) : base(stateEventId)
 {
 }