Module io.annot8.api
Package io.annot8.api.components
Interface Annot8ComponentDescriptor<T extends Annot8Component,S extends Settings>
-
- Type Parameters:
T- The Annot8 component described by this descriptorS- The settings used by this component, orNoSettingsif the component doesn't use settings
- All Known Subinterfaces:
ProcessorDescriptor<T,S>,SourceDescriptor<T,S>
public interface Annot8ComponentDescriptor<T extends Annot8Component,S extends Settings>Descriptor for an Annot8 componentDescriptors provide contextual information about a component, for example a name and it's configuration, as well as a method to create an instance of that component.
Descriptors should be serializable, as they can be used to recreate pipelines.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Capabilitiescapabilities()Get the capabilities of the component, as configured with the current settingsTcreate(Context context)Create an instance of the component, with the current settings and using the provided contextStringgetName()Get the name of this componentSgetSettings()Get the settings for this componentvoidsetName(String name)Set the name of this componentvoidsetSettings(S settings)Set the settings for this component
-
-
-
Method Detail
-
setName
void setName(String name)
Set the name of this component- Parameters:
name- name of the component
-
getName
String getName()
Get the name of this component- Returns:
- name of the component
-
setSettings
void setSettings(S settings)
Set the settings for this component- Parameters:
settings- the settings to apply
-
getSettings
S getSettings()
Get the settings for this component- Returns:
- settings used to create the component (or null)
-
capabilities
Capabilities capabilities()
Get the capabilities of the component, as configured with the current settings- Returns:
- the capabilities of the component (wrt to the settings)
-
-