Пример #1
0
 public LightweightExternalOrderbookService(
     IEventChannel <BestPriceChangeEventArgs> bestPriceChangeEventChannel,
     IOrderBookProviderApi orderBookProviderApi,
     IDateService dateService,
     IConvertService convertService,
     IScheduleSettingsCacheService scheduleSettingsCache,
     IAssetPairDayOffService assetPairDayOffService,
     IAssetPairsCache assetPairsCache,
     ICqrsSender cqrsSender,
     IIdentityGenerator identityGenerator,
     ILog log,
     MarginTradingSettings marginTradingSettings)
 {
     _bestPriceChangeEventChannel = bestPriceChangeEventChannel;
     _orderBookProviderApi        = orderBookProviderApi;
     _dateService            = dateService;
     _convertService         = convertService;
     _scheduleSettingsCache  = scheduleSettingsCache;
     _assetPairDayOffService = assetPairDayOffService;
     _assetPairsCache        = assetPairsCache;
     _cqrsSender             = cqrsSender;
     _identityGenerator      = identityGenerator;
     _log = log;
     _defaultExternalExchangeId = string.IsNullOrEmpty(marginTradingSettings.DefaultExternalExchangeId)
         ? "Default"
         : marginTradingSettings.DefaultExternalExchangeId;
     _orderbookValidation = marginTradingSettings.OrderbookValidation;
 }
Пример #2
0
 public ValidateOrderService(
     IQuoteCacheService quoteCashService,
     IAccountUpdateService accountUpdateService,
     IAccountsCacheService accountsCacheService,
     ITradingInstrumentsCacheService accountAssetsCacheService,
     IAssetPairsCache assetPairsCache,
     OrdersCache ordersCache,
     IAssetPairDayOffService assetDayOffService,
     IIdentityGenerator identityGenerator,
     IDateService dateService,
     MarginTradingSettings marginSettings,
     ICfdCalculatorService cfdCalculatorService)
 {
     _quoteCashService        = quoteCashService;
     _accountUpdateService    = accountUpdateService;
     _accountsCacheService    = accountsCacheService;
     _tradingInstrumentsCache = accountAssetsCacheService;
     _assetPairsCache         = assetPairsCache;
     _ordersCache             = ordersCache;
     _assetDayOffService      = assetDayOffService;
     _identityGenerator       = identityGenerator;
     _dateService             = dateService;
     _marginSettings          = marginSettings;
     _cfdCalculatorService    = cfdCalculatorService;
 }
Пример #3
0
 public MtController(
     IMarginTradingAccountHistoryRepository accountsHistoryRepository,
     IMarginTradingOrdersHistoryRepository ordersHistoryRepository,
     IMicrographCacheService micrographCacheService,
     IAccountAssetsCacheService accountAssetsCacheService,
     IAssetPairsCache assetPairsCache,
     IMarketMakerMatchingEngine matchingEngine,
     ITradingEngine tradingEngine,
     IAccountsCacheService accountsCacheService,
     IMarginTradingOperationsLogService operationsLogService,
     IConsole consoleWriter,
     OrdersCache ordersCache,
     MarginSettings marginSettings,
     AccountManager accountManager,
     IAssetPairDayOffService assetDayOffService,
     IQuoteCacheService quoteCacheService,
     IIdentityGenerator identityGenerator)
 {
     _accountsHistoryRepository = accountsHistoryRepository;
     _ordersHistoryRepository   = ordersHistoryRepository;
     _micrographCacheService    = micrographCacheService;
     _accountAssetsCacheService = accountAssetsCacheService;
     _assetPairsCache           = assetPairsCache;
     _matchingEngine            = matchingEngine;
     _tradingEngine             = tradingEngine;
     _accountsCacheService      = accountsCacheService;
     _operationsLogService      = operationsLogService;
     _consoleWriter             = consoleWriter;
     _ordersCache        = ordersCache;
     _marginSettings     = marginSettings;
     _accountManager     = accountManager;
     _assetDayOffService = assetDayOffService;
     _quoteCacheService  = quoteCacheService;
     _identityGenerator  = identityGenerator;
 }
Пример #4
0
 public PositionsConsumer(OrdersCache ordersCache,
                          IRabbitMqNotifyService rabbitMqNotifyService,
                          IConvertService convertService,
                          IDateService dateService,
                          IAccountsCacheService accountsCacheService,
                          IAccountUpdateService accountUpdateService,
                          IIdentityGenerator identityGenerator,
                          ICqrsSender cqrsSender,
                          IEventChannel <OrderCancelledEventArgs> orderCancelledEventChannel,
                          IEventChannel <OrderChangedEventArgs> orderChangedEventChannel,
                          IEventChannel <OrderActivatedEventArgs> orderActivatedEventChannel,
                          IMatchingEngineRouter meRouter,
                          ILog log)
 {
     _ordersCache                = ordersCache;
     _rabbitMqNotifyService      = rabbitMqNotifyService;
     _convertService             = convertService;
     _dateService                = dateService;
     _accountsCacheService       = accountsCacheService;
     _accountUpdateService       = accountUpdateService;
     _identityGenerator          = identityGenerator;
     _cqrsSender                 = cqrsSender;
     _orderCancelledEventChannel = orderCancelledEventChannel;
     _orderChangedEventChannel   = orderChangedEventChannel;
     _orderActivatedEventChannel = orderActivatedEventChannel;
     _meRouter = meRouter;
     _log      = log;
 }
Пример #5
0
 public PoolManager(IIdentityGenerator identityGenerator, IEventSystem eventSystem)
 {
     IdentityGenerator = identityGenerator;
     EventSystem       = eventSystem;
     pools             = new Dictionary <string, IPool>();
     CreatePool(DefaultPoolName);
 }
Пример #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="IdentityGeneratingEntityData"/> class.
 /// </summary>
 /// <param name="query">Query.</param>
 /// <param name="persister">Persister.</param>
 /// <param name="identityGenerator">Identity generator.</param>
 public IdentityGeneratingEntityData(IQuery query,
                                     IPersister persister,
                                     IIdentityGenerator identityGenerator)
     : base(query, persister)
 {
     this.identityGenerator = identityGenerator ?? new InMemoryIdentityGenerator();
 }
Пример #7
0
 public Pool(string name, IIdentityGenerator identityGenerator, IEventSystem eventSystem)
 {
     _entities         = new List <IEntity>();
     Name              = name;
     IdentityGenerator = identityGenerator;
     EventSystem       = eventSystem;
 }
Пример #8
0
        private IdentityGenerator()
        {
            if (AppRuntime.Instance.CurrentApplication == null)
            {
                throw new EagleAppException("The application has not been initialized and started yet.");
            }

            if (AppRuntime.Instance.CurrentApplication.ConfigSource == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator == null ||
                string.IsNullOrEmpty(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider))
            {
                generator = new SequentialIdentityGenerator();
            }
            else
            {
                Type type = Type.GetType(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider);

                if (type == null)
                {
                    throw new ConfigException("Unable to create the type from the name {0}.", AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider);
                }

                if (type.Equals(this.GetType()))
                {
                    throw new EagleAppException("Type {0} cannot be used as identity generator, it is maintained by the Eagle framework internally.", this.GetType().AssemblyQualifiedName);
                }

                generator = (IIdentityGenerator)Activator.CreateInstance(type);
            }
        }
Пример #9
0
 public ValidateOrderService(
     IQuoteCacheService quoteCashService,
     IAccountUpdateService accountUpdateService,
     IAccountsCacheService accountsCacheService,
     ITradingInstrumentsCacheService accountAssetsCacheService,
     IAssetPairsCache assetPairsCache,
     OrdersCache ordersCache,
     IAssetPairDayOffService assetDayOffService,
     IIdentityGenerator identityGenerator,
     IDateService dateService,
     MarginTradingSettings marginSettings,
     ICfdCalculatorService cfdCalculatorService,
     IFeatureManager featureManager,
     CorrelationContextAccessor correlationContextAccessor)
 {
     _quoteCashService           = quoteCashService;
     _accountUpdateService       = accountUpdateService;
     _accountsCacheService       = accountsCacheService;
     _tradingInstrumentsCache    = accountAssetsCacheService;
     _assetPairsCache            = assetPairsCache;
     _ordersCache                = ordersCache;
     _assetDayOffService         = assetDayOffService;
     _identityGenerator          = identityGenerator;
     _dateService                = dateService;
     _marginSettings             = marginSettings;
     _cfdCalculatorService       = cfdCalculatorService;
     _featureManager             = featureManager;
     _correlationContextAccessor = correlationContextAccessor;
 }
