コード例 #1
0
 private EventStream(TEntityId aggregateId, AggregationName aggregationName, Version version, IImmutableList <IDomainEvent> events)
 {
     AggregationId = aggregateId;
     Name          = aggregationName;
     Version       = version;
     Events        = events;
 }
コード例 #2
0
        public static AggregationName From(string current)
        {
            var aggregationName = new AggregationName(current);
            var validator       = new AggregationNameValidator();

            aggregationName.SetValidationResult(validator.Validate(aggregationName));

            return(aggregationName);
        }
コード例 #3
0
        public static EventStream <TEntityId> From(TEntityId aggregateId, AggregationName name, Version version, IImmutableList <IDomainEvent> events)
        {
            var eventStream = new EventStream <TEntityId>(aggregateId, name, version, events);

            return(eventStream);
        }