Пример #1
0
 public AudienceStateEventIdDtoWrapper(AudienceStateEventId val)
 {
     if (val == null)
     {
         throw new ArgumentNullException("val");
     }
     this._value = val;
 }
Пример #2
0
        public virtual AudienceStateEventId ToAudienceStateEventId()
        {
            AudienceStateEventId v = new AudienceStateEventId();

            v.ClientId = this.ClientId;
            v.Version  = this.Version;
            return(v);
        }
Пример #3
0
        protected AudienceStateDeleted NewAudienceStateDeleted(string commandId, string requesterId)
        {
            var stateEventId = new AudienceStateEventId(_state.ClientId, ((IAudienceStateProperties)_state).Version);
            var e            = NewAudienceStateDeleted(stateEventId);

            e.CommandId = commandId;

            e.CreatedBy = (string)requesterId;
            e.CreatedAt = DateTime.Now;

            return(e);
        }
Пример #4
0
        protected virtual IAudienceStateDeleted Map(IDeleteAudience c)
        {
            var stateEventId        = new AudienceStateEventId(c.ClientId, c.Version);
            IAudienceStateDeleted e = NewAudienceStateDeleted(stateEventId);

            e.CommandId = c.CommandId;


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = DateTime.Now;


            return(e);
        }
Пример #5
0
        protected virtual IAudienceStateCreated Map(ICreateAudience c)
        {
            var stateEventId        = new AudienceStateEventId(c.ClientId, c.Version);
            IAudienceStateCreated e = NewAudienceStateCreated(stateEventId);

            e.Name         = c.Name;
            e.Base64Secret = c.Base64Secret;
            e.Active       = c.Active;
            e.CommandId    = c.CommandId;


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = DateTime.Now;
            var version = c.Version;


            return(e);
        }
Пример #6
0
        public override bool Equals(object obj)
        {
            if (Object.ReferenceEquals(this, obj))
            {
                return(true);
            }

            AudienceStateEventId other = obj as AudienceStateEventId;

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

            return(true &&
                   Object.Equals(this.ClientId, other.ClientId) &&
                   Object.Equals(this.Version, other.Version)
                   );
        }
Пример #7
0
        protected virtual IAudienceStateMergePatched Map(IMergePatchAudience c)
        {
            var stateEventId             = new AudienceStateEventId(c.ClientId, c.Version);
            IAudienceStateMergePatched e = NewAudienceStateMergePatched(stateEventId);

            e.Name                          = c.Name;
            e.Base64Secret                  = c.Base64Secret;
            e.Active                        = c.Active;
            e.IsPropertyNameRemoved         = c.IsPropertyNameRemoved;
            e.IsPropertyBase64SecretRemoved = c.IsPropertyBase64SecretRemoved;
            e.IsPropertyActiveRemoved       = c.IsPropertyActiveRemoved;

            e.CommandId = c.CommandId;


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = DateTime.Now;

            var version = c.Version;


            return(e);
        }
Пример #8
0
 private AudienceStateDeleted NewAudienceStateDeleted(AudienceStateEventId stateEventId)
 {
     return(new AudienceStateDeleted(stateEventId));
 }
Пример #9
0
 private AudienceStateMergePatched NewAudienceStateMergePatched(AudienceStateEventId stateEventId)
 {
     return(new AudienceStateMergePatched(stateEventId));
 }
Пример #10
0
 protected AudienceStateEventBase(AudienceStateEventId stateEventId)
 {
     this.StateEventId = stateEventId;
 }
Пример #11
0
 public AudienceStateDeleted(AudienceStateEventId stateEventId) : base(stateEventId)
 {
 }
Пример #12
0
 public AudienceStateMergePatched(AudienceStateEventId stateEventId) : base(stateEventId)
 {
 }
Пример #13
0
 public AudienceStateCreated(AudienceStateEventId stateEventId) : base(stateEventId)
 {
 }
Пример #14
0
 public AudienceStateEventIdFlattenedDto(AudienceStateEventId val)
 {
     this._value = new AudienceStateEventIdDtoWrapper(val);
 }