public RefreshAlbumService(IAlbumService albumService, IArtistService artistService, IAddArtistService addArtistService, IArtistMetadataService artistMetadataService, IReleaseService releaseService, IProvideAlbumInfo albumInfo, IRefreshAlbumReleaseService refreshAlbumReleaseService, IMediaFileService mediaFileService, IHistoryService historyService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, ICheckIfAlbumShouldBeRefreshed checkIfAlbumShouldBeRefreshed, IMapCoversToLocal mediaCoverService, Logger logger) : base(logger, artistMetadataService) { _albumService = albumService; _artistService = artistService; _addArtistService = addArtistService; _releaseService = releaseService; _albumInfo = albumInfo; _refreshAlbumReleaseService = refreshAlbumReleaseService; _mediaFileService = mediaFileService; _historyService = historyService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _checkIfAlbumShouldBeRefreshed = checkIfAlbumShouldBeRefreshed; _mediaCoverService = mediaCoverService; _logger = logger; }
public MovieModule(IBroadcastSignalRMessage signalRBroadcaster, IMovieService moviesService, IMovieTranslationService movieTranslationService, IAddMovieService addMovieService, IMapCoversToLocal coverMapper, IManageCommandQueue commandQueueManager, IUpgradableSpecification qualityUpgradableSpecification, IConfigService configService, RootFolderValidator rootFolderValidator, MappedNetworkDriveValidator mappedNetworkDriveValidator, MoviePathValidator moviesPathValidator, MovieExistsValidator moviesExistsValidator, MovieAncestorValidator moviesAncestorValidator, RecycleBinValidator recycleBinValidator, SystemFolderValidator systemFolderValidator, ProfileExistsValidator profileExistsValidator, MovieFolderAsRootFolderValidator movieFolderAsRootFolderValidator, Logger logger) : base(signalRBroadcaster) { _moviesService = moviesService; _movieTranslationService = movieTranslationService; _addMovieService = addMovieService; _qualityUpgradableSpecification = qualityUpgradableSpecification; _configService = configService; _coverMapper = coverMapper; _commandQueueManager = commandQueueManager; _logger = logger; GetResourceAll = AllMovie; GetResourceById = GetMovie; CreateResource = AddMovie; UpdateResource = UpdateMovie; DeleteResource = DeleteMovie; SharedValidator.RuleFor(s => s.QualityProfileId).ValidId(); SharedValidator.RuleFor(s => s.Path) .Cascade(CascadeMode.StopOnFirstFailure) .IsValidPath() .SetValidator(rootFolderValidator) .SetValidator(mappedNetworkDriveValidator) .SetValidator(moviesPathValidator) .SetValidator(moviesAncestorValidator) .SetValidator(recycleBinValidator) .SetValidator(systemFolderValidator) .When(s => !s.Path.IsNullOrWhiteSpace()); SharedValidator.RuleFor(s => s.QualityProfileId).SetValidator(profileExistsValidator); PostValidator.RuleFor(s => s.Path).IsValidPath().When(s => s.RootFolderPath.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.RootFolderPath) .IsValidPath() .SetValidator(movieFolderAsRootFolderValidator) .When(s => s.Path.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.Title).NotEmpty().When(s => s.TmdbId <= 0); PostValidator.RuleFor(s => s.TmdbId).NotNull().NotEmpty().SetValidator(moviesExistsValidator); PutValidator.RuleFor(s => s.Path).IsValidPath(); }
public ImportListSyncService(IImportListFactory importListFactory, IImportListExclusionService importListExclusionService, IFetchAndParseImportList listFetcherAndParser, IGoodreadsProxy goodreadsProxy, IGoodreadsSearchProxy goodreadsSearchProxy, IAuthorService authorService, IBookService bookService, IEditionService editionService, IAddAuthorService addAuthorService, IAddBookService addBookService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, Logger logger) { _importListFactory = importListFactory; _importListExclusionService = importListExclusionService; _listFetcherAndParser = listFetcherAndParser; _goodreadsProxy = goodreadsProxy; _goodreadsSearchProxy = goodreadsSearchProxy; _authorService = authorService; _bookService = bookService; _editionService = editionService; _addAuthorService = addAuthorService; _addBookService = addBookService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _logger = logger; }
public ImportListSyncService(IImportListFactory importListFactory, IImportListExclusionService importListExclusionService, IFetchAndParseImportList listFetcherAndParser, ISearchForNewAlbum albumSearchService, ISearchForNewArtist artistSearchService, IArtistService artistService, IAlbumService albumService, IAddArtistService addArtistService, IAddAlbumService addAlbumService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, Logger logger) { _importListFactory = importListFactory; _importListExclusionService = importListExclusionService; _listFetcherAndParser = listFetcherAndParser; _albumSearchService = albumSearchService; _artistSearchService = artistSearchService; _artistService = artistService; _albumService = albumService; _addArtistService = addArtistService; _addAlbumService = addAlbumService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _logger = logger; }
public RefreshArtistService(IProvideArtistInfo artistInfo, IArtistService artistService, IArtistMetadataService artistMetadataService, IAlbumService albumService, IRefreshAlbumService refreshAlbumService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, IMediaFileService mediaFileService, IHistoryService historyService, IRootFolderService rootFolderService, ICheckIfArtistShouldBeRefreshed checkIfArtistShouldBeRefreshed, IConfigService configService, IImportListExclusionService importListExclusionService, Logger logger) : base(logger, artistMetadataService) { _artistInfo = artistInfo; _artistService = artistService; _albumService = albumService; _refreshAlbumService = refreshAlbumService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _mediaFileService = mediaFileService; _historyService = historyService; _rootFolderService = rootFolderService; _checkIfArtistShouldBeRefreshed = checkIfArtistShouldBeRefreshed; _configService = configService; _importListExclusionService = importListExclusionService; _logger = logger; }
public ImportApprovedBooks(IUpgradeMediaFiles bookFileUpgrader, IMediaFileService mediaFileService, IAudioTagService audioTagService, IAuthorService authorService, IAddAuthorService addAuthorService, IRefreshAuthorService refreshAuthorService, IBookService bookService, IEditionService editionService, IRootFolderService rootFolderService, IRecycleBinProvider recycleBinProvider, IExtraService extraService, IDiskProvider diskProvider, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, Logger logger) { _bookFileUpgrader = bookFileUpgrader; _mediaFileService = mediaFileService; _audioTagService = audioTagService; _authorService = authorService; _addAuthorService = addAuthorService; _refreshAuthorService = refreshAuthorService; _bookService = bookService; _editionService = editionService; _rootFolderService = rootFolderService; _recycleBinProvider = recycleBinProvider; _extraService = extraService; _diskProvider = diskProvider; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _logger = logger; }
public ImportListSyncService(IImportListFactory importListFactory, IImportListExclusionService importListExclusionService, IFetchAndParseImportList listFetcherAndParser, ISearchForNewBook bookSearchService, ISearchForNewAuthor authorSearchService, IAuthorService authorService, IBookService bookService, IAddAuthorService addAuthorService, IAddBookService addBookService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, Logger logger) { _importListFactory = importListFactory; _importListExclusionService = importListExclusionService; _listFetcherAndParser = listFetcherAndParser; _bookSearchService = bookSearchService; _authorSearchService = authorSearchService; _authorService = authorService; _bookService = bookService; _addAuthorService = addAuthorService; _addBookService = addBookService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _logger = logger; }
public ImportApprovedTracks(IUpgradeMediaFiles trackFileUpgrader, IMediaFileService mediaFileService, IAudioTagService audioTagService, ITrackService trackService, IArtistService artistService, IAddArtistService addArtistService, IAlbumService albumService, IRefreshAlbumService refreshAlbumService, IRootFolderService rootFolderService, IRecycleBinProvider recycleBinProvider, IExtraService extraService, IDiskProvider diskProvider, IReleaseService releaseService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, Logger logger) { _trackFileUpgrader = trackFileUpgrader; _mediaFileService = mediaFileService; _audioTagService = audioTagService; _trackService = trackService; _artistService = artistService; _addArtistService = addArtistService; _albumService = albumService; _refreshAlbumService = refreshAlbumService; _rootFolderService = rootFolderService; _recycleBinProvider = recycleBinProvider; _extraService = extraService; _diskProvider = diskProvider; _releaseService = releaseService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _logger = logger; }
public RefreshAuthorService(IProvideAuthorInfo authorInfo, IAuthorService authorService, IAuthorMetadataService authorMetadataService, IBookService bookService, IMetadataProfileService metadataProfileService, IRefreshBookService refreshBookService, IRefreshSeriesService refreshSeriesService, IEventAggregator eventAggregator, IManageCommandQueue commandQueueManager, IMediaFileService mediaFileService, IHistoryService historyService, IRootFolderService rootFolderService, ICheckIfAuthorShouldBeRefreshed checkIfAuthorShouldBeRefreshed, IConfigService configService, IImportListExclusionService importListExclusionService, Logger logger) : base(logger, authorMetadataService) { _authorInfo = authorInfo; _authorService = authorService; _bookService = bookService; _metadataProfileService = metadataProfileService; _refreshBookService = refreshBookService; _refreshSeriesService = refreshSeriesService; _eventAggregator = eventAggregator; _commandQueueManager = commandQueueManager; _mediaFileService = mediaFileService; _historyService = historyService; _rootFolderService = rootFolderService; _checkIfAuthorShouldBeRefreshed = checkIfAuthorShouldBeRefreshed; _configService = configService; _importListExclusionService = importListExclusionService; _logger = logger; }
public SeriesModule(IBroadcastSignalRMessage signalRBroadcaster, ISeriesService seriesService, IAddSeriesService addSeriesService, ISeriesStatisticsService seriesStatisticsService, ISceneMappingService sceneMappingService, IMapCoversToLocal coverMapper, IManageCommandQueue commandQueueManager, IRootFolderService rootFolderService, RootFolderValidator rootFolderValidator, MappedNetworkDriveValidator mappedNetworkDriveValidator, SeriesPathValidator seriesPathValidator, SeriesExistsValidator seriesExistsValidator, SeriesAncestorValidator seriesAncestorValidator, SystemFolderValidator systemFolderValidator, ProfileExistsValidator profileExistsValidator, LanguageProfileExistsValidator languageProfileExistsValidator, SeriesFolderAsRootFolderValidator seriesFolderAsRootFolderValidator ) : base(signalRBroadcaster) { _seriesService = seriesService; _addSeriesService = addSeriesService; _seriesStatisticsService = seriesStatisticsService; _sceneMappingService = sceneMappingService; _coverMapper = coverMapper; _commandQueueManager = commandQueueManager; _rootFolderService = rootFolderService; GetResourceAll = AllSeries; GetResourceById = GetSeries; CreateResource = AddSeries; UpdateResource = UpdateSeries; DeleteResource = DeleteSeries; Http.Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.QualityProfileId)); SharedValidator.RuleFor(s => s.Path) .Cascade(CascadeMode.StopOnFirstFailure) .IsValidPath() .SetValidator(rootFolderValidator) .SetValidator(mappedNetworkDriveValidator) .SetValidator(seriesPathValidator) .SetValidator(seriesAncestorValidator) .SetValidator(systemFolderValidator) .When(s => !s.Path.IsNullOrWhiteSpace()); SharedValidator.RuleFor(s => s.QualityProfileId).SetValidator(profileExistsValidator); SharedValidator.RuleFor(s => s.LanguageProfileId).SetValidator(languageProfileExistsValidator); PostValidator.RuleFor(s => s.Path).IsValidPath().When(s => s.RootFolderPath.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.RootFolderPath) .IsValidPath() .SetValidator(seriesFolderAsRootFolderValidator) .When(s => s.Path.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.Title).NotEmpty(); PostValidator.RuleFor(s => s.TvdbId).GreaterThan(0).SetValidator(seriesExistsValidator); PutValidator.RuleFor(s => s.Path).IsValidPath(); }
public MovieScannedHandler(IMovieService movieService, IManageCommandQueue commandQueueManager, Logger logger) { _movieService = movieService; _commandQueueManager = commandQueueManager; _logger = logger; }
public AuthorEditorModule(IAuthorService authorService, IManageCommandQueue commandQueueManager) : base("/author/editor") { _authorService = authorService; _commandQueueManager = commandQueueManager; Put("/", author => SaveAll()); Delete("/", author => DeleteAuthor()); }
public RedownloadFailedDownloadService(IConfigService configService, IManageCommandQueue commandQueueManager, Logger logger) { _configService = configService; _commandQueueManager = commandQueueManager; _logger = logger; }
public SeriesEditorModule(ISeriesService seriesService, IManageCommandQueue commandQueueManager) : base("/series/editor") { _seriesService = seriesService; _commandQueueManager = commandQueueManager; Put("/", series => SaveAll()); Delete("/", series => DeleteSeries()); }
public ArtistEditorModule(IArtistService artistService, IManageCommandQueue commandQueueManager) : base("/artist/editor") { _artistService = artistService; _commandQueueManager = commandQueueManager; Put("/", artist => SaveAll()); Delete("/", artist => DeleteArtist()); }
public MovieEditorModule(IMovieService movieService, IManageCommandQueue commandQueueManager, IUpgradableSpecification upgradableSpecification) : base("/movie/editor") { _movieService = movieService; _commandQueueManager = commandQueueManager; _upgradableSpecification = upgradableSpecification; Put("/", movie => SaveAll()); Delete("/", movie => DeleteMovies()); }
public ArtistModule(IBroadcastSignalRMessage signalRBroadcaster, IArtistService artistService, IAlbumService albumService, IAddArtistService addArtistService, IArtistStatisticsService artistStatisticsService, IMapCoversToLocal coverMapper, IManageCommandQueue commandQueueManager, IRootFolderService rootFolderService, RootFolderValidator rootFolderValidator, MappedNetworkDriveValidator mappedNetworkDriveValidator, ArtistPathValidator artistPathValidator, ArtistExistsValidator artistExistsValidator, ArtistAncestorValidator artistAncestorValidator, SystemFolderValidator systemFolderValidator, ProfileExistsValidator profileExistsValidator, MetadataProfileExistsValidator metadataProfileExistsValidator ) : base(signalRBroadcaster) { _artistService = artistService; _albumService = albumService; _addArtistService = addArtistService; _artistStatisticsService = artistStatisticsService; _coverMapper = coverMapper; _commandQueueManager = commandQueueManager; _rootFolderService = rootFolderService; GetResourceAll = AllArtists; GetResourceById = GetArtist; CreateResource = AddArtist; UpdateResource = UpdateArtist; DeleteResource = DeleteArtist; Http.Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.QualityProfileId)); Http.Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.MetadataProfileId)); SharedValidator.RuleFor(s => s.Path) .Cascade(CascadeMode.StopOnFirstFailure) .IsValidPath() .SetValidator(rootFolderValidator) .SetValidator(mappedNetworkDriveValidator) .SetValidator(artistPathValidator) .SetValidator(artistAncestorValidator) .SetValidator(systemFolderValidator) .When(s => !s.Path.IsNullOrWhiteSpace()); SharedValidator.RuleFor(s => s.QualityProfileId).SetValidator(profileExistsValidator); SharedValidator.RuleFor(s => s.MetadataProfileId).SetValidator(metadataProfileExistsValidator); PostValidator.RuleFor(s => s.Path).IsValidPath().When(s => s.RootFolderPath.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.RootFolderPath).IsValidPath().When(s => s.Path.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.ArtistName).NotEmpty(); PostValidator.RuleFor(s => s.ForeignArtistId).NotEmpty().SetValidator(artistExistsValidator); PutValidator.RuleFor(s => s.Path).IsValidPath(); }
public BookAddedService(ICacheManager cacheManager, IManageCommandQueue commandQueueManager, IBookService bookService, Logger logger) { _commandQueueManager = commandQueueManager; _bookService = bookService; _logger = logger; _addedBooksCache = cacheManager.GetCache <List <int> >(GetType()); }
public RootFolderService(IRootFolderRepository rootFolderRepository, IDiskProvider diskProvider, IManageCommandQueue commandQueueManager, Logger logger) { _rootFolderRepository = rootFolderRepository; _diskProvider = diskProvider; _commandQueueManager = commandQueueManager; _logger = logger; }
public EpisodeAddedService(ICacheManager cacheManager, IManageCommandQueue commandQueueManager, IEpisodeService episodeService, Logger logger) { _commandQueueManager = commandQueueManager; _episodeService = episodeService; _logger = logger; _addedEpisodesCache = cacheManager.GetCache <List <int> >(GetType()); }
public AlbumAddedService(ICacheManager cacheManager, IManageCommandQueue commandQueueManager, IAlbumService albumService, Logger logger) { _commandQueueManager = commandQueueManager; _albumService = albumService; _logger = logger; _addedAlbumsCache = cacheManager.GetCache <List <int> >(GetType()); }
public CommandExecutor(IServiceFactory serviceFactory, IManageCommandQueue commandQueueManager, IEventAggregator eventAggregator, Logger logger) { _logger = logger; _serviceFactory = serviceFactory; _commandQueueManager = commandQueueManager; _eventAggregator = eventAggregator; }
public ArtistScannedHandler(IAlbumMonitoredService albumMonitoredService, IArtistService artistService, IManageCommandQueue commandQueueManager, IAlbumAddedService albumAddedService, Logger logger) { _albumMonitoredService = albumMonitoredService; _artistService = artistService; _commandQueueManager = commandQueueManager; _albumAddedService = albumAddedService; _logger = logger; }
public RootFolderWatchingService(IRootFolderService rootFolderService, IManageCommandQueue commandQueueManager, IConfigService configService, Logger logger) { _rootFolderService = rootFolderService; _commandQueueManager = commandQueueManager; _configService = configService; _logger = logger; _scanDebouncer = new Debouncer(ScanPending, TimeSpan.FromSeconds(DEBOUNCE_TIMEOUT_SECONDS), true); }
public SeriesScannedHandler(IEpisodeMonitoredService episodeMonitoredService, ISeriesService seriesService, IManageCommandQueue commandQueueManager, IEpisodeAddedService episodeAddedService, Logger logger) { _episodeMonitoredService = episodeMonitoredService; _seriesService = seriesService; _commandQueueManager = commandQueueManager; _episodeAddedService = episodeAddedService; _logger = logger; }
public AuthorScannedHandler(IBookMonitoredService bookMonitoredService, IAuthorService authorService, IManageCommandQueue commandQueueManager, IBookAddedService bookAddedService, Logger logger) { _bookMonitoredService = bookMonitoredService; _authorService = authorService; _commandQueueManager = commandQueueManager; _bookAddedService = bookAddedService; _logger = logger; }
public AuthorController(IBroadcastSignalRMessage signalRBroadcaster, IAuthorService authorService, IBookService bookService, IAddAuthorService addAuthorService, IAuthorStatisticsService authorStatisticsService, IMapCoversToLocal coverMapper, IManageCommandQueue commandQueueManager, IRootFolderService rootFolderService, RecycleBinValidator recycleBinValidator, RootFolderValidator rootFolderValidator, MappedNetworkDriveValidator mappedNetworkDriveValidator, AuthorPathValidator authorPathValidator, AuthorExistsValidator authorExistsValidator, AuthorAncestorValidator authorAncestorValidator, SystemFolderValidator systemFolderValidator, QualityProfileExistsValidator qualityProfileExistsValidator, MetadataProfileExistsValidator metadataProfileExistsValidator) : base(signalRBroadcaster) { _authorService = authorService; _bookService = bookService; _addAuthorService = addAuthorService; _authorStatisticsService = authorStatisticsService; _coverMapper = coverMapper; _commandQueueManager = commandQueueManager; _rootFolderService = rootFolderService; Http.Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.QualityProfileId)); Http.Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.MetadataProfileId)); SharedValidator.RuleFor(s => s.Path) .Cascade(CascadeMode.StopOnFirstFailure) .IsValidPath() .SetValidator(rootFolderValidator) .SetValidator(mappedNetworkDriveValidator) .SetValidator(authorPathValidator) .SetValidator(authorAncestorValidator) .SetValidator(recycleBinValidator) .SetValidator(systemFolderValidator) .When(s => !s.Path.IsNullOrWhiteSpace()); SharedValidator.RuleFor(s => s.QualityProfileId).SetValidator(qualityProfileExistsValidator); SharedValidator.RuleFor(s => s.MetadataProfileId).SetValidator(metadataProfileExistsValidator); PostValidator.RuleFor(s => s.Path).IsValidPath().When(s => s.RootFolderPath.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.RootFolderPath).IsValidPath().When(s => s.Path.IsNullOrWhiteSpace()); PostValidator.RuleFor(s => s.AuthorName).NotEmpty(); PostValidator.RuleFor(s => s.ForeignAuthorId).NotEmpty().SetValidator(authorExistsValidator); PutValidator.RuleFor(s => s.Path).IsValidPath(); }
public CommandController(IManageCommandQueue commandQueueManager, IBroadcastSignalRMessage signalRBroadcaster, KnownTypes knownTypes) : base(signalRBroadcaster) { _commandQueueManager = commandQueueManager; _knownTypes = knownTypes; _debouncer = new Debouncer(SendUpdates, TimeSpan.FromSeconds(0.1)); _pendingUpdates = new Dictionary <int, CommandResource>(); PostValidator.RuleFor(c => c.Name).NotBlank(); }
public CommandModule(IManageCommandQueue commandQueueManager, IBroadcastSignalRMessage signalRBroadcaster, IServiceFactory serviceFactory) : base(signalRBroadcaster) { _commandQueueManager = commandQueueManager; _serviceFactory = serviceFactory; GetResourceById = GetCommand; CreateResource = StartCommand; GetResourceAll = GetStartedCommands; PostValidator.RuleFor(c => c.Name).NotBlank(); }
public CommandModule(IManageCommandQueue commandQueueManager, IBroadcastSignalRMessage signalRBroadcaster, IServiceFactory serviceFactory) : base(signalRBroadcaster) { _commandQueueManager = commandQueueManager; _serviceFactory = serviceFactory; GetResourceById = GetCommand; CreateResource = StartCommand; GetResourceAll = GetStartedCommands; PostValidator.RuleFor(c => c.Name).NotBlank(); _debouncer = new Debouncer(SendUpdates, TimeSpan.FromSeconds(0.1)); _pendingUpdates = new Dictionary <int, CommandResource>(); }
public CleanupCommandQueue(IManageCommandQueue commandQueueManager) { _commandQueueManager = commandQueueManager; }