public UserMainFoldersController(IFactoriesManager factoriesManager)
 {
     factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
     factoriesManager.GetService <IUserMainFoldersService>().TryGetTarget(out userMainFoldersService);
     factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
     factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);
 }
        public UserActivitiesController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <IUserActivityService>().TryGetTarget(out userActivityService);
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);

            logConfiguration = new LogConfiguration(this.GetType());
        }
Ejemplo n.º 3
0
        public BranchNodeController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IBranchNodeService>().TryGetTarget(out branchNodeService);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 4
0
        public RedirectionMiddleware(RequestDelegate nextMiddleware, IFactoriesManager factoriesManager)
        {
            this.nextMiddleware = nextMiddleware;

            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);

            logConfiguration = new LogConfiguration(GetType());
        }
        public FileToDocumentController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <IDocumentService>().TryGetTarget(out documentService);
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);

            this.factoriesManager = factoriesManager;

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 6
0
        public UserPhotoController(IMemoryCache memoryCache, IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IUserPhotoService>().TryGetTarget(out userPhotoService);
            factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);

            logConfiguration = new LogConfiguration(this.GetType());
        }
Ejemplo n.º 7
0
        public UserFeedController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <IUserFeedService>().TryGetTarget(out userFeedService);
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
            factoriesManager.GetService <IUserService <UserInfo> >().TryGetTarget(out userService);

            logConfiguration = new LogConfiguration(this.GetType());
        }
Ejemplo n.º 8
0
        public DocumentElementsController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IDocumentElementService>().TryGetTarget(out documentElementService);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 9
0
        public WordService(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IDocumentService>().TryGetTarget(out documentService);
            factoriesManager.GetService <IDocumentElementService>().TryGetTarget(out documentElementService);
            factoriesManager.GetService <IDocumentStructureService>().TryGetTarget(out documentStructureService);

            logConfiguration = new LogConfiguration(this.GetType());
        }
Ejemplo n.º 10
0
        public WordController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IWordService>().TryGetTarget(out wordService);
            factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);
            factoriesManager.GetService <ILinkService>().TryGetTarget(out linkService);

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 11
0
        public AuthorizationController(IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);
            factoriesManager.GetService <IUserService <UserInfo> >().TryGetTarget(out userService);
            factoriesManager.GetService <IUserActivityService>().TryGetTarget(out userActivityService);
            factoriesManager.GetService <IDateService>().TryGetTarget(out dateService);

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 12
0
        public UserEmailChangedEvent(string email, ObjectId userID, IFactoriesManager factoriesManager)
        {
            this.email  = email;
            this.userID = userID;

            factoriesManager.GetService <IEmailService>().TryGetTarget(out emailService);
            factoriesManager.GetService <ICodesService>().TryGetTarget(out codesService);
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);

            logConfiguration = new LogConfiguration(this.GetType());
        }
Ejemplo n.º 13
0
        public DocumentCreationEvent(ObjectId documentID, string documentName, ObjectId userID,
                                     IFactoriesManager factoriesManager)
        {
            this.documentID   = documentID;
            this.userID       = userID;
            this.documentName = documentName;

            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IDocumentStructureService>().TryGetTarget(out documentStructureService);

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 14
0
        public UserMainFoldersService(IFactoriesManager factoriesManager, IDatabaseManager databaseManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IFolderService>().TryGetTarget(out folderService);

            databaseManager.MongoDBFactory.GetDatabase <UserMainFolders>().TryGetTarget(out database);
            configurationBuilder = new MongoConfigurationBuilder(database.Configuration);
            configurationBuilder.SetConfigurationFilePath(databaseConfigFile).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 15
0
        public RequestService(IFactoriesManager factoriesManager, IDatabaseManager databaseManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IResponseService>().TryGetTarget(out responseService);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);

            databaseManager.MongoDBFactory.GetDatabase <RequestLog>().TryGetTarget(out requestDatabase);
            var configurationBuilder = new MongoConfigurationBuilder(requestDatabase.Configuration);

            configurationBuilder.SetConfigurationFilePath(databaseConfigFile).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            logConfiguration = new LogConfiguration(GetType());
        }
        public DocumentDeskStateService(IFactoriesManager factoriesManager, IDatabaseManager databaseManager)
        {
            databaseManager.MongoDBFactory.GetDatabase <Domain.Workplace.DocumentsDeskState.DocumentDeskState>().
            TryGetTarget(out database);

            configurationBuilder = new MongoConfigurationBuilder(database.Configuration);
            configurationBuilder.SetConfigurationFilePath(databaseConfigFileName).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            logConfiguration = new LogConfiguration(typeof(DocumentDeskStateService));

            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);
        }
Ejemplo n.º 17
0
        public UserFriendsService(IFactoriesManager factoriesManager, IDatabaseManager databasesManager)
        {
            databasesManager.MongoDBFactory.GetDatabase <Domain.UserFriends.UserFriends>().TryGetTarget(out database);

            configurationBuilder = new MongoConfigurationBuilder(database.Configuration);
            configurationBuilder.SetConfigurationFilePath(databaseConfigFile).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IUserService <UserInfo> >().TryGetTarget(out userService);
            factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);

            logConfiguration = new LogConfiguration(this.GetType());
        }
