Class BuiltInPluginDescriptor

java.lang.Object
nz.org.riskscape.engine.plugin.BuiltInPluginDescriptor
All Implemented Interfaces:
nz.org.riskscape.engine.plugin.PluginDescriptor

public class BuiltInPluginDescriptor extends Object implements nz.org.riskscape.engine.plugin.PluginDescriptor

A plugin descriptor for code that wasn't dynamically loaded (and can also be used in some testing scenarios)

  • Constructor Details

    • BuiltInPluginDescriptor

      public BuiltInPluginDescriptor(String pluginId, nz.org.riskscape.engine.BuildInfo buildInfo, Class<? extends nz.org.riskscape.engine.plugin.Plugin> pluginClass, Path sourcePath)
  • Method Details

    • testPlugin

      public static BuiltInPluginDescriptor testPlugin(Class<? extends nz.org.riskscape.engine.plugin.Plugin> pluginClass)

      Build a plugin descriptor for use in tests

    • getI18nClassLoader

      public ClassLoader getI18nClassLoader()
      Specified by:
      getI18nClassLoader in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • newPluginInstance

      public nz.org.riskscape.engine.plugin.Plugin newPluginInstance()
      Specified by:
      newPluginInstance in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • hasPluginDependencies

      public boolean hasPluginDependencies()
      Specified by:
      hasPluginDependencies in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • getPluginDependencies

      public Set<String> getPluginDependencies()
      Specified by:
      getPluginDependencies in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • addDependency

      public void addDependency(nz.org.riskscape.engine.plugin.PluginDescriptor dependencyDescriptor)
      Specified by:
      addDependency in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • getPluginClassName

      public String getPluginClassName()
      Specified by:
      getPluginClassName in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • getVersion

      public String getVersion()
      Specified by:
      getVersion in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getPluginId

      public String getPluginId()
      Specified by:
      getPluginId in interface nz.org.riskscape.engine.plugin.PluginDescriptor
    • getSourcePath

      public Path getSourcePath()
      Specified by:
      getSourcePath in interface nz.org.riskscape.engine.plugin.PluginDescriptor