Exemple #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);
        }
Exemple #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... ////////////////////////////
Exemple #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... ////////////////////////////
Exemple #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)
                   );
        }
 protected AttributeUseStateEventDtoBase(AttributeUseEventId stateEventId)
 {
     this.AttributeUseEventId = stateEventId;
 }
Exemple #6
0
        protected AttributeUseEventId NewAttributeUseEventId(string attributeId)
        {
            var stateEventId = new AttributeUseEventId(this.AttributeSetEventId.AttributeSetId, attributeId, this.AttributeSetEventId.Version);

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