Exemplo n.º 1
0
 public HomeController(
     ICurrent current,
     IPushService pushService,
     IOnlineManager onlineManager,
     ILogger <HomeController> logger,
     ITokenService tokenService,
     IDeviceService deviceService,
     ITypeFinder typeFinder,
     ITypeResolve typeResolve,
     IDbContext dbContext,
     DbContextFactory dbContextFactory,
     ICache cache,
     IBackgroundJobManager backgroundJobManager,
     IOptions <HangfireOptions> hangfireOption)
 {
     _current              = current;
     _tokenService         = tokenService;
     _deviceService        = deviceService;
     _typeFinder           = typeFinder;
     _typeResolve          = typeResolve;
     _dbContext            = dbContext;
     _dbContextFactory     = dbContextFactory;
     _cache                = cache;
     _backgroundJobManager = backgroundJobManager;
     _hangfireOptions      = hangfireOption.Value;
     _pushService          = pushService;
     _logger               = logger;
 }
Exemplo n.º 2
0
        public SortInfoHandler(IPlaylistHandler playlistHandler, ICurrent current, IVideoListContainer container, ILogger logger)
        {
            this.playlistHandler = playlistHandler;
            this.current         = current;
            this.container       = container;
            this.logger          = logger;

            this.SortType             = new ReactiveProperty <VideoSortType>(current.SelectedPlaylist.Value?.VideoSortType ?? VideoSortType.Register);
            this.IsDescending         = new ReactiveProperty <bool>(current.SelectedPlaylist.Value?.IsVideoDescending ?? false);
            this.IdColumnTitle        = new ReactiveProperty <string>(DefaultIdColumnTitle);
            this.TitleColumnTitle     = new ReactiveProperty <string>(DefaultTitleColumnTitle);
            this.UploadColumnTitle    = new ReactiveProperty <string>(DefaultUploadColumnTitle);
            this.DlFlagColumnTitle    = new ReactiveProperty <string>(DefaultDlFlagColumnTitle);
            this.ViewCountColumnTitle = new ReactiveProperty <string>(DefaultViewCountColumnTitle);
            this.StateColumnTitle     = new ReactiveProperty <string>(DefaultStateColumnTitle);
            this.EconomyColumnTitle   = new ReactiveProperty <string>(DefaultEconomyColumnTitle);
            this.SortTypeStr          = this.SortType.Select(value => value switch
            {
                VideoSortType.NiconicoID => DefaultIdColumnTitle,
                VideoSortType.Title => DefaultTitleColumnTitle,
                VideoSortType.UploadedDT => DefaultUploadColumnTitle,
                VideoSortType.ViewCount => DefaultViewCountColumnTitle,
                VideoSortType.Custom => "カスタム",
                VideoSortType.State => DefaultStateColumnTitle,
                VideoSortType.Economy => DefaultEconomyColumnTitle,
                _ => "登録順",
            }).ToReactiveProperty().AddTo(this.disposables);
Exemplo n.º 3
0
 public DeviceBatchManagementController(IDeviceService deviceService,
                                        ICurrent current, IDbContext dbContext,
                                        IConfiguration configuration,
                                        IMemoryCache memoryCache,
                                        IBackgroundJobManager backgroundJobManager,
                                        ILogger <DeviceBatchManagementController> logger,
                                        IMediator mediator,
                                        ICapPublisher capPublisher,
                                        TracerFactory tracerFactor,
                                        Tracer tracer,
                                        DbContextFactory dbContextFactory,
                                        ICache cache)
 {
     _deviceService        = deviceService;
     _current              = current;
     _dbContext            = dbContext;
     _configuration        = configuration;
     _logger               = logger;
     _backgroundJobManager = backgroundJobManager;
     _mediator             = mediator;
     _capBus               = capPublisher;
     _tracerFactory        = tracerFactor;
     _tracer               = tracer;
     _dbContextFactory     = dbContextFactory;
     _cache = cache;
 }
Exemplo n.º 4
0
 public RegisterDeviceHandler(ICurrent current, ITokenService tokenService, IDeviceService deviceService, ILogger <RegisterDeviceHandler> logger)
 {
     _current       = current;
     _tokenService  = tokenService;
     _deviceService = deviceService;
     _logger        = logger;
 }
Exemplo n.º 5
0
 protected HubBase(ICurrent current, IOnlineManager onlineManager, ILogger <HubBase> logger, IOptions <SysOptions> sysOptions)
 {
     Current       = current;
     OnlineManager = onlineManager;
     Logger        = logger;
     SysOptions    = sysOptions?.Value;
 }
Exemplo n.º 6
0
 public UpdateManagementController(IDeviceService deviceService, ICurrent current,
                                   IDbContext dbContext, IConfiguration configuration)
 {
     _deviceService = deviceService;
     _current       = current;
     _dbContext     = dbContext;
     _configuration = configuration;
 }
Exemplo n.º 7
0
 public OnlineVideoRefreshManager(ICurrent current, IVideoListContainer container, INetworkVideoHandler netVideoHandler, IRemotePlaylistHandler remotePlaylistHandler, IMessageHandler message, IVideosUnchecker unchecker)
 {
     this._current               = current;
     this._container             = container;
     this._netVideoHandler       = netVideoHandler;
     this._remotePlaylistHandler = remotePlaylistHandler;
     this._message               = message;
     this._unchcecker            = unchecker;
 }
Exemplo n.º 8
0
 public UserConsoleController(IDeviceService deviceService, ICurrent current, IUserService userService, IPushService pushService, DbContextFactory DbContextFactory, ICache cache)
 {
     _current          = current;
     _deviceService    = deviceService;
     _userService      = userService;
     _pushService      = pushService;
     _DbContextFactory = DbContextFactory;
     _cache            = cache;
 }
Exemplo n.º 9
0
 public DeviceController(IDeviceService deviceService, ICurrent current, IPushService pushService, IOnlineManager onlineManager, DbContextFactory DbContextFactory, IDbContext dbContext, ILogger <DeviceController> logger)
 {
     _current          = current;
     _deviceService    = deviceService;
     _pushService      = pushService;
     _onlineManager    = onlineManager;
     _dbContext        = dbContext;
     _DbContextFactory = DbContextFactory;
     _logger           = logger;
 }
 public DistributionController(
     IBookRepository _bookRepository,
     IBookCopysRepository _repo,
     ILibraryRepository _libraryRepository,
     ICurrent _current)
 {
     bookRepository = _bookRepository;
     repo = _repo;
     libraryRepository = _libraryRepository;
     current = _current;
 }
Exemplo n.º 11
0
 public DistributionController(
     IBookRepository _bookRepository,
     IBookCopysRepository _repo,
     ILibraryRepository _libraryRepository,
     ICurrent _current)
 {
     bookRepository    = _bookRepository;
     repo              = _repo;
     libraryRepository = _libraryRepository;
     current           = _current;
 }
Exemplo n.º 12
0
 public AccountController(
     Func <IFormsAuthenticationService> _authenticationService,
     Func <IMembershipService> _membershipService,
     ICurrent _current,
     Func <ILogger> _log, Func <IRepository <User> > _userRepository)
 {
     formsService      = _authenticationService;
     membershipService = _membershipService;
     current           = _current;
     log            = _log;
     userRepository = _userRepository;
 }
Exemplo n.º 13
0
 public AccountController(
     Func<IFormsAuthenticationService> _authenticationService,
     Func<IMembershipService> _membershipService,
     ICurrent _current,
     Func<ILogger> _log, Func<IRepository<User>> _userRepository)
 {
     formsService = _authenticationService;
     membershipService = _membershipService;
     current = _current;
     log = _log;
     userRepository = _userRepository;
 }
Exemplo n.º 14
0
 public PushService(ICurrent current, IOnlineManager onlineManager, ILogger <PushService> logger, ITokenService tokenService, IMediator mediator, IDeviceService deviceService, ITypeFinder typeFinder, ITypeResolve typeResolve, SignalrClient signalrClient, IOptions <SysOptions> options)
 {
     _tokenService  = tokenService;
     _mediator      = mediator;
     _deviceService = deviceService;
     _typeFinder    = typeFinder;
     _typeResolve   = typeResolve;
     _current       = current;
     _onlineManager = onlineManager;
     _logger        = logger;
     _signalrClient = signalrClient;
     _options       = options?.Value;
 }
Exemplo n.º 15
0
 public EventQueueJob(ILogger <EventQueueJob> logger, ICache cache, ICurrent current, IDataContainer dataContainer, ITypeFinder typeFinder, ITypeResolve typeResolve, IDeviceService deviceService, IDbContext dbContext, IEventQueueService eventQueueService, ICapPublisher capPublisher)
 {
     _logger            = logger;
     _cache             = cache;
     _current           = current;
     _dataContainer     = dataContainer;
     _typeFinder        = typeFinder;
     _typeResolve       = typeResolve;
     _deviceService     = deviceService;
     _dbContext         = dbContext;
     _eventQueueService = eventQueueService;
     _capBus            = capPublisher;
 }
Exemplo n.º 16
0
        public DownloadSettingsHandler(ILocalSettingHandler settingHandler, ICurrent current, IEnumSettingsHandler enumSettingsHandler, ILocalSettingsContainer container)
        {
            this.settingHandler      = settingHandler;
            this.current             = current;
            this.enumSettingsHandler = enumSettingsHandler;
            this._container          = container;

            this.IsDownloadingVideoInfoEnable  = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLVideoInfo)).AddTo(this.disposables);
            this.IsLimittingCommentCountEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.LimitCommentsCount)).AddTo(this.disposables);
            this.IsDownloadingVideoEnable      = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLVideo)).AddTo(this.disposables);
            this.IsDownloadingCommentEnable    = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLComment)).AddTo(this.disposables);
            this.IsDownloadingCommentLogEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLKako)).AddTo(this.disposables);
            this.IsDownloadingEasyComment      = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLEasy)).AddTo(this.disposables);
            this.IsDownloadingThumbEnable      = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLThumb)).AddTo(this.disposables);
            this.IsDownloadingOwnerComment     = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLOwner)).AddTo(this.disposables);
            this.IsOverwriteEnable             = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLOverwrite)).AddTo(this.disposables);
            this.IsSkippingEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLSkip)).AddTo(this.disposables);
            this.IsCopyFromAnotherFolderEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DLCopy)).AddTo(this.disposables);
            this.IsLimittingCommentCountEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.LimitCommentsCount)).AddTo(this.disposables);
            this.MaxCommentsCount = new ReactiveProperty <int>(this.settingHandler.GetIntSetting(SettingsEnum.MaxCommentsCount)).AddTo(this.disposables);
            this.IsNoEncodeEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DlWithoutEncode)).AddTo(this.disposables);
            this.IsDownloadingIchibaInfoEnable = new ReactiveProperty <bool>(this.settingHandler.GetBoolSetting(SettingsEnum.DlIchiba)).AddTo(this.disposables);
            this.ThumbnailSize            = new ReactiveProperty <VideoInfo::ThumbSize>(this.enumSettingsHandler.GetSetting <VideoInfo::ThumbSize>());
            this.IsAppendingCommentEnable = this._container.GetReactiveBoolSetting(SettingsEnum.AppendComment);

            this.IsDownloadingVideoInfoEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLVideoInfo));
            this.IsDownloadingVideoEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLVideo));
            this.IsDownloadingCommentEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLComment));
            this.IsDownloadingCommentLogEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLKako));
            this.IsDownloadingEasyComment.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLEasy));
            this.IsDownloadingThumbEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLThumb));
            this.IsDownloadingOwnerComment.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLOwner));
            this.IsOverwriteEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLOverwrite));
            this.IsSkippingEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLSkip));
            this.IsCopyFromAnotherFolderEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DLCopy));
            this.IsLimittingCommentCountEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.LimitCommentsCount));
            this.MaxCommentsCount.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.MaxCommentsCount));
            this.IsNoEncodeEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DlWithoutEncode));
            this.IsDownloadingIchibaInfoEnable.Subscribe(value => this.settingHandler.SaveSetting(value, SettingsEnum.DlIchiba));
            this.ThumbnailSize.Subscribe(value => this.enumSettingsHandler.SaveSetting(value));

            this.Resolution = new ReactiveProperty <VideoInfo::IResolution>(new VideoInfo::Resolution("1920x1080"));
        }
