INativeApp.cs 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. using MediaBrowser.Common.Net;
  2. using MediaBrowser.Model.Logging;
  3. using System.Collections.Generic;
  4. using System.Reflection;
  5. using Emby.Server.Core;
  6. using Emby.Server.Core.Data;
  7. using Emby.Server.Core.FFMpeg;
  8. namespace Emby.Server.Core
  9. {
  10. public interface INativeApp
  11. {
  12. /// <summary>
  13. /// Gets the assemblies with parts.
  14. /// </summary>
  15. /// <returns>List&lt;Assembly&gt;.</returns>
  16. List<Assembly> GetAssembliesWithParts();
  17. /// <summary>
  18. /// Authorizes the server.
  19. /// </summary>
  20. void AuthorizeServer(int udpPort, int httpServerPort, int httpsServerPort, string applicationPath, string tempDirectory);
  21. /// <summary>
  22. /// Gets a value indicating whether [supports running as service].
  23. /// </summary>
  24. /// <value><c>true</c> if [supports running as service]; otherwise, <c>false</c>.</value>
  25. bool SupportsRunningAsService { get; }
  26. /// <summary>
  27. /// Gets a value indicating whether this instance is running as service.
  28. /// </summary>
  29. /// <value><c>true</c> if this instance is running as service; otherwise, <c>false</c>.</value>
  30. bool IsRunningAsService { get; }
  31. /// <summary>
  32. /// Gets a value indicating whether this instance can self restart.
  33. /// </summary>
  34. /// <value><c>true</c> if this instance can self restart; otherwise, <c>false</c>.</value>
  35. bool CanSelfRestart { get; }
  36. /// <summary>
  37. /// Gets a value indicating whether [supports autorun at startup].
  38. /// </summary>
  39. /// <value><c>true</c> if [supports autorun at startup]; otherwise, <c>false</c>.</value>
  40. bool SupportsAutoRunAtStartup { get; }
  41. /// <summary>
  42. /// Gets a value indicating whether this instance can self update.
  43. /// </summary>
  44. /// <value><c>true</c> if this instance can self update; otherwise, <c>false</c>.</value>
  45. bool CanSelfUpdate { get; }
  46. /// <summary>
  47. /// Shutdowns this instance.
  48. /// </summary>
  49. void Shutdown();
  50. /// <summary>
  51. /// Restarts this instance.
  52. /// </summary>
  53. void Restart(StartupOptions startupOptions);
  54. /// <summary>
  55. /// Configures the automatic run.
  56. /// </summary>
  57. /// <param name="autorun">if set to <c>true</c> [autorun].</param>
  58. void ConfigureAutoRun(bool autorun);
  59. FFMpegInstallInfo GetFfmpegInstallInfo();
  60. void LaunchUrl(string url);
  61. IDbConnector GetDbConnector();
  62. void EnableLoopback(string appName);
  63. }
  64. }