Пример #10
0
 public ExternalOrderbookService(
     IEventChannel <BestPriceChangeEventArgs> bestPriceChangeEventChannel,
     IOrderBookProviderApi orderBookProviderApi,
     IDateService dateService,
     IConvertService convertService,
     IAssetPairDayOffService assetPairDayOffService,
     IScheduleSettingsCacheService scheduleSettingsCache,
     IAssetPairsCache assetPairsCache,
     ICqrsSender cqrsSender,
     IIdentityGenerator identityGenerator,
     ILog log,
     MarginTradingSettings marginTradingSettings)
 {
     _bestPriceChangeEventChannel = bestPriceChangeEventChannel;
     _orderBookProviderApi        = orderBookProviderApi;
     _dateService            = dateService;
     _convertService         = convertService;
     _assetPairDayOffService = assetPairDayOffService;
     _scheduleSettingsCache  = scheduleSettingsCache;
     _assetPairsCache        = assetPairsCache;
     _cqrsSender             = cqrsSender;
     _identityGenerator      = identityGenerator;
     _log = log;
     _marginTradingSettings = marginTradingSettings;
 }
Пример #11
0
        private IdentityGenerator()
        {
            if (AppRuntime.Instance.CurrentApplication == null)
            {
                throw new OFoodsException("该应用程序尚未初始化并且尚未启动.");
            }
            if (AppRuntime.Instance.CurrentApplication.ConfigSource == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator == null ||
                string.IsNullOrEmpty(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider) ||
                string.IsNullOrWhiteSpace(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider))
            {
                generator = new SequentialIdentityGenerator();
            }
            else
            {
                Type type = Type.GetType(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider);
                if (type == null)
                {
                    throw new OFoodsException("无法从名称{0}创建类型.", AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider);
                }
                if (type.Equals(this.GetType()))
                {
                    throw new OFoodsException("类型{0}不能用作标识生成器,它由内部的OFoods框架维护.", this.GetType().AssemblyQualifiedName);
                }

                generator = (IIdentityGenerator)Activator.CreateInstance(type);
            }
        }
Пример #12
0
 public SpecialLiquidationCommandsHandler(
     ITradingEngine tradingEngine,
     IDateService dateService,
     IOrderReader orderReader,
     IChaosKitty chaosKitty,
     IOperationExecutionInfoRepository operationExecutionInfoRepository,
     ILog log,
     MarginTradingSettings marginTradingSettings,
     IAssetPairsCache assetPairsCache,
     IAssetPairDayOffService assetPairDayOffService,
     IExchangeConnectorService exchangeConnectorService,
     IIdentityGenerator identityGenerator,
     IAccountsCacheService accountsCacheService)
 {
     _tradingEngine = tradingEngine;
     _dateService   = dateService;
     _orderReader   = orderReader;
     _chaosKitty    = chaosKitty;
     _operationExecutionInfoRepository = operationExecutionInfoRepository;
     _log = log;
     _marginTradingSettings    = marginTradingSettings;
     _assetPairsCache          = assetPairsCache;
     _assetPairDayOffService   = assetPairDayOffService;
     _exchangeConnectorService = exchangeConnectorService;
     _identityGenerator        = identityGenerator;
     _accountsCacheService     = accountsCacheService;
 }
 public PublishedEventPersistenter(IIdentityGenerator identityGenerator, EventBusMySQLOptions eventBusMySQLOptions, IServiceProvider serviceProvider, ILogger <PublishedEventPersistenter> logger)
 {
     _identityGenerator    = identityGenerator;
     _eventBusMySQLOptions = eventBusMySQLOptions;
     _serviceProvider      = serviceProvider;
     _logger = logger;
 }
 public PasswordResetTokenCreator(IWriteableRepository writeableRepository, IReadOnlyRepository readOnlyRepository, ITimeProvider timeProvider, IIdentityGenerator <Guid> idGenerator)
 {
     _writeableRepository = writeableRepository;
     _readOnlyRepository  = readOnlyRepository;
     _timeProvider        = timeProvider;
     _idGenerator         = idGenerator;
 }