Ejemplo n.º 18
0
        public DocumentElementService(IFactoriesManager factoriesManager, IDatabaseManager databaseManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
            factoriesManager.GetService <IDateService>().TryGetTarget(out dateService);
            factoriesManager.GetService <IDocumentStructureService>().TryGetTarget(out documentStructureService);

            databaseManager.MongoDBFactory.GetDatabase <DocumentElementWrapper>().TryGetTarget(out database);

            IConfigurationBuilder configurationBuilder = new MongoConfigurationBuilder(database.Configuration);

            configurationBuilder.SetConfigurationFilePath(databaseConfigFile).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            logConfiguration = new LogConfiguration(GetType());
        }
        public ResponseLoggerMiddleware(RequestDelegate nextMiddlewareDel, IFactoriesManager factoriesManager)
        {
            this.nextMiddlewareDel = nextMiddlewareDel;

            factoriesManager.GetService <ILogger <ResponseLog> >().TryGetTarget(out responseLogger);

            logConfiguration = new LogConfiguration(typeof(RequestLoggerMiddleware));
        }
Ejemplo n.º 20
0
        public FileToDocumentAssociated(ObjectId documentID, ObjectId userID,
                                        string documentName, IFactoriesManager factoriesManager)
        {
            this.documentID   = documentID;
            this.userID       = userID;
            this.documentName = documentName;

            factoriesManager.GetService <IDocumentStructureService>().TryGetTarget(out documentStructureService);
        }
Ejemplo n.º 21
0
        public static void Initialize(IFactoriesManager factoriesManager)
        {
            actions    = new ConcurrentQueue <Action>();
            resetEvent = new AutoResetEvent(true);

            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);

            logConfiguration = new LogConfiguration(typeof(DefferedTasksManager));
        }
Ejemplo n.º 22
0
        public TokenService(IDatabaseManager databaseManager, IFactoriesManager factoriesManager)
        {
            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);

            databaseManager.MongoDBFactory.GetDatabase <JwtToken>().TryGetTarget(out mongoDBService);
            IConfigurationBuilder configurationBuilder = new MongoConfigurationBuilder(mongoDBService.Configuration);

            configurationBuilder.SetConfigurationFilePath(DATABASE_CONFIG_FILE).SetUserName().SetPassword()
            .SetAuthMechanism().SetDatabaseName().SetServerName().SetConnectionString();

            logConfiguration = new LogConfiguration(GetType());
        }
Ejemplo n.º 23
0
 public FolderSystemController(IFactoriesManager factoriesManager)
 {
     factoriesManager.GetService <ITokenService>().TryGetTarget(out tokenService);
     factoriesManager.GetService <IRequestService>().TryGetTarget(out requestService);
     factoriesManager.GetService <IFileService>().TryGetTarget(out fileService);
     factoriesManager.GetService <IFolderService>().TryGetTarget(out folderService);
     factoriesManager.GetService <IDateService>().TryGetTarget(out dateService);
     factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);
 }
Ejemplo n.º 24
0
        public UserCreatedEvent(IFactoriesManager factoriesManager, UserInfo user)
        {
            factoriesManager.GetService <ILinkService>().TryGetTarget(out linkService);
            factoriesManager.GetService <IEmailService>().TryGetTarget(out emailService);
            factoriesManager.GetService <IUserFriendsService>().TryGetTarget(out userFriendsService);
            factoriesManager.GetService <ICodesService>().TryGetTarget(out codesService);
            factoriesManager.GetService <IUserMainFoldersService>().TryGetTarget(out userMainFoldersService);
            factoriesManager.GetService <IDocumentDeskStateService>().TryGetTarget(out documentDeskStateService);

            this.user = user;
        }
Ejemplo n.º 25
0
        public LinkService(IFactoriesManager factoriesManager, IDatabaseManager databaseManager)
        {
            databaseManager.MongoDBFactory.GetDatabase <VerificationLink>().TryGetTarget(out verificationLinksDatabase);
            databaseManager.MongoDBFactory.GetDatabase <WordDownloadLink>().TryGetTarget(out wordLinksDatabase);

            IConfigurationBuilder configurationBuilder = new MongoConfigurationBuilder(verificationLinksDatabase.Configuration);

            configurationBuilder.SetConfigurationFilePath(databaseConfigFile).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            configurationBuilder = new MongoConfigurationBuilder(wordLinksDatabase.Configuration);
            configurationBuilder.SetConfigurationFilePath(databaseConfigFile).SetAuthMechanism()
            .SetUserName().SetPassword().SetDatabaseName().SetServerName().SetConnectionString();

            factoriesManager.GetService <ILogger <ApplicationError> >().TryGetTarget(out exceptionLogger);

            logConfiguration = new LogConfiguration(this.GetType());
        }