The type of the document element.
The type of the document element.
The ("stable") document type itself.
The ("stable") document type itself. It is not restricted in the "document API" traits and classes (only indirectly, through ThisDocApi).
Concrete document classes will restrict this type to that document class itself.
Upperbound on type ThisDoc, which must be restricted to a sub-type of the "document API" trait or class in question.
Upperbound on type ThisDoc, which must be restricted to a sub-type of the "document API" trait or class in question.
Concrete document classes will restrict this type to that document class itself.
Expensive method to obtain all comments, throughout the tree
Expensive method to obtain all processing instructions, throughout the tree
Returns the document element
Returns the document element
Returns the tree representation string corresponding to this element, that is, toTreeRepr.
Returns the tree representation string corresponding to this element, that is, toTreeRepr. Possibly expensive!
Returns withDocumentElement(this.documentElement.transformElemsOrSelf(f))
Returns withDocumentElement(this.documentElement.transformElemsToNodeSeq(f))
Returns withDocumentElement(this.documentElement.updateElemOrSelf(path, newElem))
Returns withDocumentElement(this.documentElement.updateElemOrSelf(path)(f)).
Returns withDocumentElement(this.documentElement.updateElemWithNodeSeq(path, newNodes))
Returns withDocumentElement(this.documentElement.updateElemWithNodeSeq(path)(f))
Returns withDocumentElement(this.documentElement.updateElemsOrSelf(paths)(f))
Returns withDocumentElement(this.documentElement.updateElemsWithNodeSeq(paths)(f))
Returns withDocumentElement(this.documentElement.updateTopmostElemsOrSelf(f))
Returns withDocumentElement(this.documentElement.updateTopmostElemsWithNodeSeq(f))
Returns the optional document URI, wrapped in an Option
Returns the optional document URI, wrapped in an Option
Creates a copy, but with the new documentElement passed as parameter newRoot
Creates a copy, but with the new uriOption passed as parameter newUriOption
Creates a copy, but with the new xmlDeclarationOption passed as parameter newXmlDeclarationOption
(Since version 1.5.0) Renamed to 'updateElemOrSelf'
(Since version 1.5.0) Renamed to 'updateElemOrSelf'
(Since version 1.5.0) Renamed to 'updateElemsOrSelf'
(Since version 1.5.0) Renamed to 'updateElemWithNodeSeq'
(Since version 1.5.0) Renamed to 'updateElemWithNodeSeq'
Document. Although at first sight the document root element seems to be the root node, this is not entirely true. For example, there may be comments at top level, outside the document root element.The document is itself not a
Node. This choice has the following advantages:toTreeReprshould not be passed a parent scope. By not considering a Document a Node, it is more visible that parent scopes are irrelevant for Documents, unlike for "elements".A
Documentis constructed from an optional URI, an optional XML declaration, a document element (asElem), top-level processing instructions, if any, and top-level comments, if any.Note that class
Documentdoes not have any query methods forEleminstances. In particular, theElemApidoes not apply to documents. Therefore, given a document, querying for elements (other than the document element itself) always goes via the document element.