public interface ConfigurationParameter extends MetaDataObject
A configuration parameter consists of the following fields:
This interface does not provide access to the value of the parameter - that is a separate piece of metadata associated with the resource.
In an aggregate resource, configuration parameters may override component resources' parameters.
This is done by the overrides
property. Overrides should always be
specified for aggregate resources. If no overrides are specified, the default behavior is to
override any parameter with the same name in any component resource. However, this usage is
discouraged and will generate a warning in the log file; it exists for backwards compatibility
purposes.
As with all MetaDataObject
s, a ConfigurationParameter
may or may not be
modifiable. An application can find out by calling the MetaDataObject.isModifiable()
method.
Modifier and Type | Field and Description |
---|---|
static String |
TYPE_BOOLEAN
Identifies the Boolean data type.
|
static String |
TYPE_FLOAT
Identifies the Float data type.
|
static String |
TYPE_INTEGER
Identifies the Integer data type.
|
static String |
TYPE_STRING
Identifies the String data type.
|
Modifier and Type | Method and Description |
---|---|
void |
addOverride(String aOverride)
Adds an override to this configuration parameter.
|
String |
getDescription()
Retrieves the description of this configuration parameter.
|
String |
getExternalOverrideName()
Retrieves the external name of this configuration parameter.
|
String |
getName()
Retrieves the name of this configuration parameter.
|
String[] |
getOverrides()
Gets the parameters that are this parameter overrides.
|
String |
getType()
Retrieves the data type of this configuration parameter.
|
boolean |
isMandatory()
Retrieves whether this parameter is mandatory.
|
boolean |
isMultiValued()
Retrieves whether this parameter is multi-valued.
|
void |
removeOverride(String aOverride)
Removes an override from this configuration parameter.
|
void |
setDescription(String aDescription)
Sets the description of this configuration parameter.
|
void |
setExternalOverrideName(String aExternalOverrideName)
Sets the external name of this configuration parameter.
|
void |
setMandatory(boolean aMandatory)
Sets whether this parameter is mandatory.
|
void |
setMultiValued(boolean aMultiValued)
Sets whether this parameter is multi-valued.
|
void |
setName(String aName)
Sets the name of this configuration parameter.
|
void |
setOverrides(String[] aOverrides)
Sets the parameters that are this parameter overrides.
|
void |
setType(String aType)
Sets the data type of this configuration parameter.
|
clone, equals, getAttributeValue, getSourceUrl, getSourceUrlString, isModifiable, listAttributes, setAttributeValue, setSourceUrl
buildFromXMLElement, buildFromXMLElement, toXML, toXML, toXML, toXML
static final String TYPE_STRING
static final String TYPE_BOOLEAN
static final String TYPE_INTEGER
static final String TYPE_FLOAT
String getName()
void setName(String aName)
aName
- the name of this configuration parameter.UIMA_UnsupportedOperationException
- if this object is not modifiableString getExternalOverrideName()
void setExternalOverrideName(String aExternalOverrideName)
aExternalOverrideName
- the external name of this configuration parameter.UIMA_UnsupportedOperationException
- if this object is not modifiableString getDescription()
void setDescription(String aDescription)
aDescription
- the description of this configuration parameter.UIMA_UnsupportedOperationException
- if this object is not modifiableString getType()
void setType(String aType)
aType
- the data type of this configuration parameter. This must be one of the TYPE constants
defined on this interface.UIMA_IllegalArgumentException
- if aType
is not a valid data type defined by a TYPE constant on this
interface.UIMA_UnsupportedOperationException
- if this object is not modifiableboolean isMultiValued()
void setMultiValued(boolean aMultiValued)
aMultiValued
- true if and only if this parameter is multi-valued.UIMA_UnsupportedOperationException
- if this object is not modifiableboolean isMandatory()
void setMandatory(boolean aMandatory)
aMandatory
- true if and only if this parameter is mandatory.UIMA_UnsupportedOperationException
- if this object is not modifiableString[] getOverrides()
/
parameterName.
For example the overrides annotator1/parameter1
would override the parameter
named parameter1
within the component named annotator1
.void setOverrides(String[] aOverrides)
/
parameterName.
For example the overrides annotator1/parameter1
would override the parameter
named parameter1
within the component named annotator1
.aOverrides
- the parameters this this parameter overridesvoid addOverride(String aOverride)
aOverride
- the override to addUIMA_UnsupportedOperationException
- if this object is not modifiablesetOverrides(String[])
void removeOverride(String aOverride)
aOverride
- the override to remove. Must equal (via the equals() method) one of the overrides on
this parameter, or this method will do nothing.UIMA_UnsupportedOperationException
- if this object is not modifiablesetOverrides(String[])
Copyright © 2006–2017 The Apache Software Foundation. All rights reserved.