IPlugin.cs 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. using System;
  2. using MediaBrowser.Model.Plugins;
  3. namespace MediaBrowser.Common.Plugins
  4. {
  5. /// <summary>
  6. /// Defines the <see cref="IPlugin" />.
  7. /// </summary>
  8. public interface IPlugin
  9. {
  10. /// <summary>
  11. /// Gets the name of the plugin.
  12. /// </summary>
  13. string Name { get; }
  14. /// <summary>
  15. /// Gets the Description.
  16. /// </summary>
  17. string Description { get; }
  18. /// <summary>
  19. /// Gets the unique id.
  20. /// </summary>
  21. Guid Id { get; }
  22. /// <summary>
  23. /// Gets the plugin version.
  24. /// </summary>
  25. Version Version { get; }
  26. /// <summary>
  27. /// Gets the path to the assembly file.
  28. /// </summary>
  29. string AssemblyFilePath { get; }
  30. /// <summary>
  31. /// Gets a value indicating whether the plugin can be uninstalled.
  32. /// </summary>
  33. bool CanUninstall { get; }
  34. /// <summary>
  35. /// Gets the full path to the data folder, where the plugin can store any miscellaneous files needed.
  36. /// </summary>
  37. string DataFolderPath { get; }
  38. /// <summary>
  39. /// Gets the <see cref="PluginInfo"/>.
  40. /// </summary>
  41. /// <returns>PluginInfo.</returns>
  42. PluginInfo GetPluginInfo();
  43. /// <summary>
  44. /// Called when just before the plugin is uninstalled from the server.
  45. /// </summary>
  46. void OnUninstalling();
  47. }
  48. }