Пример #15
0
        private IdentityGenerator()
        {
            if (AppRuntime.Instance.CurrentApplication == null)
            {
                throw new EagleAppException("The application has not been initialized and started yet.");
            }

            if (AppRuntime.Instance.CurrentApplication.ConfigSource == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators == null ||
                AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator == null ||
                string.IsNullOrEmpty(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider))
            {
                generator = new SequentialIdentityGenerator();
            }
            else
            {
                Type type = Type.GetType(AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider);

                if (type == null)
                {
                    throw new ConfigException("Unable to create the type from the name {0}.", AppRuntime.Instance.CurrentApplication.ConfigSource.Config.Generators.IdentityGenerator.Provider);
                }

                if (type.Equals(this.GetType()))
                {
                    throw new EagleAppException("Type {0} cannot be used as identity generator, it is maintained by the Eagle framework internally.", this.GetType().AssemblyQualifiedName);
                }

                generator = (IIdentityGenerator)Activator.CreateInstance(type);
            }
        }
Пример #16
0
        public Created(string login, string password, IIdentityGenerator identityGenerator)
        {
            Login = login;
            Password = password;

            AggregateId = identityGenerator.NewId();
        }
Пример #17
0
 public SecurityAggregate(SecurityAggregateState state, Action <IEvent <SecurityId> > observer,
                          PasswordGenerator generator, IIdentityGenerator identityGenerator)
 {
     _state             = state;
     _observer          = observer;
     _generator         = generator;
     _identityGenerator = identityGenerator;
 }
Пример #18
0
 public DatabaseEngine(IIdentityGenerator identityGenerator, IObjectCloner objectCloner, string uniqueIdPropName)
 {
     _objectObjectCloner = objectCloner;
     _idGenerator        = identityGenerator;
     _uniqueIdPropName   = uniqueIdPropName;
     _collections        = new ThreadLocal <Dictionary <string, Dictionary <string, dynamic> > >();
     _collections.Value  = new Dictionary <string, Dictionary <string, dynamic> >();
 }
Пример #19
0
 public PoolManager(IIdentityGenerator identityGenerator, IEventSystem eventSystem)
 {
     IdentityGenerator = identityGenerator;
     EventSystem       = eventSystem;
     _groupAccessors   = new Dictionary <GroupAccessorToken, IEnumerable <IEntity> >();
     _pools            = new Dictionary <string, IPool>();
     CreatePool(DefaultPoolName);
 }
Пример #20
0
 public RequestCorrelationFeatureTests()
 {
     generator = A.Fake <IIdentityGenerator>();
     A.CallTo(() => generator.GenerateIdentity()).Returns(newId);
     feature = new RequestCorrelationFeature {
         IdentityGenerator = generator
     };
 }
Пример #21
0
 public OrderFactory(IIdentityGenerator <OrderIdentity> orderIdentityGenerator,
                     IIdentityGenerator <OrderItemIdentity> orderItemIdentityGenerator,
                     ITimeService timeService)
 {
     _orderIdentityGenerator     = orderIdentityGenerator;
     _orderItemIdentityGenerator = orderItemIdentityGenerator;
     _timeService = timeService;
 }
Пример #22
0
 public AggregateFactory(ITapeStorageFactory factory, IEnvelopeStreamer streamer, IQueueWriter writer, NuclearStorage storage, IIdentityGenerator generator)
 {
     _factory   = factory;
     _streamer  = streamer;
     _writer    = writer;
     _storage   = storage;
     _generator = generator;
 }
 public RequestCorrelationFeatureTests(AppHostFixture fixture)
 {
     appHost   = fixture.AppHost;
     generator = A.Fake <IIdentityGenerator>();
     A.CallTo(() => generator.GenerateIdentity()).Returns(newId);
     feature = new RequestCorrelationFeature {
         IdentityGenerator = generator
     };
 }
