Ejemplo n.º 1
0
        public V4AggregateProjection()
        {
            _createMethods       = new CreateMethodCollection(GetType(), typeof(T));
            _applyMethods        = new ApplyMethodCollection(GetType(), typeof(T));
            _shouldDeleteMethods = new ShouldDeleteMethodCollection(GetType(), typeof(T));

            ProjectionName = typeof(T).Name;
        }
Ejemplo n.º 2
0
        public AggregateProjection() : base(typeof(T).NameInCode())
        {
            _createMethods       = new CreateMethodCollection(GetType(), typeof(T));
            _applyMethods        = new ApplyMethodCollection(GetType(), typeof(T));
            _shouldDeleteMethods = new ShouldDeleteMethodCollection(GetType(), typeof(T));

            ProjectionName = typeof(T).Name;

            Options.DeleteViewTypeOnTeardown <T>();
        }
        public AggregateProjection() : base(typeof(T).NameInCode())
        {
            _createMethods       = new CreateMethodCollection(GetType(), typeof(T));
            _applyMethods        = new ApplyMethodCollection(GetType(), typeof(T));
            _shouldDeleteMethods = new ShouldDeleteMethodCollection(GetType(), typeof(T));

            ProjectionName = typeof(T).Name;

            Options.DeleteViewTypeOnTeardown <T>();

            _allEventTypes = new Lazy <Type[]>(() =>
            {
                return(_createMethods.Methods.Concat(_applyMethods.Methods).Concat(_shouldDeleteMethods.Methods)
                       .Select(x => x.EventType).Concat(DeleteEvents).Distinct().ToArray());
            });
        }
        protected GeneratedAggregateProjectionBase(AggregationScope scope) : base(typeof(T).NameInCode())
        {
            _createMethods       = new CreateMethodCollection(GetType(), typeof(T));
            _applyMethods        = new ApplyMethodCollection(GetType(), typeof(T));
            _shouldDeleteMethods = new ShouldDeleteMethodCollection(GetType(), typeof(T));

            Options.DeleteViewTypeOnTeardown <T>();

            _allEventTypes = new Lazy <Type[]>(() =>
            {
                return(_createMethods.Methods.Concat(_applyMethods.Methods).Concat(_shouldDeleteMethods.Methods)
                       .Select(x => x.EventType).Concat(DeleteEvents).Concat(TransformedEvents).Distinct().ToArray());
            });


            _inlineAggregationHandlerType = GetType().ToSuffixedTypeName("InlineHandler");
            _liveAggregationTypeName      = GetType().ToSuffixedTypeName("LiveAggregation");
            _versioning = new AggregateVersioning <T>(scope);
        }
        public AggregateProjection() : base(typeof(T).NameInCode())
        {
            _createMethods       = new CreateMethodCollection(GetType(), typeof(T));
            _applyMethods        = new ApplyMethodCollection(GetType(), typeof(T));
            _shouldDeleteMethods = new ShouldDeleteMethodCollection(GetType(), typeof(T));

            ProjectionName = typeof(T).Name;

            Options.DeleteViewTypeOnTeardown <T>();

            _allEventTypes = new Lazy <Type[]>(() =>
            {
                return(_createMethods.Methods.Concat(_applyMethods.Methods).Concat(_shouldDeleteMethods.Methods)
                       .Select(x => x.EventType).Concat(DeleteEvents).Concat(TransformedEvents).Distinct().ToArray());
            });


            _inlineAggregationHandlerType = GetType().NameInCode().Sanitize() + "InlineHandler";
            _liveAggregationTypeName      = GetType().NameInCode().Sanitize() + "LiveAggregation";
        }