public PismoInstaller(IHttpClient httpClient, ILogger logger, IApplicationPaths appPaths, IZipClient zipClient)
 {
     _httpClient = httpClient;
     _logger = logger;
     _appPaths = appPaths;
     _zipClient = zipClient;
 }
Esempio n. 2
0
 public ImageEncoder(string ffmpegPath, ILogger logger, IFileSystem fileSystem, IApplicationPaths appPaths)
 {
     _ffmpegPath = ffmpegPath;
     _logger = logger;
     _fileSystem = fileSystem;
     _appPaths = appPaths;
 }
Esempio n. 3
0
        public static void Init(IApplicationPaths appPaths, INetworkManager networkManager)
        {
            // Ugly alert (static init)

            _appPaths = appPaths;
            _networkManager = networkManager;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="SqliteItemRepository"/> class.
        /// </summary>
        /// <param name="appPaths">The app paths.</param>
        /// <param name="jsonSerializer">The json serializer.</param>
        /// <param name="logManager">The log manager.</param>
        /// <exception cref="System.ArgumentNullException">
        /// appPaths
        /// or
        /// jsonSerializer
        /// </exception>
        public SqliteItemRepository(IApplicationPaths appPaths, IJsonSerializer jsonSerializer, ILogManager logManager)
        {
            if (appPaths == null)
            {
                throw new ArgumentNullException("appPaths");
            }
            if (jsonSerializer == null)
            {
                throw new ArgumentNullException("jsonSerializer");
            }

            _appPaths = appPaths;
            _jsonSerializer = jsonSerializer;

            _criticReviewsPath = Path.Combine(_appPaths.DataPath, "critic-reviews");

            _logger = logManager.GetLogger(GetType().Name);

            var chapterDbFile = Path.Combine(_appPaths.DataPath, "chapters.db");
            var chapterConnection = SqliteExtensions.ConnectToDb(chapterDbFile, _logger).Result;
            _chapterRepository = new SqliteChapterRepository(chapterConnection, logManager);

            var mediaStreamsDbFile = Path.Combine(_appPaths.DataPath, "mediainfo.db");
            var mediaStreamsConnection = SqliteExtensions.ConnectToDb(mediaStreamsDbFile, _logger).Result;
            _mediaStreamsRepository = new SqliteMediaStreamsRepository(mediaStreamsConnection, logManager);

            var providerInfosDbFile = Path.Combine(_appPaths.DataPath, "providerinfo.db");
            var providerInfoConnection = SqliteExtensions.ConnectToDb(providerInfosDbFile, _logger).Result;
            _providerInfoRepository = new SqliteProviderInfoRepository(providerInfoConnection, logManager);
        }
        //public URCOMLoader PrivateCom
        //{
        //    get
        //    {
        //        return _privateCom;
        //    }
        //}

        public InternalDirectShowPlayer(
            ILogManager logManager
            , MainBaseForm hostForm
            //, IPresentationManager presentation
            //, ISessionManager sessionManager
            , IApplicationPaths appPaths
            , IIsoManager isoManager
            //, IUserInputManager inputManager
            , IZipClient zipClient
            , IHttpClient httpClient, IConfigurationManager configurationManager)
        {
            _logger = logManager.GetLogger("InternalDirectShowPlayer");
            _hostForm = hostForm;
            //_presentation = presentation;
            //_sessionManager = sessionManager;
            _httpClient = httpClient;
            _config = configurationManager;
            _isoManager = isoManager;
            //_inputManager = inputManager;
            _zipClient = zipClient;

            var config = GetConfiguration();

            config.VideoConfig.SetDefaults();
            config.AudioConfig.SetDefaults();
            config.SubtitleConfig.SetDefaults();
            config.COMConfig.SetDefaults();

            //use a static object so we keep the libraries in the same place. Doesn't usually matter, but the EVR Presenter does some COM hooking that has problems if we change the lib address.
            //if (_privateCom == null)
            //    _privateCom = new URCOMLoader(_config, _zipClient);
            URCOMLoader.Instance.Initialize(appPaths.ProgramDataPath, _zipClient, logManager, configurationManager);

            EnsureMediaFilters(appPaths.ProgramDataPath);
        }
		internal static string ExtractFont(string name, IApplicationPaths paths, IFileSystem fileSystem)
        {
            var filePath = Path.Combine(paths.ProgramDataPath, "fonts", name);

			if (fileSystem.FileExists(filePath))
            {
                return filePath;
            }

            var namespacePath = typeof(PlayedIndicatorDrawer).Namespace + ".fonts." + name;
            var tempPath = Path.Combine(paths.TempDirectory, Guid.NewGuid().ToString("N") + ".ttf");
			fileSystem.CreateDirectory(Path.GetDirectoryName(tempPath));

            using (var stream = typeof(PlayedIndicatorDrawer).Assembly.GetManifestResourceStream(namespacePath))
            {
                using (var fileStream = new FileStream(tempPath, FileMode.Create, FileAccess.Write, FileShare.Read))
                {
                    stream.CopyTo(fileStream);
                }
            }

			fileSystem.CreateDirectory(Path.GetDirectoryName(filePath));

            try
            {
				fileSystem.CopyFile(tempPath, filePath, false);
            }
            catch (IOException)
            {

            }

            return tempPath;
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="PismoIsoManager" /> class.
 /// </summary>
 public PismoIsoManager(ILogger logger, IHttpClient httpClient, IApplicationPaths appPaths, IZipClient zipClient)
 {
     _logger = logger;
     _httpClient = httpClient;
     _appPaths = appPaths;
     _zipClient = zipClient;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="PluginUpdater" /> class.
 /// </summary>
 /// <param name="appHost">The app host.</param>
 /// <param name="logger">The logger.</param>
 public PluginUpdater(IApplicationHost appHost, ILogger logger, IApplicationPaths appPaths, ApiClient apiClient)
 {
     _appHost = appHost;
     _logger = logger;
     _appPaths = appPaths;
     _apiClient = apiClient;
 }
Esempio n. 9
0
 public DeviceRepository(IApplicationPaths appPaths, IJsonSerializer json, ILogger logger, IFileSystem fileSystem)
 {
     _appPaths = appPaths;
     _json = json;
     _logger = logger;
     _fileSystem = fileSystem;
 }
 public SqliteDisplayPreferencesRepository(ILogManager logManager, IJsonSerializer jsonSerializer, IApplicationPaths appPaths, IDbConnector dbConnector, IMemoryStreamProvider memoryStreamProvider)
     : base(logManager, dbConnector)
 {
     _jsonSerializer = jsonSerializer;
     _memoryStreamProvider = memoryStreamProvider;
     DbFilePath = Path.Combine(appPaths.DataPath, "displaypreferences.db");
 }
Esempio n. 11
0
        public MBLicenseFile(IApplicationPaths appPaths)
        {
            _appPaths = appPaths;

            UpdateRecords = new Dictionary<Guid, DateTime>();
            Load();
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="ServerConfigurationManager" /> class.
 /// </summary>
 /// <param name="applicationPaths">The application paths.</param>
 /// <param name="logManager">The log manager.</param>
 /// <param name="xmlSerializer">The XML serializer.</param>
 public ServerConfigurationManager(IApplicationPaths applicationPaths, ILogManager logManager, IXmlSerializer xmlSerializer)
     : base(applicationPaths, logManager, xmlSerializer)
 {
     UpdateItemsByNamePath();
     UpdateTranscodingTempPath();
     UpdateMetadataPath();
 }
Esempio n. 13
0
 public FFMpegDownloader(ILogger logger, IApplicationPaths appPaths, IHttpClient httpClient, IZipClient zipClient)
 {
     _logger = logger;
     _appPaths = appPaths;
     _httpClient = httpClient;
     _zipClient = zipClient;
 }
Esempio n. 14
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ScheduledTaskWorker" /> class.
        /// </summary>
        /// <param name="scheduledTask">The scheduled task.</param>
        /// <param name="applicationPaths">The application paths.</param>
        /// <param name="taskManager">The task manager.</param>
        /// <param name="jsonSerializer">The json serializer.</param>
        /// <param name="logger">The logger.</param>
        /// <exception cref="System.ArgumentNullException">
        /// scheduledTask
        /// or
        /// applicationPaths
        /// or
        /// taskManager
        /// or
        /// jsonSerializer
        /// or
        /// logger
        /// </exception>
        public ScheduledTaskWorker(IScheduledTask scheduledTask, IApplicationPaths applicationPaths, ITaskManager taskManager, IJsonSerializer jsonSerializer, ILogger logger, IFileSystem fileSystem)
        {
            if (scheduledTask == null)
            {
                throw new ArgumentNullException("scheduledTask");
            }
            if (applicationPaths == null)
            {
                throw new ArgumentNullException("applicationPaths");
            }
            if (taskManager == null)
            {
                throw new ArgumentNullException("taskManager");
            }
            if (jsonSerializer == null)
            {
                throw new ArgumentNullException("jsonSerializer");
            }
            if (logger == null)
            {
                throw new ArgumentNullException("logger");
            }

            ScheduledTask = scheduledTask;
            ApplicationPaths = applicationPaths;
            TaskManager = taskManager;
            JsonSerializer = jsonSerializer;
            Logger = logger;
            _fileSystem = fileSystem;

            InitTriggerEvents();
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="ImageManager" /> class.
        /// </summary>
        /// <param name="apiClient">The API client.</param>
        /// <param name="paths">The paths.</param>
        /// <param name="config"></param>
        public ImageManager(Func<IApiClient> apiClient, IApplicationPaths paths, ITheaterConfigurationManager config)
        {
            _apiClient = apiClient;
            _config = config;

            _remoteImageCache = new FileSystemRepository(Path.Combine(paths.CachePath, "remote-images"));
        }
Esempio n. 16
0
        public void UpdateApplication(MBApplication app, IApplicationPaths appPaths, string archive)
        {
            // First see if there is a version file and read that in
            var version = "Unknown";
            if (File.Exists(archive + ".ver"))
            {
                version = File.ReadAllText(archive + ".ver");
            }

            // Use our installer passing it the specific archive
            // We need to copy to a temp directory and execute it there
            var source = Path.Combine(appPaths.ProgramSystemPath, UpdaterExe);
            var tempUpdater = Path.Combine(Path.GetTempPath(), UpdaterExe);
            File.Copy(source, tempUpdater, true);
            source = Path.Combine(appPaths.ProgramSystemPath, UpdaterDll);
            var tempUpdaterDll = Path.Combine(Path.GetTempPath(), UpdaterDll);
            File.Copy(source, tempUpdaterDll, true);
            var product = app == MBApplication.MBTheater ? "mbt" : "server";
            // Our updater needs SS and ionic
            source = Path.Combine(appPaths.ProgramSystemPath, "ServiceStack.Text.dll");
            File.Copy(source, Path.Combine(Path.GetTempPath(), "ServiceStack.Text.dll"), true);
            source = Path.Combine(appPaths.ProgramSystemPath, "Ionic.Zip.dll");
            File.Copy(source, Path.Combine(Path.GetTempPath(), "Ionic.Zip.dll"), true);
            Process.Start(tempUpdater, string.Format("product={0} archive=\"{1}\" caller={2} pismo=false version={3}", product, archive, Process.GetCurrentProcess().Id, version));

            // That's it.  The installer will do the work once we exit
        }
Esempio n. 17
0
        public static void SaveImageInfo(IApplicationPaths appPaths, ILogger logger, string musicBrainzId, string url, string size)
        {
            if (appPaths == null)
            {
                throw new ArgumentNullException("appPaths");
            }
            if (string.IsNullOrEmpty(musicBrainzId))
            {
                throw new ArgumentNullException("musicBrainzId");
            }
            if (string.IsNullOrEmpty(url))
            {
                throw new ArgumentNullException("url");
            }

            var cachePath = Path.Combine(appPaths.CachePath, "lastfm", musicBrainzId, "image.txt");

            try
            {
                if (string.IsNullOrEmpty(url))
                {
                    File.Delete(cachePath);
                }
                else
                {
                    Directory.CreateDirectory(Path.GetDirectoryName(cachePath));
                    File.WriteAllText(cachePath, url + "|" + size);
                }
            }
            catch (IOException ex)
            {
                // Don't fail if this is unable to write
                logger.ErrorException("Error saving to {0}", ex, cachePath);
            }
        }
        public void UpdateApplication(IApplicationPaths appPaths, string archive, ILogger logger, string restartServiceName)
        {
            // First see if there is a version file and read that in
            var version = "Unknown";
            if (File.Exists(archive + ".ver"))
            {
                version = File.ReadAllText(archive + ".ver");
            }

            // Use our installer passing it the specific archive
            // We need to copy to a temp directory and execute it there
            var source = Path.Combine(appPaths.ProgramSystemPath, UpdaterExe);

            logger.Info("Copying updater to temporary location");
            var tempUpdater = Path.Combine(Path.GetTempPath(), UpdaterExe);
            File.Copy(source, tempUpdater, true);
            source = Path.Combine(appPaths.ProgramSystemPath, UpdaterDll);
            var tempUpdaterDll = Path.Combine(Path.GetTempPath(), UpdaterDll);

            logger.Info("Copying updater dependencies to temporary location");
            File.Copy(source, tempUpdaterDll, true);
            var product = "mbt";
            // Our updater needs SS and ionic
            source = Path.Combine(appPaths.ProgramSystemPath, "ServiceStack.Text.dll");
            File.Copy(source, Path.Combine(Path.GetTempPath(), "ServiceStack.Text.dll"), true);
            source = Path.Combine(appPaths.ProgramSystemPath, "SharpCompress.dll");
            File.Copy(source, Path.Combine(Path.GetTempPath(), "SharpCompress.dll"), true);

            logger.Info("Starting updater process.");
            Process.Start(tempUpdater, string.Format("product={0} archive=\"{1}\" caller={2} pismo=false version={3} service={4} installpath=\"{5}\"", product, archive, Process.GetCurrentProcess().Id, version, restartServiceName ?? string.Empty, appPaths.ProgramDataPath));

            // That's it.  The installer will do the work once we exit
        }
		public LinuxIsoManager(ILogger logger, IHttpClient httpClient, IApplicationPaths appPaths, IZipClient zipClient)
		{
			_logger = logger;
			_tmpPath = Path.DirectorySeparatorChar + "tmp" + Path.DirectorySeparatorChar + "mediabrowser";
			_mountELF = Path.DirectorySeparatorChar + "usr" + Path.DirectorySeparatorChar + "bin" + Path.DirectorySeparatorChar + "mount";
			_umountELF = Path.DirectorySeparatorChar + "usr" + Path.DirectorySeparatorChar + "bin" + Path.DirectorySeparatorChar + "umount";
			_sudoELF = Path.DirectorySeparatorChar + "usr" + Path.DirectorySeparatorChar + "bin" + Path.DirectorySeparatorChar + "sudo";
		}
Esempio n. 20
0
 public VideoProcessor(ILogger logger, IMediaEncoder mediaEncoder, IFileSystem fileSystem, IApplicationPaths appPaths, ILibraryMonitor libraryMonitor)
 {
     _logger = logger;
     _mediaEncoder = mediaEncoder;
     _fileSystem = fileSystem;
     _appPaths = appPaths;
     _libraryMonitor = libraryMonitor;
 }
Esempio n. 21
0
 public EncodedRecorder(ILogger logger, IFileSystem fileSystem, IMediaEncoder mediaEncoder, IApplicationPaths appPaths, IJsonSerializer json)
 {
     _logger = logger;
     _fileSystem = fileSystem;
     _mediaEncoder = mediaEncoder;
     _appPaths = appPaths;
     _json = json;
 }
Esempio n. 22
0
        public ImageMagickEncoder(ILogger logger, IApplicationPaths appPaths, IHttpClient httpClient)
        {
            _logger = logger;
            _appPaths = appPaths;
            _httpClient = httpClient;

            LogImageMagickVersion();
        }
Esempio n. 23
0
 public FontConfigLoader(IHttpClient httpClient, IApplicationPaths appPaths, ILogger logger, IZipClient zipClient, IFileSystem fileSystem)
 {
     _httpClient = httpClient;
     _appPaths = appPaths;
     _logger = logger;
     _zipClient = zipClient;
     _fileSystem = fileSystem;
 }
Esempio n. 24
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ChapterImagesTask" /> class.
 /// </summary>
 /// <param name="logManager">The log manager.</param>
 /// <param name="libraryManager">The library manager.</param>
 /// <param name="itemRepo">The item repo.</param>
 public ChapterImagesTask(ILogManager logManager, ILibraryManager libraryManager, IItemRepository itemRepo, IApplicationPaths appPaths, IEncodingManager encodingManager)
 {
     _logger = logManager.GetLogger(GetType().Name);
     _libraryManager = libraryManager;
     _itemRepo = itemRepo;
     _appPaths = appPaths;
     _encodingManager = encodingManager;
 }
Esempio n. 25
0
 public NewsEntryPoint(IHttpClient httpClient, IApplicationPaths appPaths, IFileSystem fileSystem, ILogger logger, IJsonSerializer json)
 {
     _httpClient = httpClient;
     _appPaths = appPaths;
     _fileSystem = fileSystem;
     _logger = logger;
     _json = json;
 }
Esempio n. 26
0
        public static void Init(IApplicationPaths appPaths, INetworkManager networkManager, ILogManager logManager)
        {
            // Ugly alert (static init)

            _appPaths = appPaths;
            _networkManager = networkManager;
            _logger = logManager.GetLogger("SecurityManager");
        }
Esempio n. 27
0
 public ConnectEntryPoint(IHttpClient httpClient, IApplicationPaths appPaths, ILogger logger, INetworkManager networkManager, IConnectManager connectManager)
 {
     _httpClient = httpClient;
     _appPaths = appPaths;
     _logger = logger;
     _networkManager = networkManager;
     _connectManager = connectManager;
 }
        /// <summary>
        /// Initializes a new instance of the <see cref="BaseConfigurationManager" /> class.
        /// </summary>
        /// <param name="applicationPaths">The application paths.</param>
        /// <param name="logManager">The log manager.</param>
        /// <param name="xmlSerializer">The XML serializer.</param>
        protected BaseConfigurationManager(IApplicationPaths applicationPaths, ILogManager logManager, IXmlSerializer xmlSerializer)
        {
            CommonApplicationPaths = applicationPaths;
            XmlSerializer = xmlSerializer;
            Logger = logManager.GetLogger(GetType().Name);

            UpdateCachePath();
        }
Esempio n. 29
0
 public SubtitleEncoder(ILibraryManager libraryManager, ILogger logger, IApplicationPaths appPaths, IFileSystem fileSystem, IMediaEncoder mediaEncoder)
 {
     _libraryManager = libraryManager;
     _logger = logger;
     _appPaths = appPaths;
     _fileSystem = fileSystem;
     _mediaEncoder = mediaEncoder;
 }
Esempio n. 30
0
 public RemoteNotifications(IApplicationPaths appPaths, ILogger logger, IHttpClient httpClient, IJsonSerializer json, INotificationsRepository notificationsRepo, IUserManager userManager)
 {
     _appPaths = appPaths;
     _logger = logger;
     _httpClient = httpClient;
     _json = json;
     _notificationsRepo = notificationsRepo;
     _userManager = userManager;
 }
Esempio n. 31
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SkiaEncoder"/> class.
 /// </summary>
 /// <param name="logger">The application logger.</param>
 /// <param name="appPaths">The application paths.</param>
 public SkiaEncoder(ILogger <SkiaEncoder> logger, IApplicationPaths appPaths)
 {
     _logger   = logger;
     _appPaths = appPaths;
 }
Esempio n. 32
0
 internal static string GetPersonDataFilePath(IApplicationPaths appPaths, string tmdbId)
 {
     return(Path.Combine(GetPersonDataPath(appPaths, tmdbId), DataFileName));
 }
 public SqliteProviderInfoRepository(IApplicationPaths appPaths, ILogManager logManager)
 {
     _appPaths = appPaths;
     _logger   = logManager.GetLogger(GetType().Name);
 }
 public LiveTvService(IHttpClient httpClient, IJsonSerializer jsonSerializer, ILogManager logManager, IXmlSerializer xmlSerializer, IApplicationPaths appPaths)
 {
     _logger         = logManager.GetLogger(Name);
     _httpClient     = httpClient;
     _jsonSerializer = jsonSerializer;
     FirstRun        = true;
     streams         = new Dictionary <int, MediaSourceInfo>();
     _xmlSerializer  = xmlSerializer;
     _appPaths       = appPaths;
     _logger.Info("Directory is: " + DataPath);
     timers = new List <SingleTimer>();
     RefreshConfigData(CancellationToken.None);
     Plugin.Instance.Configuration.TunerDefaultConfigurationsFields = TunerHostConfig.BuildDefaultForTunerHostsBuilders();
     Plugin.Instance.ConfigurationUpdated += (sender, args) => RefreshConfigData(CancellationToken.None);
 }
Esempio n. 35
0
        private static string GetAlbumDataPath(IApplicationPaths appPaths, string musicBrainzReleaseGroupId)
        {
            var dataPath = Path.Combine(GetAlbumDataPath(appPaths), musicBrainzReleaseGroupId);

            return(dataPath);
        }
 protected BaseDynamicImageProvider(IFileSystem fileSystem, IProviderManager providerManager, IApplicationPaths applicationPaths, IImageProcessor imageProcessor)
 {
     ApplicationPaths = applicationPaths;
     ProviderManager  = providerManager;
     FileSystem       = fileSystem;
     ImageProcessor   = imageProcessor;
 }
Esempio n. 37
0
 public MusicGenreImageProvider(IFileSystem fileSystem, IProviderManager providerManager, IApplicationPaths applicationPaths, IImageProcessor imageProcessor, ILibraryManager libraryManager) : base(fileSystem, providerManager, applicationPaths, imageProcessor)
 {
     _libraryManager = libraryManager;
 }
        public UpdateService(IFileSystem fileSystem, IHttpClient httpClient, IZipClient zipClient, IJsonSerializer jsonSerializer, IApplicationPaths appPaths,
#if __JELLYFIN__
                             ILoggerFactory logManager
Esempio n. 39
0
 public FFProbeAudioInfo(IMediaEncoder mediaEncoder, IItemRepository itemRepo, IApplicationPaths appPaths, IJsonSerializer json)
 {
     _mediaEncoder = mediaEncoder;
     _itemRepo     = itemRepo;
     _appPaths     = appPaths;
     _json         = json;
 }
Esempio n. 40
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ChapterImagesTask" /> class.
 /// </summary>
 public ChapterImagesTask(ILogManager logManager, ILibraryManager libraryManager, IItemRepository itemRepo, IApplicationPaths appPaths, IEncodingManager encodingManager, IFileSystem fileSystem)
 {
     _logger          = logManager.GetLogger(GetType().Name);
     _libraryManager  = libraryManager;
     _itemRepo        = itemRepo;
     _appPaths        = appPaths;
     _encodingManager = encodingManager;
     _fileSystem      = fileSystem;
 }
        /// <summary>
        /// Gets the artist data path.
        /// </summary>
        /// <param name="appPaths">The application paths.</param>
        /// <param name="musicBrainzArtistId">The music brainz artist identifier.</param>
        /// <returns>System.String.</returns>
        private static string GetArtistDataPath(IApplicationPaths appPaths, string musicBrainzArtistId)
        {
            var dataPath = Path.Combine(GetArtistDataPath(appPaths), musicBrainzArtistId);

            return(dataPath);
        }
Esempio n. 42
0
        internal static string GetMoviesDataPath(IApplicationPaths appPaths)
        {
            var dataPath = Path.Combine(appPaths.CachePath, "tmdb-movies2");

            return(dataPath);
        }
Esempio n. 43
0
        /// <summary>
        /// Gets the movie data path.
        /// </summary>
        /// <param name="appPaths">The app paths.</param>
        /// <param name="tmdbId">The TMDB id.</param>
        /// <returns>System.String.</returns>
        internal static string GetMovieDataPath(IApplicationPaths appPaths, string tmdbId)
        {
            var dataPath = GetMoviesDataPath(appPaths);

            return(Path.Combine(dataPath, tmdbId));
        }
Esempio n. 44
0
 private static string GetPersonsDataPath(IApplicationPaths appPaths)
 {
     return(Path.Combine(appPaths.CachePath, "tmdb-people"));
 }
Esempio n. 45
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TvMazePlugin"/> class.
 /// </summary>
 /// <param name="applicationPaths">Instance of the <see cref="IApplicationPaths"/> interface.</param>
 /// <param name="xmlSerializer">Instance of the <see cref="IXmlSerializer"/> interface.</param>
 public TvMazePlugin(IApplicationPaths applicationPaths, IXmlSerializer xmlSerializer)
     : base(applicationPaths, xmlSerializer)
 {
     Instance = this;
 }
Esempio n. 46
0
        internal static string GetArtistJsonPath(IApplicationPaths appPaths, string musicBrainzArtistId)
        {
            var dataPath = GetArtistDataPath(appPaths, musicBrainzArtistId);

            return(Path.Combine(dataPath, "fanart.json"));
        }
Esempio n. 47
0
 public DlnaProfileEntryPoint(IApplicationPaths appPaths, IFileSystem fileSystem, IXmlSerializer xmlSerializer)
 {
     _appPaths      = appPaths;
     _fileSystem    = fileSystem;
     _xmlSerializer = xmlSerializer;
 }
Esempio n. 48
0
        /// <summary>
        /// Gets the artist data path.
        /// </summary>
        /// <param name="appPaths">The application paths.</param>
        /// <returns>System.String.</returns>
        internal static string GetArtistDataPath(IApplicationPaths appPaths)
        {
            var dataPath = Path.Combine(appPaths.CachePath, "fanart-music");

            return(dataPath);
        }
Esempio n. 49
0
        internal static string GetAlbumInfoPath(IApplicationPaths appPaths, string musicBrainzReleaseGroupId)
        {
            var dataPath = GetAlbumDataPath(appPaths, musicBrainzReleaseGroupId);

            return(Path.Combine(dataPath, "album.json"));
        }
 public Plugin(IApplicationPaths appPaths, IXmlSerializer xmlSerializer)
     : base(appPaths, xmlSerializer)
 {
 }
Esempio n. 51
0
 public PhotoAlbumImageProvider(IFileSystem fileSystem, IProviderManager providerManager, IApplicationPaths applicationPaths, IImageProcessor imageProcessor)
     : base(fileSystem, providerManager, applicationPaths, imageProcessor)
 {
 }
Esempio n. 52
0
        /// <summary>
        /// COPY TO /volume1/@appstore/EmbyServer/releases/4.3.1.0/plugins
        /// </summary>
        /// <param name="applicationPaths"></param>
        /// <param name="xmlSerializer"></param>
        /// <param name="logger"></param>
        public Plugin(IApplicationPaths applicationPaths, IXmlSerializer xmlSerializer, IJsonSerializer jsonSerializer, IFileSystem fileSystem,
#if __JELLYFIN__
                      ILoggerFactory logManager
Esempio n. 53
0
        private static string GetAlbumDataPath(IApplicationPaths appPaths)
        {
            var dataPath = Path.Combine(appPaths.CachePath, "audiodb-album");

            return(dataPath);
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="ServerEntryPoint" /> class.
        /// </summary>
        /// <param name="taskManager">The task manager.</param>
        /// <param name="appPaths">The app paths.</param>
        /// <param name="logManager"></param>
        public ServerEntryPoint(ITaskManager taskManager, ILibraryManager libraryManager, IApplicationPaths appPaths, ILogManager logManager, ISecurityManager securityManager)
        {
            _taskManager          = taskManager;
            LibraryManager        = libraryManager;
            PluginSecurityManager = securityManager;
            Plugin.Logger         = logManager.GetLogger(Plugin.Instance.Name);

            Instance = this;
        }
Esempio n. 55
0
 public AniDbSeasonProvider(IHttpClient httpClient, IApplicationPaths appPaths)
 {
     _seriesProvider = new AniDbSeriesProvider(appPaths, httpClient);
 }
Esempio n. 56
0
 public SharingRepository(ILogger logger, IApplicationPaths appPaths, IFileSystem fileSystem)
     : base(logger)
 {
     FileSystem = fileSystem;
     DbFilePath = Path.Combine(appPaths.DataPath, "shares.db");
 }
 public CollectionFolderImageProvider(IFileSystem fileSystem, IProviderManager providerManager, IApplicationPaths applicationPaths, IImageProcessor imageProcessor) : base(fileSystem, providerManager, applicationPaths, imageProcessor)
 {
 }
 public ManualCollectionFolderImageProvider(IFileSystem fileSystem, IProviderManager providerManager, IApplicationPaths applicationPaths, IImageProcessor imageProcessor, ILibraryManager libraryManager) : base(fileSystem, providerManager, applicationPaths, imageProcessor)
 {
     _libraryManager = libraryManager;
 }
Esempio n. 59
0
        private static string GetPersonDataPath(IApplicationPaths appPaths, string tmdbId)
        {
            var letter = tmdbId.GetMD5().ToString().Substring(0, 1);

            return(Path.Combine(GetPersonsDataPath(appPaths), letter, tmdbId));
        }
Esempio n. 60
0
 public FFProbeVideoInfo(ILogger logger, IIsoManager isoManager, IMediaEncoder mediaEncoder, IItemRepository itemRepo, IBlurayExaminer blurayExaminer, ILocalizationManager localization, IApplicationPaths appPaths, IJsonSerializer json, IEncodingManager encodingManager, IFileSystem fileSystem, IServerConfigurationManager config, ISubtitleManager subtitleManager, IChapterManager chapterManager)
 {
     _logger          = logger;
     _isoManager      = isoManager;
     _mediaEncoder    = mediaEncoder;
     _itemRepo        = itemRepo;
     _blurayExaminer  = blurayExaminer;
     _localization    = localization;
     _appPaths        = appPaths;
     _json            = json;
     _encodingManager = encodingManager;
     _fileSystem      = fileSystem;
     _config          = config;
     _subtitleManager = subtitleManager;
     _chapterManager  = chapterManager;
 }