Exemplo n.º 17
0
        public BorrowerViewModel(
            Func<IBorrowerRepository> _borrowerRepository,
            Func<IStudentRepository> _studentRepository,
            Func<IBookCopysRepository> _bookCopyRepository,
            ICurrent _current, IBusy status)
        {
            Status = status;
            Status.Busy = true;
            borrowerRepository = _borrowerRepository;
            studentRepository = _studentRepository;
            bookCopyRepository = _bookCopyRepository;
            current = _current;

            Task.Factory.StartNew(() =>
                {
                    Borrowers =
                        borrowerRepository().GetAll(
                            c => !c.Return.HasValue && c.BookCopy.LibraryID == current.CurrentUser.LibraryID).
                            ToObservable();
                    Status.Busy = false;
                });
        }
Exemplo n.º 18
0
 public DeviceHub(ICurrent current, ICache cache, IDbContext dbContext, IDatabaseHelper databaseHelper, IDataContainer dataContainer, SignalrClient signalrClient, IOnlineManager onlineManager, ILogger <DeviceHub> logger, ITokenService tokenService, IDeviceService deviceService, ITypeFinder typeFinder, ITypeResolve typeResolve, IMediator mediator, IHttpContextAccessor httpContextAccessor, IPackStore <HttpLog> logStore, IPackStore <TimeData> monitorTimeDataManager, Tracer tracer, TracerFactory tracerFactor, IOptions <MonitorOptions> settings, DbContextFactory dbContextFactory, IOptions <SysOptions> sysOptions, IOptions <HangfireOptions> hangfireOption = null) : base(current, onlineManager, logger, sysOptions)
 {
     _tokenService           = tokenService;
     _deviceService          = deviceService;
     _typeFinder             = typeFinder;
     _typeResolve            = typeResolve;
     _mediator               = mediator;
     _httpContextAccessor    = httpContextAccessor;
     _logStore               = logStore;
     _monitorTimeDataManager = monitorTimeDataManager;
     _tracer           = tracer;//tracerFactor.GetTracer( "syinpo-signalr-tracer"+CommonHelper.NewSequentialGuid() );
     _tracerFactory    = tracerFactor;
     _settings         = settings;
     _hangfireOptions  = hangfireOption.Value;
     _dbContextFactory = dbContextFactory;
     _cache            = cache;
     _dbContext        = dbContext;
     _databaseHelper   = databaseHelper;
     _dataContainer    = dataContainer;
     _signalrClient    = signalrClient;
     _logger           = logger;
 }
Exemplo n.º 19
0
 public HomeController(
     ICurrent current,
     IOnlineManager onlineManager,
     ILogger <HomeController> logger,
     ITokenService tokenService,
     IDeviceService deviceService,
     ITypeFinder typeFinder,
     ITypeResolve typeResolve,
     IDbContext dbContext,
     DbContextFactory dbContextFactory,
     ICache cache,
     IBackgroundJobManager backgroundJobManager)
 {
     _current              = current;
     _tokenService         = tokenService;
     _deviceService        = deviceService;
     _typeFinder           = typeFinder;
     _typeResolve          = typeResolve;
     _dbContext            = dbContext;
     _dbContextFactory     = dbContextFactory;
     _cache                = cache;
     _backgroundJobManager = backgroundJobManager;
 }
Exemplo n.º 20
0
        public BorrowerViewModel(
            Func <IBorrowerRepository> _borrowerRepository,
            Func <IStudentRepository> _studentRepository,
            Func <IBookCopysRepository> _bookCopyRepository,
            ICurrent _current, IBusy status)
        {
            Status             = status;
            Status.Busy        = true;
            borrowerRepository = _borrowerRepository;
            studentRepository  = _studentRepository;
            bookCopyRepository = _bookCopyRepository;
            current            = _current;


            Task.Factory.StartNew(() =>
            {
                Borrowers =
                    borrowerRepository().GetAll(
                        c => !c.Return.HasValue && c.BookCopy.LibraryID == current.CurrentUser.LibraryID).
                    ToObservable();
                Status.Busy = false;
            });
        }
