Class TypeSystemDescription_impl
- java.lang.Object
-
- org.apache.uima.resource.metadata.impl.MetaDataObject_impl
-
- org.apache.uima.resource.metadata.impl.TypeSystemDescription_impl
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
,MetaDataObject
,TypeSystemDescription
,XMLizable
public class TypeSystemDescription_impl extends MetaDataObject_impl implements TypeSystemDescription
Reference implementation ofTypeSystemDescription
.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.uima.resource.metadata.impl.MetaDataObject_impl
MetaDataObject_impl.MetaDataAttr, MetaDataObject_impl.SerialContext, MetaDataObject_impl.Serializer
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
mDescription
private Import[]
mImports
private java.lang.String
mName
private TypeDescription[]
mTypes
Descriptions of all Types in this type system.private java.lang.String
mVendor
private java.lang.String
mVersion
(package private) static long
serialVersionUID
private static XmlizationInfo
XMLIZATION_INFO
-
Fields inherited from class org.apache.uima.resource.metadata.impl.MetaDataObject_impl
serialContext
-
Fields inherited from interface org.apache.uima.resource.metadata.TypeSystemDescription
EMPTY_TYPE_SYSTEM_DESCRIPTIONS
-
-
Constructor Summary
Constructors Constructor Description TypeSystemDescription_impl()
Creates a new TypeSystemDescription_impl.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description TypeDescription
addType(java.lang.String aTypeName, java.lang.String aDescription, java.lang.String aSupertypeName)
Adds a Type to this TypeSystem fragment.java.lang.String
getDescription()
Gets the description of this Type System.Import[]
getImports()
Gets the imports declared by this Type System.java.lang.String
getName()
Gets the name of this Type System.TypeDescription
getType(java.lang.String aTypeName)
Retrieves a Type from this TypeSystem fragment.TypeDescription[]
getTypes()
Gets descriptions of all Types in this TypeSystem fragment.java.lang.String
getVendor()
Gets the vendor of this Type System.java.lang.String
getVersion()
Gets the version number of this Type System.protected XmlizationInfo
getXmlizationInfo()
To be implemented by subclasses to return information describing how to represent this object in XML.void
resolveImports()
Resolves any import declarations in this type system, adding the imported types directly onto this TypeSystemDescription'stypes
list.void
resolveImports(java.util.Collection<java.lang.String> aAlreadyImportedTypeSystemURLs, ResourceManager aResourceManager)
Deprecated.void
resolveImports(ResourceManager aResourceManager)
Resolves any import declarations in this type system, adding the imported types directly onto this TypeSystemDescription'stypes
list.void
setDescription(java.lang.String aDescription)
Sets the description of this Type System.void
setImports(Import[] aImports)
Sets the imports declared by this Type System.void
setName(java.lang.String aName)
Sets the name of this Type System.void
setTypes(TypeDescription[] aTypes)
Sets the descriptions of all Types in this TypeSystem fragment.void
setVendor(java.lang.String aVendor)
Sets the vendor of this Type System.void
setVersion(java.lang.String aVersion)
Sets the version number of this Type System.-
Methods inherited from class org.apache.uima.resource.metadata.impl.MetaDataObject_impl
buildFromXMLElement, buildFromXMLElement, clone, equals, getAdditionalAttributes, getAttributeClass, getAttributes, getAttributeValue, getInfoset, getMatchingNode, getPropertyDescriptors, getPropertyXmlInfo, getRelativePathBase, getSerialContext, getSourceUrl, getSourceUrlString, getUnfilteredAttributes, getWrapperClass, getXMLAttributes, hashCode, isModifiable, listAttributes, readArrayPropertyValueFromXMLElement, readMapPropertyFromXml, readPropertyValueFromXMLElement, readUnknownPropertyValueFromXMLElement, resolveSettings, setAttributeValue, setInfoset, setSourceUrl, setSourceUrlIfNull, toString, toXML, toXML, toXML, toXML, valueIsNullOrEmptyArray, writeArrayPropertyAsElement, writeMapPropertyToXml, writePropertyAsElement
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
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 Detail
-
serialVersionUID
static final long serialVersionUID
- See Also:
- Constant Field Values
-
mName
private java.lang.String mName
-
mVersion
private java.lang.String mVersion
-
mDescription
private java.lang.String mDescription
-
mVendor
private java.lang.String mVendor
-
mImports
private Import[] mImports
-
mTypes
private TypeDescription[] mTypes
Descriptions of all Types in this type system.
-
XMLIZATION_INFO
private static final XmlizationInfo XMLIZATION_INFO
-
-
Method Detail
-
getName
public java.lang.String getName()
Description copied from interface:TypeSystemDescription
Gets the name of this Type System.- Specified by:
getName
in interfaceTypeSystemDescription
- Returns:
- the name of this Type System, null if none has been specified.
- See Also:
ResourceMetaData.getName()
-
setName
public void setName(java.lang.String aName)
Description copied from interface:TypeSystemDescription
Sets the name of this Type System.- Specified by:
setName
in interfaceTypeSystemDescription
- Parameters:
aName
- the name of this Type System- See Also:
ResourceMetaData.setName(String)
-
getVersion
public java.lang.String getVersion()
Description copied from interface:TypeSystemDescription
Gets the version number of this Type System.- Specified by:
getVersion
in interfaceTypeSystemDescription
- Returns:
- the version number of this Type System, as a String, null if none has been specified.
- See Also:
ResourceMetaData.getVersion()
-
setVersion
public void setVersion(java.lang.String aVersion)
Description copied from interface:TypeSystemDescription
Sets the version number of this Type System.- Specified by:
setVersion
in interfaceTypeSystemDescription
- Parameters:
aVersion
- the version number of this Type System, as a String- See Also:
ResourceMetaData.setVersion(String)
-
getDescription
public java.lang.String getDescription()
Description copied from interface:TypeSystemDescription
Gets the description of this Type System.- Specified by:
getDescription
in interfaceTypeSystemDescription
- Returns:
- the description of this Type System, null if none has been specified.
- See Also:
ResourceMetaData.getDescription()
-
setDescription
public void setDescription(java.lang.String aDescription)
Description copied from interface:TypeSystemDescription
Sets the description of this Type System.- Specified by:
setDescription
in interfaceTypeSystemDescription
- Parameters:
aDescription
- the description of this Type System- See Also:
ResourceMetaData.setDescription(String)
-
getVendor
public java.lang.String getVendor()
Description copied from interface:TypeSystemDescription
Gets the vendor of this Type System.- Specified by:
getVendor
in interfaceTypeSystemDescription
- Returns:
- the vendor of this Type System, as a String
- See Also:
ResourceMetaData.getVendor()
-
setVendor
public void setVendor(java.lang.String aVendor)
Description copied from interface:TypeSystemDescription
Sets the vendor of this Type System.- Specified by:
setVendor
in interfaceTypeSystemDescription
- Parameters:
aVendor
- the vendor of this Type System, as a String, null if none has been specified.- See Also:
ResourceMetaData.setVendor(String)
-
getImports
public Import[] getImports()
Description copied from interface:TypeSystemDescription
Gets the imports declared by this Type System.- Specified by:
getImports
in interfaceTypeSystemDescription
- Returns:
- an array of imports declared by this type system.
- See Also:
TypeSystemDescription.getImports()
-
setImports
public void setImports(Import[] aImports)
Description copied from interface:TypeSystemDescription
Sets the imports declared by this Type System.- Specified by:
setImports
in interfaceTypeSystemDescription
- Parameters:
aImports
- an array of imports declared by this type system.- See Also:
TypeSystemDescription.setImports(Import[])
-
getTypes
public TypeDescription[] getTypes()
Description copied from interface:TypeSystemDescription
Gets descriptions of all Types in this TypeSystem fragment.- Specified by:
getTypes
in interfaceTypeSystemDescription
- Returns:
- descriptions of all Types in this TypeSystem fragment
- See Also:
TypeSystemDescription.getTypes()
-
setTypes
public void setTypes(TypeDescription[] aTypes)
Description copied from interface:TypeSystemDescription
Sets the descriptions of all Types in this TypeSystem fragment.- Specified by:
setTypes
in interfaceTypeSystemDescription
- Parameters:
aTypes
- descriptions of all Types in this TypeSystem fragment- See Also:
TypeSystemDescription.setTypes(TypeDescription[])
-
addType
public TypeDescription addType(java.lang.String aTypeName, java.lang.String aDescription, java.lang.String aSupertypeName)
Description copied from interface:TypeSystemDescription
Adds a Type to this TypeSystem fragment.- Specified by:
addType
in interfaceTypeSystemDescription
- Parameters:
aTypeName
- name of Type to addaDescription
- verbose description of this TypeaSupertypeName
- name of supertype for the new Type- Returns:
- description of the new Type
- See Also:
TypeSystemDescription.addType(String, String, String)
-
getType
public TypeDescription getType(java.lang.String aTypeName)
Description copied from interface:TypeSystemDescription
Retrieves a Type from this TypeSystem fragment.- Specified by:
getType
in interfaceTypeSystemDescription
- Parameters:
aTypeName
- name of Type to retrieve- Returns:
- the type with the specified name,
null
if no such type exists - See Also:
TypeSystemDescription.getType(java.lang.String)
-
resolveImports
public void resolveImports() throws InvalidXMLException
Description copied from interface:TypeSystemDescription
Resolves any import declarations in this type system, adding the imported types directly onto this TypeSystemDescription'stypes
list. The import elements are then deleted, so this results in a structure that is equivalent to the imported elements having been defined locally.- Specified by:
resolveImports
in interfaceTypeSystemDescription
- Throws:
InvalidXMLException
- if either the import target does not exist or is invalid- See Also:
TypeSystemDescription.resolveImports()
-
resolveImports
public void resolveImports(ResourceManager aResourceManager) throws InvalidXMLException
Description copied from interface:TypeSystemDescription
Resolves any import declarations in this type system, adding the imported types directly onto this TypeSystemDescription'stypes
list. The import elements are then deleted, so this results in a structure that is equivalent to the imported elements having been defined locally.- Specified by:
resolveImports
in interfaceTypeSystemDescription
- Parameters:
aResourceManager
- the Resource Manager used to locate type systems imported by name. For example, the path in which to locate these type systems can be set via theResourceManager.setDataPath(String)
method.- Throws:
InvalidXMLException
- if either the import target does not exist or is invalid
-
resolveImports
@Deprecated public void resolveImports(java.util.Collection<java.lang.String> aAlreadyImportedTypeSystemURLs, ResourceManager aResourceManager) throws InvalidXMLException
Deprecated.Description copied from interface:TypeSystemDescription
Resolves any import declarations in this type system, adding the imported types directly onto this TypeSystemDescription'stypes
list. The import elements are then deleted, so this results in a structure that is equivalent to the imported elements having been defined locally.This version is used internally to resolve nested imports.
- Specified by:
resolveImports
in interfaceTypeSystemDescription
- Parameters:
aAlreadyImportedTypeSystemURLs
- URLs of already imported type systems, so we don't import them again.aResourceManager
- the Resource Manager used to locate type systems imported by name. For example, the path in which to locate these type systems can be set via theResourceManager.setDataPath(String)
method.- Throws:
InvalidXMLException
- if either the import target does not exist or is invalid
-
getXmlizationInfo
protected XmlizationInfo getXmlizationInfo()
Description copied from class:MetaDataObject_impl
To be implemented by subclasses to return information describing how to represent this object in XML.- Specified by:
getXmlizationInfo
in classMetaDataObject_impl
- Returns:
- information defining this object's XML representation
-
-