コード例 #1
0
        public static IPublishCommands GetCommandPublisher()
        {
            var unitOfWork = new EntityFrameworkUnitOfWork(ContextFactory);

            IPublishCommands commandPublisher = new LocalCommandPublisher(unitOfWork);
            commandPublisher = new CommandPublisherAuthorizer(commandPublisher, currentUserSession);
            commandPublisher = new CommandLogger(commandPublisher);
            commandPublisher = new CommandRetry(commandPublisher);
            commandPublisher.Subscribe(new ClientService(unitOfWork));

            return commandPublisher;
        }
コード例 #2
0
 public CommandPublisherProxy(ICurrentUserSession currentUser)
 {
     this.currentUser = currentUser;
     commandPublisher = new LocalCommandPublisher();
 }