Exemplo n.º 21
0
 public BookService(ICurrent _current)
 {
     current = _current;
 }
Exemplo n.º 22
0
 public CorporateMembership(IRepository<User> repository, ICurrent current)
 {
     mRepository = repository;
     mCurrent = current;
 }
Exemplo n.º 23
0
 public CorporateRoleMembership()
 {
     mCurrent = DependencyResolver.Current.GetService<ICurrent>();
 }
 public DistributionAPIController(IBookCopysRepository _bookcopyRepository, ICurrent _current)
 {
     bookcopyRepository = _bookcopyRepository;
     current = _current;
 }
Exemplo n.º 25
0
 public void Init(ActionExecutingContext actionExecutingContext, ICache cache, ICurrent current)
 {
     _actionExecutingContext = actionExecutingContext;
     _cache   = cache;
     _current = current;
 }
Exemplo n.º 26
0
 public VideoListRefresher(IPlaylistStoreHandler playlistStoreHandler, IVideoHandler videoHandler, ILocalVideoUtils localVideoUtils, IVideoThumnailUtility videoThumnailUtility, ICurrent current, ILightVideoListinfoHandler lightVideoListinfoHandler, ILocalSettingsContainer container)
 {
     this._playlistStoreHandler = playlistStoreHandler;
     this._videoHandler         = videoHandler;
     this._current = current;
     this._videoThumnailUtility      = videoThumnailUtility;
     this._localVideoUtils           = localVideoUtils;
     this._lightVideoListinfoHandler = lightVideoListinfoHandler;
     this._settingsContainer         = container;
 }
