|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--oracle.xml.parser.v2.NodeFactory
This class specifies methods to create various nodes of the DOM tree built during parsing. Applications can override these methods to create their own custom classes to be added to the DOM tree while parsing. Applications have to register their own NodeFactory using the XMLParser's setNodeFactory() method. If a null pointer is returned by these methods, then the node will not be added to the DOM tree.
DOMParser.setNodeFactory(oracle.xml.parser.v2.NodeFactory)
, Serialized FormConstructor Summary |
NodeFactory()
|
Method Summary |
Type | Method |
---|---|
XMLAttr |
createAttribute(java.lang.String tag,
java.lang.String text)
Creates an attribute node with the specified tag, and text. |
XMLAttr |
createAttribute(java.lang.String localName,
java.lang.String prefix,
java.lang.String namespaceURI,
java.lang.String value)
|
XMLCDATA |
createCDATASection(java.lang.String text)
Creates a CDATA node with the specified text. |
XMLComment |
createComment(java.lang.String text)
Creates a comment node with the specified text. |
XMLDocument |
createDocument()
Creates a document node. |
XMLDocumentFragment |
createDocumentFragment()
Creates a document fragment node with the specified tag. |
XMLElement |
createElement(java.lang.String tag)
Creates an Element node with the specified tag. |
XMLElement |
createElementNS(java.lang.String localName,
java.lang.String prefix,
java.lang.String namespaceURI)
Creates an Element node with the specified local name,prefix , namespaceURI. |
XMLEntityReference |
createEntityReference(java.lang.String tag)
Creates an entity reference node with the specified tag. |
XMLPI |
createProcessingInstruction(java.lang.String tag,
java.lang.String text)
Creates a PI node with the specified tag, and text. |
XMLText |
createTextNode(java.lang.String text)
Creates a text node with the specified text. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public NodeFactory()
Method Detail |
public XMLElement createElement(java.lang.String tag)
tag
- The name of the element.public XMLElement createElementNS(java.lang.String localName, java.lang.String prefix, java.lang.String namespaceURI)
The
- local name of the element, prefix of the element,
namespaceURI of the elementpublic XMLDocument createDocument()
public XMLText createTextNode(java.lang.String text)
text
- The text associated with the node.public XMLCDATA createCDATASection(java.lang.String text)
text
- The text associated with the node.public XMLComment createComment(java.lang.String text)
text
- The text associated with the node.public XMLPI createProcessingInstruction(java.lang.String tag, java.lang.String text)
tag
- The name of the node.text
- The text associated with the node.public XMLAttr createAttribute(java.lang.String tag, java.lang.String text)
tag
- The name of the node.text
- The text associated with the node.public XMLAttr createAttribute(java.lang.String localName, java.lang.String prefix, java.lang.String namespaceURI, java.lang.String value)
public XMLDocumentFragment createDocumentFragment()
tag
- The name of the node.public XMLEntityReference createEntityReference(java.lang.String tag)
tag
- The name of the node.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |