DAZ Script |
---|
DzDomDocument () |
DzDomDocument ( String nsURI, String qName, String publicId, String systemId ) |
DAZ Script | |
---|---|
DzDomAttr | createAttribute ( String name ) |
DzDomAttr | createAttributeNS ( String nsURI, String qName ) |
DzDomCDATASection | createCDATASection ( String value ) |
DzDomComment | createComment ( String value ) |
DzDomDocumentFragment | createDocumentFragment () |
DzDomElement | createElement ( String tagName ) |
DzDomElement | createElementNS ( String nsURI, String qName ) |
DzDomEntityReference | createEntityReference ( String name ) |
DzDomProcessingInstruction | createProcessingInstruction ( String target, String data ) |
DzDomText | createTextNode ( String value ) |
DzDomDocumentType | doctype () |
DzDomElement | documentElement () |
DzDomNode | elementById ( String id ) |
DzDomNode | importNode ( DzDomNode node, Boolean deep ) |
Boolean | loadContent ( String filename ) |
Boolean | saveContent ( String filename ) |
Boolean | setContent ( String text ) |
ByteArray | toByteArray ( Number indent=1 ) |
String | toString ( Number indent=1 ) |
A script wrapper for QDomDocument. This object represents an entire DOM document. Conceptually, it is the root of the document tree and provides the primary access to the document's data.
This is the only DzDomNode derived object that is constructed directly.
To populate a document, use loadContent() to cause data to be parsed from an XML (or XML derivative) file, or use setContent() to cause data to be parsed from an XML (or XML derivative) string.
Note that it is also possible to create nodes of the DOM tree from scratch by using the following factory functions:
The parsed XML data is represented by an internal tree of nodes that can be accessed using DzDomNode (and derived) objects. The internal objects in the DOM tree are deleted once the last DOM object referencing them and the DzDomDocument itself are deleted.
For more information about the Document Object Model (DOM) see the Level 1 and Level 2 Core specifications.
Default constructor.
Return Value:
DzDomDocument( String nsURI, String qName, String publicId, String systemId )
Parameter(s):
Return Value:
nsURI
namespace, with a root element named qName
, and a document type of qName
with the public identifier of.publicId
and the system identifier systemId
.Attention:
Since:
DzDomAttr : createAttribute( String name )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomAttr : createAttributeNS( String nsURI, String qName )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomCDATASection : createCDATASection( String value )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomComment : createComment( String value )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomDocumentFragment : createDocumentFragment()
Return Value:
Attention:
See Also:
DzDomElement : createElement( String tagName )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomElement : createElementNS( String nsURI, String qName )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomEntityReference : createEntityReference( String name )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomProcessingInstruction : createProcessingInstruction( String target, String data )
Parameter(s):
Return Value:
Attention:
See Also:
DzDomText : createTextNode( String value )
Parameter(s):
Return Value:
Attention:
See Also:
Return Value:
DzDomElement : documentElement()
Return Value:
Since:
DzDomNode : elementById( String id )
Parameter(s):
Return Value:
elementId
(if any), otherwise a null element.Attention:
DzDomNode : importNode( DzDomNode node, Boolean deep )
Parameter(s):
true
, node
and all of its children are imported recursively. If false
, only node
is imported.Return Value:
Attention:
See Also:
Boolean : loadContent( String filename )
Sets the contents of the document by parsing the file at the specified path.
Parameter(s):
Return Value:
true
if the file was successfully parsed, otherwise false
.Boolean : saveContent( String filename )
Saves the contents of the document to the specified file.
Parameter(s):
Return Value:
true
if the file was successfully saved, otherwise false
.Boolean : setContent( String text )
Sets the contents of this document from the specified string.
Parameter(s):
Return Value:
true
if the string was successfully parsed, otherwise false
.See Also:
ByteArray : toByteArray( Number indent=1 )
Parameter(s):
Return Value:
Since:
String : toString( Number indent=1 )
Parameter(s):
Return Value: