Ejemplo n.º 1
0
        private AttributeUseEventId NewAttributeUseEventId(string attributeId)
        {
            var eId = new AttributeUseEventId();

            eId.AttributeSetId      = this.AttributeSetEventId.AttributeSetId;
            eId.AttributeId         = attributeId;
            eId.AttributeSetVersion = this.AttributeSetEventId.Version;
            return(eId);
        }
Ejemplo n.º 2
0
        }// END Map(IMergePatch... ////////////////////////////

        protected virtual IAttributeUseStateRemoved MapRemove(IRemoveAttributeUse c, IAttributeSetCommand outerCommand, long version)
        {
            c.RequesterId = outerCommand.RequesterId;
            var stateEventId            = new AttributeUseEventId(c.AttributeSetId, c.AttributeId, version);
            IAttributeUseStateRemoved e = NewAttributeUseStateRemoved(stateEventId);


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

            return(e);
        }// END Map(IRemove... ////////////////////////////
Ejemplo n.º 3
0
        protected virtual IAttributeUseStateCreated MapCreate(ICreateAttributeUse c, IAttributeSetCommand outerCommand, long version, IAttributeSetState outerState)
        {
            c.RequesterId = outerCommand.RequesterId;
            var stateEventId            = new AttributeUseEventId(c.AttributeSetId, c.AttributeId, version);
            IAttributeUseStateCreated e = NewAttributeUseStateCreated(stateEventId);
            var s = outerState.AttributeUses.Get(c.AttributeId, true);

            e.SequenceNumber = c.SequenceNumber;
            e.Active         = c.Active;

            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>();
            return(e);
        }// END Map(ICreate... ////////////////////////////
Ejemplo n.º 4
0
        public override bool Equals(object obj)
        {
            if (Object.ReferenceEquals(this, obj))
            {
                return(true);
            }

            AttributeUseEventId other = obj as AttributeUseEventId;

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

            return(true &&
                   Object.Equals(this.AttributeSetId, other.AttributeSetId) &&
                   Object.Equals(this.AttributeId, other.AttributeId) &&
                   Object.Equals(this.AttributeSetVersion, other.AttributeSetVersion)
                   );
        }
Ejemplo n.º 5
0
 protected AttributeUseStateEventDtoBase(AttributeUseEventId stateEventId)
 {
     this.AttributeUseEventId = stateEventId;
 }
Ejemplo n.º 6
0
        protected AttributeUseEventId NewAttributeUseEventId(string attributeId)
        {
            var stateEventId = new AttributeUseEventId(this.AttributeSetEventId.AttributeSetId, attributeId, this.AttributeSetEventId.Version);

            return(stateEventId);
        }
Ejemplo n.º 7
0
 private AttributeUseStateRemoved NewAttributeUseStateRemoved(AttributeUseEventId stateEventId)
 {
     return(new AttributeUseStateRemoved(stateEventId));
 }
Ejemplo n.º 8
0
 private AttributeUseStateMergePatched NewAttributeUseStateMergePatched(AttributeUseEventId stateEventId)
 {
     return(new AttributeUseStateMergePatched(stateEventId));
 }
Ejemplo n.º 9
0
 public AttributeUseStateRemoved(AttributeUseEventId stateEventId) : base(stateEventId)
 {
 }
Ejemplo n.º 10
0
 public AttributeUseStateMergePatched(AttributeUseEventId stateEventId) : base(stateEventId)
 {
 }
Ejemplo n.º 11
0
 public AttributeUseStateCreated(AttributeUseEventId stateEventId) : base(stateEventId)
 {
 }
Ejemplo n.º 12
0
 protected AttributeUseStateEventBase(AttributeUseEventId stateEventId) : base(stateEventId)
 {
 }