Пример #24
0
 public SqlStoreSender(
     IIdentityGenerator identityGenerator,
     IRepository <PerformedOperationFinalProcessing> repository,
     IXmlEventSerializer serializer)
 {
     _identityGenerator = identityGenerator;
     _repository        = repository;
     _serializer        = serializer;
 }
Пример #25
0
        public ExtensionsApplicationBuilder(IApplicationBuilder appBuilder, IIdentityGenerator generator = null)
        {
            this.appBuilder  = appBuilder;
            this.generator   = generator ?? new NaiveShimIdentityGenerator(0);
            this.middlewares = new List <Func <RequestDelegate, RequestDelegate> >();
            var id = this.generator.GetId();

            this.shims.Add(new Shim(id));
        }
 public PasswordResetTokenCreator(IPasswordResetTokenRepository tokenRepo,
                                  IUserRepository readOnlyRepository, ITimeProvider timeProvider,
                                  IIdentityGenerator <Guid> idGenerator)
 {
     _tokenRepo          = tokenRepo;
     _readOnlyRepository = readOnlyRepository;
     _timeProvider       = timeProvider;
     _idGenerator        = idGenerator;
 }
Пример #27
0
 public ServiceController(
     IOvernightMarginParameterContainer overnightMarginParameterContainer,
     IIdentityGenerator identityGenerator,
     ISnapshotService snapshotService)
 {
     _overnightMarginParameterContainer = overnightMarginParameterContainer;
     _identityGenerator = identityGenerator;
     _snapshotService   = snapshotService;
 }
        public InMemoryObjectStoreDelegate(StateAdapterProvider stateAdapterProvider)
        {
            _stateAdapterProvider = stateAdapterProvider;
            _stores            = new Dictionary <Type, Dictionary <long, TState> >();
            _entries           = new List <TEntry>();
            _dispatchables     = new List <Dispatchable <TEntry, TState> >();
            _identityGenerator = IdentityGeneratorType.Random.Generator();

            _nextId = 1;
        }
Пример #29
0
 public UserSessionFactory(IWriteableRepository writeableRepository,
                           ITimeProvider timeProvider,
                           IIdentityGenerator <Guid> identityGenerator,
                           ITokenExpirationProvider tokenExpirationProvider)
 {
     _writeableRepository     = writeableRepository;
     _timeProvider            = timeProvider;
     _identityGenerator       = identityGenerator;
     _tokenExpirationProvider = tokenExpirationProvider;
 }
Пример #30
0
 public UserSessionFactory(IWriteableRepository writeableRepository,
                           ITimeProvider timeProvider,
                           IIdentityGenerator<Guid> identityGenerator,
                           ITokenExpirationProvider tokenExpirationProvider)
 {
     _writeableRepository = writeableRepository;
     _timeProvider = timeProvider;
     _identityGenerator = identityGenerator;
     _tokenExpirationProvider = tokenExpirationProvider;
 }
Пример #31
0
 public PendingOrdersCleaningService(ILog log, IOrderReader orderReader, ITradingEngine tradingEngine,
                                     IAssetPairDayOffService assetDayOffService, IIdentityGenerator identityGenerator)
     : base(nameof(PendingOrdersCleaningService), 60000, log)
 {
     _log                = log;
     _orderReader        = orderReader;
     _tradingEngine      = tradingEngine;
     _assetDayOffService = assetDayOffService;
     _identityGenerator  = identityGenerator;
 }
Пример #32
0
 public SqlStoreSender(
     IIdentityGenerator identityGenerator,
     IRepository <PerformedOperationFinalProcessing> repository,
     IOperationSerializer <TOperation> serializer)
 {
     _identityGenerator = identityGenerator;
     _repository        = repository;
     _serializer        = serializer;
     _targetFlow        = MessageFlowBase <TFlow> .Instance;
 }
Пример #33
0
 public SalesAreaRepository(
     ISqlServerTenantDbContext dbContext,
     IIdentityGenerator identityGenerator,
     IMapper mapper)
 {
     _dbContext         = dbContext;
     _identityGenerator = identityGenerator;
     _sequenceRebuilder = new SequenceRebuilder <Entities.Tenant.SalesAreas.SalesArea, SalesAreaNoIdentity>();
     _mapper            = mapper;
 }
        public void SetUp()
        {
            BlobStore = Substitute.For<IBlobStore>();
            IdentityGenerator = Substitute.For<IIdentityGenerator>();
            _handleWriter = Substitute.For<IDocumentWriter>();
            DocumentReader = Substitute.For<IMongoDbReader<DocumentDescriptorReadModel, DocumentDescriptorId>>();
            DocumentDeletedReader = Substitute.For<IMongoDbReader<DocumentDeletedReadModel, String>>();

            QueueDispatcher = Substitute.For<IQueueManager>();
            CounterService = Substitute.For<ICounterService>();
            var bus = Substitute.For<IInProcessCommandBus>();
            var configuration =  new DocumentStoreTestConfiguration();
            Controller = new DocumentsController(
                BlobStore,
               configuration, 
                IdentityGenerator, 
                DocumentReader,
                DocumentDeletedReader,
                bus, 
                _handleWriter,
                QueueDispatcher,
                CounterService,
                null)
            {
                Request = new HttpRequestMessage
                {
                    RequestUri = new Uri("http://localhost/api/products")
                },
                Logger = new ConsoleLogger(),
                Configuration = new HttpConfiguration(),
                RequestContext =
                {
                    RouteData = new HttpRouteData(
                        route: new HttpRoute(),
                        values: new HttpRouteValueDictionary {{"controller", "file"}})
                }
            };

            //  Controller.Configuration.MapHttpAttributeRoutes();

            Controller.Request.Properties.Add(HttpPropertyKeys.HttpConfigurationKey, new HttpConfiguration());
        }
 public DocumentsController(
     IBlobStore blobStore,
     DocumentStoreConfiguration configService,
     IIdentityGenerator identityGenerator,
     IMongoDbReader<DocumentDescriptorReadModel, DocumentDescriptorId> documentDescriptorReader,
     IMongoDbReader<DocumentDeletedReadModel, String> documentDeletedReader,
     IInProcessCommandBus commandBus,
     IDocumentWriter handleWriter,
     IQueueManager queueDispatcher,
     ICounterService counterService,
     IDocumentFormatTranslator documentFormatTranslator)
 {
     _blobStore = blobStore;
     _configService = configService;
     _identityGenerator = identityGenerator;
     _documentDescriptorReader = documentDescriptorReader;
     _documentDeletedReader = documentDeletedReader;
     _handleWriter = handleWriter;
     _queueDispatcher = queueDispatcher;
     _counterService = counterService;
     _documentFormatTranslator = documentFormatTranslator;
     CommandBus = commandBus;
 }
Пример #36
0
 private IdentityGenerator()
 {
     this.generator = new SequentialIdentityGenerator();
 }
Пример #37
0
 public AggregateRootFactory(IIdentityGenerator identityGenerator, IRepository repository)
 {
     _identityGenerator = identityGenerator;
     _repository = repository;
 }
Пример #38
0
 public SrvOrdersRegistrator(IOrdersRepository ordersRepository, IIdentityGenerator identityGenerator, IOrderExecuter orderExecuter)
 {
     _ordersRepository = ordersRepository;
     _identityGenerator = identityGenerator;
     _orderExecuter = orderExecuter;
 }
Пример #39
0
 public UserService(IStorage<User> storage, ICryptographyService cryptographyService, IIdentityGenerator identityGenerator)
 {
     this.storage = storage;
     this.cryptographyService = cryptographyService;
     this.identityGenerator = identityGenerator;
 }
 public EmployeeCreated(string name, IIdentityGenerator identityGenerator)
 {
     this.Name = name;
     this.AggregateId = identityGenerator.NewId();
 }
Пример #41
0
 public AggregateRootFactory(IIdentityGenerator identityGenerator, IRepository repository, IAccountIndexStore accountIndexStore)
 {
     _identityGenerator = identityGenerator;
     _repository = repository;
     _accountIndexStore = accountIndexStore;
 }