You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

PluginDescriptor.java 2.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. /*
  2. * Copyright (C) 2012-present the original author or authors.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. package org.pf4j;
  17. import java.util.List;
  18. /**
  19. * A plugin descriptor contains information about a plug-in.
  20. *
  21. * @author Decebal Suiu
  22. */
  23. public interface PluginDescriptor {
  24. /**
  25. * The unique identifier of the plugin.
  26. *
  27. * @return the plugin id
  28. */
  29. String getPluginId();
  30. /**
  31. * Returns a description of the plugin.
  32. *
  33. * @return the plugin description
  34. */
  35. String getPluginDescription();
  36. /**
  37. * Returns the fully qualified class name of the plugin class.
  38. * The plugin class must implement the {@link Plugin} interface.
  39. *
  40. * @return the plugin class
  41. */
  42. String getPluginClass();
  43. /**
  44. * Returns the plugin version.
  45. * The version must be unique for each release of the plugin.
  46. * The version is used to check if the plugin is compatible with the application.
  47. *
  48. * @see VersionManager
  49. * @return the plugin version
  50. */
  51. String getVersion();
  52. /**
  53. * Returns the required version of the application.
  54. *
  55. * @return the required version of the application
  56. */
  57. String getRequires();
  58. /**
  59. * Returns the author of the plugin.
  60. *
  61. * @return the author of the plugin
  62. */
  63. String getProvider();
  64. /**
  65. * Returns the license of the plugin.
  66. *
  67. * @return the license of the plugin
  68. */
  69. String getLicense();
  70. /**
  71. * Returns the dependencies of the plugin.
  72. * A dependency is represented by a {@link PluginDependency} object.
  73. *
  74. * @return the dependencies of the plugin
  75. */
  76. List<PluginDependency> getDependencies();
  77. }