public class PluginDependency extends Object
Plugin.checkDependencies(com.tplan.robot.plugin.PluginManager)
method. If one or more of the required dependencies are not installed, the plugin
is supposed to construct dependency criteria represented by instances of this class
and throw them through a DependencyMissingException
back to the Plugin Manager.T-Plan Robot Enterprise, (C) 2009-2022 T-Plan Limited. All rights reserved.
Constructor and Description |
---|
PluginDependency(Plugin dependentPlugin,
String dependencyCode,
Class dependencyInterface,
String dependencyUniqueId,
int[] dependencyVersion)
Constructor with arguments referring to attributes of a plugin which
is required as a dependency.
|
Modifier and Type | Method and Description |
---|---|
String |
getDependencyCode()
Get code of the dependency plugin.
|
Class |
getDependencyInterface()
Get the exposed functional interface implemented by the dependency plugin.
|
String |
getDependencyUniqueId()
Get required unique ID of the dependency plugin.
|
int[] |
getDependencyVersion()
Get required version of the dependency plugin.
|
Plugin |
getDependentPlugin()
Get the dependent plugin (source of this dependency).
|
public PluginDependency(Plugin dependentPlugin, String dependencyCode, Class dependencyInterface, String dependencyUniqueId, int[] dependencyVersion)
dependentPlugin
- source of the dependency, a plugin which is depending on
certain other plugin functionality described by the other parameters.dependencyCode
- dependency plugin code. This parameter must not be null.dependencyInterface
- dependency plugin interface. This parameter must not be null.dependencyUniqueId
- unique ID desired unique ID of the dependency plugin (optional).
It allows to specify dependency on a plugin from particular provider (vendor). If null
is provided, it is taken as that the dependent plugin can do with a dependency one from any provider.dependencyVersion
- desired version of the dependency plugin (optional). If null
is provided, it is taken as that the dependent plugin can do with any version
of the dependency one.public String getDependencyCode()
public String getDependencyUniqueId()
public int[] getDependencyVersion()
public Plugin getDependentPlugin()
public Class getDependencyInterface()