Package org.apache.uima.resource
Interface URISpecifier
- All Superinterfaces:
Cloneable
,MetaDataObject
,ResourceServiceSpecifier
,ResourceSpecifier
,Serializable
,XMLizable
- All Known Implementing Classes:
URISpecifier_impl
A type of
ResourceSpecifier
that locates an existing Resource
service
by its URI.-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Value forgetResourceType()
representing an Analysis Engine.static final String
Value forgetResourceType()
representing a CAS Consumer. -
Method Summary
Modifier and TypeMethodDescriptionGets the name of the Protocol used to communicate with the service.Retrieves the type of Resource (e.g.Gets the timeout period in milliseconds.getUri()
Retrieves the URI at which a Resource may be located.void
setParameters
(Parameter[] parameters) void
setProtocol
(String aProtocol) Sets the name of the Protocol used to communicate with the service.void
setResourceType
(String aResourceType) Sets the type of Resource (e.g.void
setTimeout
(Integer aTimeout) Sets the timeout period in milliseconds.void
Sets the URI at which a Resource may be located.Methods inherited from interface org.apache.uima.resource.metadata.MetaDataObject
clone, equals, getAttributeValue, getSourceUrl, getSourceUrlString, isModifiable, listAttributes, setAttributeValue, setSourceUrl
Methods inherited from interface org.apache.uima.util.XMLizable
buildFromXMLElement, buildFromXMLElement, toXML, toXML, toXML, toXML
-
Field Details
-
RESOURCE_TYPE_ANALYSIS_ENGINE
Value forgetResourceType()
representing an Analysis Engine.- See Also:
-
RESOURCE_TYPE_CAS_CONSUMER
Value forgetResourceType()
representing a CAS Consumer.- See Also:
-
-
Method Details
-
getResourceType
String getResourceType()Retrieves the type of Resource (e.g. Analysis Engine, CAS Consumer) that the service at this URI is expected to implement. This is optional, but useful for clients to know what to do with the URISpecifier.- Returns:
- the type of Resource. This should be one of the constants on this class, or null if the resource type is not specified.
-
setResourceType
Sets the type of Resource (e.g. Analysis Engine, CAS Consumer) that the service at this URI is expected to implement. This is optional, but useful for clients to know what to do with the URISpecifier.- Parameters:
aResourceType
- the type of Resource. This should be one of the constants on this class, or null to indicate that the resource type is not specified.
-
getUri
String getUri()Retrieves the URI at which a Resource may be located.- Returns:
- a URI string
-
getProtocol
String getProtocol()Gets the name of the Protocol used to communicate with the service. Protocol names are defined in theConstants
class.- Returns:
- the name of the protocol.
-
getTimeout
Integer getTimeout()Gets the timeout period in milliseconds. If a call takes longer than this amount of time, an exception will be thrown.- Returns:
- the timeout period in milliseconds. A null value indicates that the transport layer's default value will be used.
-
setUri
Sets the URI at which a Resource may be located.- Parameters:
aUri
- a URI string
-
setProtocol
Sets the name of the Protocol used to communicate with the service. Protocol names are defined in theConstants
class.- Parameters:
aProtocol
- the name of the protocol.
-
setTimeout
Sets the timeout period in milliseconds. If a call takes longer than this amount of time, an exception will be thrown.- Parameters:
aTimeout
- the timeout period in milliseconds. A null value indicates that the transport layer's default value will be used.
-
getParameters
Parameter[] getParameters()- Returns:
- Returns the Parameters.
-
setParameters
- Parameters:
parameters
- The Parameters to set.
-