Exemplo n.º 27
0
 public LightVideoListinfoHandler(ICurrent current)
 {
     this.current = current;
 }
Exemplo n.º 28
0
        public VideoListContainer(IPlaylistHandler playlistHandler, IVideoHandler videoHandler, IVideoListRefresher refresher, ICurrent current, ILogger logger)
        {
            this.videoHandler     = videoHandler;
            this.refresher        = refresher;
            this.current          = current;
            this.logger           = logger;
            this.Videos           = new ObservableCollection <IListVideoInfo>();
            this._playlistHandler = playlistHandler;

            this.current.IsTemporaryPlaylist.Subscribe(value =>
            {
                if (value)
                {
                    this.Clear();
                }
            });
        }
Exemplo n.º 29
0
 public VideoRegistrationHandler(IVideoIDHandler idHandler, IMessageHandler messageHandler, ICurrent current, IVideoListContainer container)
 {
     this.IsProcessing    = idHandler.IsProcessing.ToReadOnlyReactivePropertySlim();
     this._idHandler      = idHandler;
     this._messageHandler = messageHandler;
     this._currrent       = current;
     this._container      = container;
 }
Exemplo n.º 30
0
 public CorporateRoleMembership()
 {
     mCurrent = DependencyResolver.Current.GetService <ICurrent>();
 }
Exemplo n.º 31
0
 public NotCacheableSwitchFilter(ICurrent current, DbContextFactory dbContextFactory, IDatabaseHelper databaseHelper)
 {
     _current          = current;
     _dbContextFactory = dbContextFactory;
     _databaseHelper   = databaseHelper;
 }
Exemplo n.º 32
0
 public CorporateMembership(IRepository <User> repository, ICurrent current)
 {
     mRepository = repository;
     mCurrent    = current;
 }
Exemplo n.º 33
0
 public AdminAuthorizeFilter(ICurrent current, IUserService userService)
 {
     _current     = current;
     _userService = userService;
 }
Exemplo n.º 34
0
 public ExternalAppUtils(ICurrent current, ICommandExecuter commandExecuter, ILocalSettingHandler localSettingHandler)
 {
     this.current             = current;
     this.commandExecuter     = commandExecuter;
     this.localSettingHandler = localSettingHandler;
 }
Exemplo n.º 35
0
 public FirewallFilter(ICache cache, ICurrent current, IOptions <SysOptions> options)
 {
     _cache   = cache;
     _current = current;
     _options = options?.Value;
 }
Exemplo n.º 36
0
 public CommnadMessage(ICommand command, string commandName, ICurrent current)
 {
     Command = command;
     CommandName = commandName;
     Current = current;
 }
Exemplo n.º 37
0
 public DistributionAPIController(IBookCopysRepository _bookcopyRepository, ICurrent _current)
 {
     bookcopyRepository = _bookcopyRepository;
     current            = _current;
 }