Package: groovy.xml

## [Groovy] Class StreamingDOMBuilder

- groovy.xml.StreamingDOMBuilder

-     @SuppressWarnings(value="Instanceof")
      class StreamingDOMBuilder
      extends AbstractStreamingBuilder

  A streaming builder that creates W3C DOM content for GPath-style XML traversal or further DOM processing.

- - ### Properties Summary

    Properties
    Type | Name and description
    --- | ---
    `Object` | `builder` Backing namespace-aware builder reused for each bind(Closure) call.
    `Object` | `commentClosure` Closure backing `mkp.comment` for DOM comment node creation.
    `Object` | `defaultNamespaceStack` Stack tracking the currently active default namespace while nested elements are created.
    `Object` | `noopClosure` Closure backing text-yield operations when appending DOM nodes.
    `Object` | `pendingStack` Stack of pending namespace declarations restored after each nested element finishes.
    `Object` | `piClosure` Closure backing `mkp.pi` for DOM processing-instruction node creation.
    `Object` | `tagClosure` Default element-emitting closure used for ordinary DOM builder nodes.

  - Inherited properties
    Properties inherited from class | Properties
    --- | ---
    `class AbstractStreamingBuilder` | `aliasSetupClosure, badTagClosure, builder, getNamespaceClosure, namespaceSetupClosure, specialTags, toMapStringClosure`

  - ### Constructor Summary

    Constructors
    Constructor and description
    `StreamingDOMBuilder()` Creates a DOM-oriented builder with the standard `mkp` helper tags installed.

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `Object` | `bind(Object closure)` Binds a markup closure that can append to an existing DOM node or create a fresh document.

- - ### Property Detail

    - #### Object builder

      Backing namespace-aware builder reused for each bind(Closure) call.

    - #### Object commentClosure

      Closure backing `mkp.comment` for DOM comment node creation.

    - #### Object defaultNamespaceStack

      Stack tracking the currently active default namespace while nested elements are created.

    - #### Object noopClosure

      Closure backing text-yield operations when appending DOM nodes.

    - #### Object pendingStack

      Stack of pending namespace declarations restored after each nested element finishes.

    - #### Object piClosure

      Closure backing `mkp.pi` for DOM processing-instruction node creation.

    - #### Object tagClosure

      Default element-emitting closure used for ordinary DOM builder nodes.

  - ### Constructor Detail

    - #### StreamingDOMBuilder()

      Creates a DOM-oriented builder with the standard `mkp` helper tags installed.

  - ### Method Detail

    - #### Object bind(Object closure)

      Binds a markup closure that can append to an existing DOM node or create a fresh document.

      Parameters:
        `closure` - closure describing the XML to generate
      Returns:
        a closure that appends to a supplied DOM node or returns a new namespace-aware document