public class XBRLTaxonomy extends XBRLDocument
The [Parent] property is the parent class XBRLDocument.
XBRLValidation.Direction| Modifier and Type | Field and Description |
|---|---|
static javax.xml.namespace.QName |
schemaNodeName
The document node name.
|
INSTANCE, IXBRL, LINKBASE, TAXONOMYCONCEPT_LABEL, CONCEPT_QNAME, EASY_TO_READ, ELEMENT_LABEL, EMPTYRELATIONSHIPSITERATORINSTANCE, EMPTYXMLFRAGMENTITERATORINSTANCE, FACT_CONCEPT_DATATYPE, FACT_CONCEPT_LABEL, FACT_QNAME, HIDE_COMMON_ACCURACY, idQName, NO_POSITION, OrderComparator, OrderComparator2, PERIOD_TYPE, PERIOD_VALUE, SHORT_TEXT, SOURCE_DOCUMENT, XPATH, XPOINTER| Constructor and Description |
|---|
XBRLTaxonomy(DTSContainer dts)
Creates a new empty XBRLTaxonomy instance.
|
XBRLTaxonomy(DTSContainer dts,
java.net.URI txBase,
java.net.URI txUri,
boolean bAddToCache,
XBRLDTSDocument parent)
Creates a new XBRLTaxonomy instance.
|
XBRLTaxonomy(XMLDocumentURI docURI,
boolean bAddToCache)
Creates a new XBRLTaxonomy instance from an XMLDocumentURI.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addArcroleType(XBRLArcroleType arcrole)
Adds a new arcrole type to the set of arcrole types defined in this
taxonomy.
|
void |
addElement(XMLElementDefinition newElement)
Add a new element to the taxonomy.
|
void |
addGlobalAttribute(XMLFragment attributeDefinitionHeaderNode)
Adds a new global attribute definition to this taxonomy schema.
|
void |
addGlobalAttributeGroup(XMLFragment attributeGroupDefinitionHeaderNode)
Adds a new global attributeGroup definition to this taxonomy schema.
|
void |
addGlobalGroup(XMLFragment groupDefinitionHeaderNode)
Adds a new global attributeGroup definition to this taxonomy schema.
|
void |
addGlobalType(XMLFragment typeDefinitionHeaderNode)
Adds a new global type definition to this taxonomy schema.
|
void |
addImport(XBRLImport imp)
Adds a new import to this taxonomy.
|
void |
addInclude(XBRLInclude inc)
Adds an XBRLInclude to this taxonomy.
|
void |
addLinkbase(XBRLLinkbase linkbase)
Adds a linkbase object to this taxonomy.
|
void |
addRoleType(XBRLRoleType role)
Adds a new role type to the set of role types defined in this
taxonomy.
|
void |
addXMLChild(XMLHasParent child)
Adds the xml child.
|
void |
clear()
Frees-up used memory
This method should not be invoqued on live objects in the DTS.
|
XMLElementDefinition |
convertNodeInfo(net.sf.saxon.s9api.XdmNode ni)
This method is used internally by the XBRL API in order to create an XMLElementDefinition
from an XdmNode.
|
void |
delElement(XMLElementDefinition element)
Deletes an element from the taxonomy
This function will not delete the relationships the element participates on.
|
boolean |
delGlobalAttribute(java.lang.String name)
Removes a Global attribute definition from this taxonomy schema.
|
boolean |
delGlobalAttributeGroup(java.lang.String name)
Removes a Global attributeGroup definition from this taxonomy schema.
|
boolean |
delGlobalGroup(java.lang.String name)
Removes a Global group definition from this taxonomy schema.
|
boolean |
delGlobalType(java.lang.String name)
Removes a Global Type definition from this taxonomy schema.
|
void |
discoverDTS(XBRLDTSDocument parent)
All derived classes MUST implement this method and provide the functionality according to section 3.2 of the
XBRL 2.1 specification
|
org.jdom.Document |
generateDocNode(boolean relativize,
java.net.URI base)
This class has to be implemented by objects derived from XBRLDocument
and must return a org.jdom.Document node with the content
of this XBRLDocument object
|
XBRLArcroleType |
getArcroleTypeByURI(java.lang.String uri)
Access to an arcrole type definition for a given URI if that arcrole type exists on
this taxonomy. returns null if there is no such arcrole type for the given URI.
|
java.util.Iterator<XBRLArcroleType> |
getArcroleTypes()
Returns an iterator over all arcrole types defined in this taxonomy.
|
java.util.Iterator<XMLElementDefinition> |
getConcepts()
Access to the [Concepts] property
This method does not return non XBRL concep definitions.
|
int |
getDTSDocumentType()
Returns the type of DTS Document.
|
java.lang.String |
getDTSDocumentTypeName()
Gets the DTS document type name.
|
XMLElementDefinition |
getElementDefinitionById(java.lang.String id)
Finds the element definition based on the element name and returns
an XMLDocument that can be an XMLDocument, an XBRLItem or an XBRLTuple
Returns null if not found.
|
XMLElementDefinition |
getElementDefinitionByName(java.lang.String name)
Finds the element definition based on the element name and returns
an XMLDocument that can be an XMLFragment, an XBRLItem or an XBRLTuple
Returns null if not found.
|
java.util.Iterator<XMLFragment> |
getElements()
For complex type resources this returns an iterator with all children XML fragments
This method may be overwriten by other classes in the hierarchy.
|
XBRLExtendedLink |
getExtendedLink(net.sf.saxon.s9api.XdmNode key)
Gets the extended link.
|
java.lang.String |
getFriendlyName()
Returns a string description that represents the element content in a form
that users can understand.
|
java.util.Iterator<java.lang.String> |
getGlobalAtributeGroups()
Access to an iterator over all global attribute groups.
|
XMLFragment |
getGlobalAttributeByName(java.lang.String name)
Returns a global attribute defined in this taxonomy schema by its name.
|
XMLFragment |
getGlobalAttributeGroupByName(java.lang.String name)
Returns a global attributeGroup defined in this taxonomy schema by its name.
|
java.util.Iterator<java.lang.String> |
getGlobalAttributes()
Access to an iterator over all global attributes.
|
XMLFragment |
getGlobalGroupByName(java.lang.String name)
Returns a global group defined in this taxonomy schema by its name.
|
java.util.Iterator<java.lang.String> |
getGlobalGroups()
Access to an iterator over all element groups defined.
|
XMLFragment |
getGlobalTypeByName(java.lang.String name)
Returns a global type defined in this taxonomy schema by its name or null if the taxonomy
schema has no a definition for a global type under the type name used in the name parameter.
|
java.util.Iterator<java.lang.String> |
getGlobalTypes()
Access to an iterator over all global types defined in the taxonomy.
|
XBRLTaxonomy |
getImport(java.net.URI namespace)
Return the XBRLTaxonomy imported for the namespace or null if the schema for the namespace is not imported.
|
java.util.Iterator<XBRLImport> |
getImports()
Return an iterator of all defined imports.
|
java.util.Iterator<XBRLInclude> |
getIncludes()
Access to the includes declared on this taxonomy.
|
java.util.Iterator<XBRLItem> |
getItems()
Access to the [Items] property.
|
java.util.Iterator<XBRLLinkbase> |
getLinkbases()
Return an iterator of all defined linkbases.
|
int |
getNumberOfItemDeclarations()
Returns the number of XBRL items defined in this XBRLTaxonomy.
|
int |
getNumberOfTupleDeclarations()
Returns the number of XBRL tuples defined in this XBRLTaxonomy.
|
XBRLRoleType |
getRoleTypeByURI(java.lang.String uri)
Access to a role type definition for a given URI if that role type exists on
this taxonomy. returns null if there is no such role type for the given URI.
|
java.util.Iterator<XBRLRoleType> |
getRoleTypes()
Returns an iterator over all role types defined in this taxonomy.
|
com.saxonica.schema.PreparedSchema |
getSchema()
Deprecated.
|
java.lang.String |
getTargetNamespace()
Access to the [Namespace] Property.
|
java.util.Iterator<XBRLTuple> |
getTuples()
Access to the [Tuples] property.
|
void |
readInfoset()
Read all structures that builds the infoset.
|
void |
removeArcroleType(XBRLArcroleType arcrole)
Removes an arcrole type from the set of arcrole types defined in this taxonomy.
|
void |
removeImport(XBRLImport imp)
Remove an existing import.
|
boolean |
removeInclude(XBRLInclude inc)
Removes am include form this taxonomy.
|
void |
removeLinkbase(XBRLLinkbase linkbase)
Removes a linkbase object that is referenced in this taxonomy.
|
void |
removeRoleType(XBRLRoleType role)
Removes a role type from the set of role types defined in this taxonomy.
|
void |
removeXMLChild(XMLHasParent child)
Removes the xml child.
|
void |
setDocumentAndReload(net.sf.saxon.s9api.XdmNode node)
This method is called by the XMLFragment object each time the surrounding XdmNode
object is set.
|
void |
setTargetNamespace(java.lang.String targetNamespace)
Sets or changes the targetNamespace for this schema .
|
addExtendedLink, addIdOfElement, addIdOfElement, addParent, changeElementId, changeExtendedLinkKey, createDocument, createDocument, delParent, equals, getAllUsedIds, getComments, getDocument, getDTS, getElementById, getExtendedLinks, getExtendedLinks, getParents, hashCode, isContentModified, isDocumentModified, isIdUsed, moveNamespacesUp, moveNamespacesUp, removeExtendedLink, removeIdOfElement, save, setComments, updateXMLaddChild, delChild, generateLocatorToDocument, getBase, getChildren, getDocumentURI, getDTSKey, getLocalFile, getValidationReport, invalidate, invalidate, isInDTS, isOnValidation, setURI, validateaddAttribute, addChild, addFromRelationship, addNamespace, addNamespace, addToRelationship, changeBase, checkBase, clone, clone, delAttribute, delAttribute, equalXdmValues, evaluateBoolean, evaluateList, evaluateNode, evaluateNumber, evaluateString, generateId, generateNode, generateNodeNamespacesAndAttributes, generateNodeValue, generatePrefix, getAllAttributes, getAttribute, getAttributeBooleanValue, getAttributeQNameValue, getAttributes, getAttributes, getAttributeStringValue, getAttributeValue, getBase, getBaseURI, getBooleanValue, getChild, getContainer, getContainerDocumentURI, getDeclaredNamespaces, getElementsHashCode, getFragment, getFriendlyName, getFromRelationships, getFromRelationships, getFromRelationships, getFromRelationships, getFromRelationships, getGenericLabelText, getId, getLang, getNamespaceURI, getNodeName, getNumberOfAttributes, getNumberOfElements, getNumberOfFromRelationships, getNumberOfToRelationships, getOrGenerateId, getParent, getPrefix, getPrefixes, getQNameValue, getRelationshipsBases, getRelationshipsChain, getRelationshipTypes, getStaticContext, getStaticNamespace, getStringValue, getToolTipText, getToRelationships, getToRelationships, getToRelationships, getToRelationships, getToRelationships, getValue, getXPathExecutable, getXPathNamespaceContext, getXPathToNode, getXPathToRoot, getXPointerElementScheme, getXPointerElementScheme, getXPointerShorthandScheme, getXPointerToNode, isDead, isNamespaceDefined, isXdmDocumentAttached, objEquals, objHashCode, qNameToString, removeAttribute, removeChild, removeChild, removeFromRelationship, removeToRelationship, resetElements, resetHash, resolve_equal2, resolveHRef, resolveHRef, s_equal2, s_equal2, s_equal2, setAttributes, setBase, setDocument, setElements, setId, setLang, setNamespaceContext, setNamespaces, setNode, setNodeName, setParent, setRegenerateNodeIfnotFound, setValue, setValue, setVariablesDefined, size, thin, toString, valueEquals, xEqualpublic static final javax.xml.namespace.QName schemaNodeName
public XBRLTaxonomy(DTSContainer dts, java.net.URI txBase, java.net.URI txUri, boolean bAddToCache, XBRLDTSDocument parent) throws DTSDiscoveryException
dts - current DTSContainer for the new XBRLTaxonomytxBase - the base URI for the creation of this taxonomytxUri - the taxonomy URI (official absolute URI)bAddToCache - boolean, true if the document should be added to the DTSContainer cache of read documents.parent - XBRLDTSDocument that is the parent of this document, this is only used if there are errors reading the document. Can be null.DTSDiscoveryException - the DTS discovery exceptionpublic XBRLTaxonomy(XMLDocumentURI docURI, boolean bAddToCache) throws DTSDiscoveryException
docURI - the doc uribAddToCache - the b add to cacheDTSDiscoveryException - the DTS discovery exceptionpublic XBRLTaxonomy(DTSContainer dts)
The taxonomy will not have any parent object and will not be added to the set of
taxonomies that belongs to the DTSContainer object. See DTSContainer.addDocumentToDTS(XBRLDTSDocument)
in order to allow DTSContainer.save(boolean) to serialize the taxonomy
to XML nodes. Don't forget to set a file name to this taxonomy before calling
the save method. see XMLDocumentURI.setURI(URI) for more information.
dts - the DTSContainer object.public void clear()
throws java.lang.Throwable
XMLFragmentThis method should not be invoqued on live objects in the DTS. It is automatically invoqued by the API when an object is no longer used and referenced by other objects. It is save not to call it directly.
clear in interface XBRLDTSDocumentclear in class XBRLDocumentjava.lang.Throwable - the throwablepublic void setDocumentAndReload(net.sf.saxon.s9api.XdmNode node)
throws XBRLInconsistentDTSException,
com.rs.lic.LicenseVerificationException
XMLFragmentOverwrite this method in parent objects in order to refresh objects that depends on the surrounding XML nodes.
setDocumentAndReload in class XBRLDocumentnode - the new XdmNodeXBRLInconsistentDTSException - the XBRL inconsistent dts exceptioncom.rs.lic.LicenseVerificationException - the license verification exception@Deprecated public com.saxonica.schema.PreparedSchema getSchema()
public java.lang.String getTargetNamespace()
public void setTargetNamespace(java.lang.String targetNamespace)
targetNamespace - the new target namespacepublic int getDTSDocumentType()
XBRLDocumentgetDTSDocumentType in class XBRLDocumentpublic java.util.Iterator<XMLElementDefinition> getConcepts()
public java.util.Iterator<XBRLItem> getItems()
public java.util.Iterator<XBRLTuple> getTuples()
public void addElement(XMLElementDefinition newElement)
newElement - the new elementpublic void delElement(XMLElementDefinition element)
This function will not delete the relationships the element participates on.
If the desire is to remove the concept from the taxonomy and the relationships
form existing extended links use the DTSContainer.delConcept(QName)
method instead.
element - the elementpublic XMLElementDefinition getElementDefinitionByName(java.lang.String name)
name - Element namepublic XMLElementDefinition getElementDefinitionById(java.lang.String id) throws XBRLValidationException
id - Element idXBRLValidationException - the XBRL validation exceptionpublic java.lang.String getDTSDocumentTypeName()
XBRLDocumentgetDTSDocumentTypeName in class XBRLDocumentpublic java.util.Iterator<XBRLInclude> getIncludes()
public java.util.Iterator<XBRLImport> getImports()
public XMLFragment getGlobalTypeByName(java.lang.String name)
name - the type namepublic java.util.Iterator<java.lang.String> getGlobalTypes()
public XMLFragment getGlobalAttributeByName(java.lang.String name)
name - the attribute namepublic java.util.Iterator<java.lang.String> getGlobalAttributes()
public XMLFragment getGlobalAttributeGroupByName(java.lang.String name)
name - the attributeGroup namepublic java.util.Iterator<java.lang.String> getGlobalAtributeGroups()
public XMLFragment getGlobalGroupByName(java.lang.String name)
name - the group namepublic java.util.Iterator<java.lang.String> getGlobalGroups()
public boolean delGlobalType(java.lang.String name)
name - the global type namepublic boolean delGlobalAttribute(java.lang.String name)
name - the global attribute namepublic boolean delGlobalAttributeGroup(java.lang.String name)
name - the global attributeGroup namepublic boolean delGlobalGroup(java.lang.String name)
name - the global group namepublic void addGlobalType(XMLFragment typeDefinitionHeaderNode)
The parameter must contain all nodes representing the type definition as nested XMLFragment objects
typeDefinitionHeaderNode - the first XMLFragment object. Must be a complexType node or
a simpleType node with an attribute o name "name". the attribute value will be
used in order to obtain the type name.public void addGlobalAttribute(XMLFragment attributeDefinitionHeaderNode)
The parameter must contain all nodes representing the attribute definition as nested XMLFragment objects
attributeDefinitionHeaderNode - the first XMLFragment object. Must be a xs:attribute node
with an attribute named "name". the attribute value will be
used in order to obtain the attribute name.public void addGlobalAttributeGroup(XMLFragment attributeGroupDefinitionHeaderNode)
The parameter must contain all nodes representing the attributeGroup definition as nested XMLFragment objects
attributeGroupDefinitionHeaderNode - the first XMLFragment object. Must be a xs:attributeGroup node
with an attribute named "name". the attribute value will be
used in order to obtain the attribute name.public void addGlobalGroup(XMLFragment groupDefinitionHeaderNode)
The parameter must contain all nodes representing the attributeGroup definition as nested XMLFragment objects
groupDefinitionHeaderNode - the first XMLFragment object. Must be a xs:attributeGroup node
with an attribute named "name". the attribute value will be
used in order to obtain the attribute name.public XBRLTaxonomy getImport(java.net.URI namespace)
namespace - the namespacepublic java.util.Iterator<XBRLLinkbase> getLinkbases()
public void addLinkbase(XBRLLinkbase linkbase)
linkbase - the linkbasepublic void removeLinkbase(XBRLLinkbase linkbase)
linkbase - to removepublic XBRLExtendedLink getExtendedLink(net.sf.saxon.s9api.XdmNode key) throws DTSDiscoveryException
XBRLDocumentgetExtendedLink in class XBRLDocumentkey - the keyDTSDiscoveryException - the DTS discovery exceptionpublic void discoverDTS(XBRLDTSDocument parent) throws DTSDiscoveryException, com.rs.lic.LicenseVerificationException
XBRLDocumentdiscoverDTS in interface XBRLDTSDocumentdiscoverDTS in class XBRLDocumentparent - the parentDTSDiscoveryException - the DTS discovery exceptioncom.rs.lic.LicenseVerificationException - the license verification exceptionpublic void addRoleType(XBRLRoleType role)
The XBRLRoleType object automatically calls this method when a parent is set to a role type.
role - XBRLRoleType to be addedpublic void removeRoleType(XBRLRoleType role)
The XBRLRoleType object automatically calls this method when a parent is set to a role type.
role - XBRLRoleType to be removedpublic java.util.Iterator<XBRLRoleType> getRoleTypes()
public XBRLRoleType getRoleTypeByURI(java.lang.String uri)
uri - as a Stringpublic void addArcroleType(XBRLArcroleType arcrole)
The XBRLArcroleType object automatically calls this method when a parent is set to an arcrole type.
arcrole - XBRLArcroleType to be addedpublic void removeArcroleType(XBRLArcroleType arcrole)
The XBRLArcroleType object automatically calls this method when a parent is set to an arcrole type.
arcrole - XBRLArcroleType to be removedpublic java.util.Iterator<XBRLArcroleType> getArcroleTypes()
public XBRLArcroleType getArcroleTypeByURI(java.lang.String uri)
uri - as a Stringpublic XMLElementDefinition convertNodeInfo(net.sf.saxon.s9api.XdmNode ni) throws XBRLValidationException
ni - XdmNodeXBRLValidationException - the XBRL validation exceptionpublic void readInfoset()
throws XBRLValidationException
XBRLDocumentreadInfoset in class XBRLDocumentXBRLValidationException - the XBRL validation exceptionpublic int getNumberOfItemDeclarations()
This is concept definitions that are in the xbrli:item substitution group or has xbrli:item on any on its ancestors in the substitution group hierarchy.
public int getNumberOfTupleDeclarations()
This is concept definitions that are in the xbrli:tuple substitution group or has xbrli:tuple on any on its ancestors in the substitution group hierarchy.
public org.jdom.Document generateDocNode(boolean relativize,
java.net.URI base)
throws XBRLSerializationException
XBRLDocumentgenerateDocNode in class XBRLDocumentrelativize - boolean indicating if all URIs must be relativizedbase - URI the base uri to relativize other URIsXBRLSerializationException - the XBRL serialization exceptionpublic void removeImport(XBRLImport imp)
imp - XBRLImportpublic void addInclude(XBRLInclude inc)
inc - the incpublic boolean removeInclude(XBRLInclude inc)
inc - the incpublic void addXMLChild(XMLHasParent child) throws XBRLInconsistentDTSException
XMLHasParentaddXMLChild in interface XMLHasParentaddXMLChild in class XMLFragmentchild - the childXBRLInconsistentDTSException - the XBRL inconsistent dts exceptionpublic void removeXMLChild(XMLHasParent child)
XMLHasParentremoveXMLChild in interface XMLHasParentremoveXMLChild in class XMLFragmentchild - the childpublic void addImport(XBRLImport imp) throws XBRLInconsistentDTSException
imp - XBRLImportXBRLInconsistentDTSException - the XBRL inconsistent dts exceptionpublic java.util.Iterator<XMLFragment> getElements()
XMLFragmentgetElements in class XMLFragmentpublic java.lang.String getFriendlyName()
XMLFragmentRemarks, this method may return very long names not suitable for user interface
getFriendlyName in class XMLFragment