public class VODocument extends DelegatingDocument
VOElement
,
or of VOElement
subclasses according to their element names,
that is any element with a tagname of "TABLE" in this DOM will be
an instance of the class TableElement
and so on.ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
Constructor and Description |
---|
VODocument()
Constructs a new VODocument.
|
VODocument(String systemId,
boolean strict)
Constructs a new VODocument with a specified System ID.
|
Modifier and Type | Method and Description |
---|---|
protected DelegatingAttr |
createDelegatingAttr(Attr baseNode)
Creates a new node in this document that delegates to an object
of class
Attr
in the base model. |
protected DelegatingElement |
createDelegatingElement(Element node)
Creates a new node in this document that delegates to an object
of class
Element
in the base model. |
DelegatingNode |
getDelegator(Node base)
Returns the node in this document which delegates to (is based on)
a given node in the base document.
|
Element |
getElementById(String elementId) |
int |
getElementCount(String voTagName)
Returns the number of elements of a given name
which have so far been added to this document.
|
StoragePolicy |
getStoragePolicy()
Returns the storage policy used for storing bulk table data found
as elements in the DOM into a usable form.
|
String |
getSystemId()
Returns the system ID associated with this document.
|
String |
getVOTagName(Element el)
Returns the unqualified tag name for an element in the VOTable namespace,
taking care of namespacing issues.
|
void |
setElementId(Element el,
String id)
Stores an element as the referent of a given ID string.
|
void |
setStoragePolicy(StoragePolicy policy)
Sets the storage policy used for storing bulk table data found
as elements in the DOM into a usable form.
|
adoptNode, createAttribute, createAttributeNS, createCDATASection, createComment, createDelegatingAttr, createDelegatingCDATASection, createDelegatingCharacterData, createDelegatingComment, createDelegatingDocumentFragment, createDelegatingDocumentType, createDelegatingEntity, createDelegatingEntityReference, createDelegatingNamedNodeMap, createDelegatingNodeList, createDelegatingNotation, createDelegatingProcessingInstruction, createDelegatingSimpleNode, createDelegatingText, createDocumentFragment, createElement, createElementNS, createEntityReference, createProcessingInstruction, createTextNode, getBaseDocument, getDoctype, getDocumentElement, getDocumentURI, getDomConfig, getElementsByTagName, getElementsByTagNameNS, getImplementation, getInputEncoding, getStrictErrorChecking, getXmlEncoding, getXmlStandalone, getXmlVersion, importNode, normalizeDocument, renameNode, setDocumentURI, setStrictErrorChecking, setXmlStandalone, setXmlVersion
appendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
appendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData
public VODocument(String systemId, boolean strict)
systemId
- system ID for the VOTable document represented by
this DOM (sometimes used for resolving URLs) - may be nullstrict
- whether to enforce the VOTable standard strictly
or in some cases do what is probably meant
(see VOElementFactory.setStrict(boolean)
)public VODocument()
public String getSystemId()
public StoragePolicy getStoragePolicy()
public void setStoragePolicy(StoragePolicy policy)
StoragePolicy.PREFER_MEMORY
.policy
- new policypublic void setElementId(Element el, String id)
getElementById(java.lang.String)
method.public Element getElementById(String elementId)
getElementById
in interface Document
getElementById
in class DelegatingDocument
public DelegatingNode getDelegator(Node base)
DelegatingDocument
getDelegator
in class DelegatingDocument
base
- node in the base documentpublic int getElementCount(String voTagName)
voTagName
- VOTable-domain tag nameprotected DelegatingElement createDelegatingElement(Element node)
DelegatingDocument
Element
in the base model. This may be overridden to create specialised
node types.createDelegatingElement
in class DelegatingDocument
node
- delegate nodebaseNode
protected DelegatingAttr createDelegatingAttr(Attr baseNode)
DelegatingDocument
Attr
in the base model. This may be overridden to create specialised
node types.createDelegatingAttr
in class DelegatingDocument
baseNode
- delegate nodebaseNode
Copyright © 2024 Central Laboratory of the Research Councils. All Rights Reserved.