Ejemplo n.º 1
0
        public IStatUserRegistrationFilter BuildStatUserRegistrationFilter(List <IStatUserRegistrationFilter> userRegistrationFilters)
        {
            for (int i = 0; i < userRegistrationFilters.Count - 1; i++)
            {
                IStatUserRegistrationFilter filter     = userRegistrationFilters[i];
                IStatUserRegistrationFilter nextFilter = userRegistrationFilters[i + 1];
                filter.Set(nextFilter);
            }

            return(userRegistrationFilters[0]);
        }
Ejemplo n.º 2
0
        public FiltersManager(IFiltersFactory filtersFactory, IFiltersChainBuilder filtersChainBuilder)
        {
            List<IStatWatchingFilter> statWatchingFilters = filtersFactory.CreateStatWatchingFilters();
            List<IStatUserRegistrationFilter> statUserRegistrationFilters = filtersFactory.CreateStatUserRegistrationFilters();
            List<IStatProjectUploadingFilter> statProjectUploadingFilters = filtersFactory.CreateStatProjectUploadingFilters();
            List<IStatProjectDeletionFilter> statProjectDeletionFilters = filtersFactory.CreateStatProjectDeletionFilters();
            List<IStatProjectCancellationFilter> statProjectCancellationFilters = filtersFactory.CreateStatProjectCancellationFilters();

            _statWatchingFilter = filtersChainBuilder.BuildStatWatchingFilter(statWatchingFilters);
            _statUserRegistrationFilter = filtersChainBuilder.BuildStatUserRegistrationFilter(statUserRegistrationFilters);
            _statProjectUploadingFilter = filtersChainBuilder.BuildStatProjectUploadingFilter(statProjectUploadingFilters);
            _statProjectDeletionFilter = filtersChainBuilder.BuildStatProjectDeletionFilter(statProjectDeletionFilters);
            _statProjectCancellationFilter = filtersChainBuilder.BuildStatProjectCancellationFilter(statProjectCancellationFilters);
        }
Ejemplo n.º 3
0
        public FiltersManager(IFiltersFactory filtersFactory, IFiltersChainBuilder filtersChainBuilder)
        {
            List <IStatWatchingFilter>            statWatchingFilters            = filtersFactory.CreateStatWatchingFilters();
            List <IStatUserRegistrationFilter>    statUserRegistrationFilters    = filtersFactory.CreateStatUserRegistrationFilters();
            List <IStatProjectUploadingFilter>    statProjectUploadingFilters    = filtersFactory.CreateStatProjectUploadingFilters();
            List <IStatProjectDeletionFilter>     statProjectDeletionFilters     = filtersFactory.CreateStatProjectDeletionFilters();
            List <IStatProjectCancellationFilter> statProjectCancellationFilters = filtersFactory.CreateStatProjectCancellationFilters();

            _statWatchingFilter            = filtersChainBuilder.BuildStatWatchingFilter(statWatchingFilters);
            _statUserRegistrationFilter    = filtersChainBuilder.BuildStatUserRegistrationFilter(statUserRegistrationFilters);
            _statProjectUploadingFilter    = filtersChainBuilder.BuildStatProjectUploadingFilter(statProjectUploadingFilters);
            _statProjectDeletionFilter     = filtersChainBuilder.BuildStatProjectDeletionFilter(statProjectDeletionFilters);
            _statProjectCancellationFilter = filtersChainBuilder.BuildStatProjectCancellationFilter(statProjectCancellationFilters);
        }