예제 #1
0
 public BlogService(IPostCache cache, IPostStore store, RazorEngine engine, IOptions <SiteSettings> siteSettings)
 {
     _cache        = cache;
     _store        = store;
     _engine       = engine;
     _siteSettings = siteSettings.Value;
 }
        public InitialStateCreator(IPostCache cache, IPostStore store, IMetadataProcessor metadata)
        {
            _cache    = cache;
            _store    = store;
            _metadata = metadata;

            Initialization = InitializeAsync();
        }
예제 #3
0
        protected BlogServiceBase(IPostCache postCache, IWebHostEnvironment env, IHttpContextAccessor contextAccessor)
        {
            if (env is null)
            {
                throw new ArgumentNullException(nameof(env));
            }

            this.Folder           = Path.Combine(env.WebRootPath, Posts);
            this.PostCache        = postCache ?? throw new ArgumentNullException(nameof(postCache));
            this._contextAccessor = contextAccessor ?? throw new ArgumentNullException(nameof(contextAccessor));
        }
 public AzureStorageBlogService(
     IPostCache postCache,
     IWebHostEnvironment env,
     IHttpContextAccessor contextAccessor,
     IOptionsMonitor <AzureStorageOptions> optionsMonitor,
     CloudTableClient cloudTableClient)
     : base(postCache, env, contextAccessor)
 {
     this._options          = optionsMonitor?.CurrentValue ?? throw new ArgumentNullException(nameof(optionsMonitor));
     this._cloudTableClient = cloudTableClient ?? throw new ArgumentNullException(nameof(cloudTableClient));
 }
예제 #5
0
 public UserAppService(
     IRepository <User, long> repository,
     UserManager userManager,
     RoleManager roleManager,
     IRepository <Role> roleRepository,
     IPasswordHasher <User> passwordHasher,
     IWorkerCache workerCache,
     IPostCache postCache)
     : base(repository)
 {
     _userManager    = userManager;
     _roleManager    = roleManager;
     _roleRepository = roleRepository;
     _passwordHasher = passwordHasher;
     _workerCache    = workerCache;
     _postCache      = postCache;
 }
예제 #6
0
 public TypeAppService(DutyProvider dutyProvider,
                       IArticleTypeCache articleTypeCache,
                       IPostCache postCache,
                       IRouteTypeCache routeTypeCache,
                       ITaskTypeCache taskTypeCache,
                       IWorkRoleCache workRoleCache,
                       IWorkplaceCache workplaceCache,
                       IOilTypeCache oilTypeCache,
                       IVehicleMTTypeCache vehicleMTTypeCache)
 {
     _dutyProvider       = dutyProvider;
     _articleTypeCache   = articleTypeCache;
     _postCache          = postCache;
     _routeTypeCache     = routeTypeCache;
     _taskTypeCache      = taskTypeCache;
     _workRoleCache      = workRoleCache;
     _workplaceCache     = workplaceCache;
     _oilTypeCache       = oilTypeCache;
     _vehicleMTTypeCache = vehicleMTTypeCache;
 }
예제 #7
0
        public WorkManager(IWorkerCache workerCache,
                           IVehicleCache vehicleCache,
                           IWorkplaceCache workplaceCache,
                           IWorkRoleCache workRoleCache,
                           IDepotCache depotCache,
                           IArticleCache articleCache,
                           IPostCache postCache,
                           IBoxCache boxCache,
                           IOutletCache outletCache,
                           ISigninCache signinCache,
                           IRepository <Signin> signinRepository,
                           IAffairCache affairCache,
                           IRepository <Affair> affairRepository,
                           IRepository <AffairWorker> affairWorkerRepository,
                           IRepository <AffairTask> affairTaskRepository,
                           IRepository <AffairEvent> affairEventRepository,
                           IRepository <AskDoorRecord> askdoorRepository)
        {
            _workerCache    = workerCache;
            _vehicleCache   = vehicleCache;
            _workplaceCache = workplaceCache;
            _workRoleCache  = workRoleCache;
            _depotCache     = depotCache;
            _articleCache   = articleCache;
            _postCache      = postCache;
            _boxCache       = boxCache;
            _outletCache    = outletCache;

            _signinCache      = signinCache;
            _signinRepository = signinRepository;

            _affairCache            = affairCache;
            _affairRepository       = affairRepository;
            _affairWorkerRepository = affairWorkerRepository;
            _affairTaskRepository   = affairTaskRepository;
            _affairEventRepository  = affairEventRepository;

            _askdoorRepository = askdoorRepository;
        }
예제 #8
0
 public FieldAppService(IDepotCache depotCache,
                        IWorkplaceCache workplaceCache,
                        IWorkerCache workerCache,
                        IVehicleCache vehicleCache,
                        IPostCache postCache,
                        IWorkRoleCache workRoleCache,
                        IGasStationCache gasStationCache,
                        IRepository <Worker> workerRepository,
                        IRepository <WorkerFile> workerFileRepository,
                        IRepository <Asset> assetRepository)
 {
     _depotCache           = depotCache;
     _workplaceCache       = workplaceCache;
     _workerCache          = workerCache;
     _vehicleCache         = vehicleCache;
     _postCache            = postCache;
     _workRoleCache        = workRoleCache;
     _gasStationCache      = gasStationCache;
     _workerRepository     = workerRepository;
     _workerFileRepository = workerFileRepository;
     _assetRepository      = assetRepository;
 }
예제 #9
0
 public InitialStateCreator(IPostCache cache, IPostStore store, IMetadataProcessor metadata)
 {
     _cache    = cache;
     _store    = store;
     _metadata = metadata;
 }
예제 #10
0
 public WorkerCache(ICacheManager cacheManager, IRepository <Worker> repository, IObjectMapper objectMapper,
                    IPostCache postCache)
     : base(cacheManager, repository, objectMapper)
 {
     _postCache = postCache;
 }
예제 #11
0
 public static void Use(IPostCache cacheInstance)
 {
     instance = new Lazy <IPostCache>(() => cacheInstance);
 }