Contextual information and API during DOM conversion.

Constructors

Properties

targetDefaultNamespaceURI: null | string
targetDocument: Document

Methods

  • Parameters

    • localName: string

    Returns Attr

  • Parameters

    • namespaceURI: null | string
    • qualifiedName: string

    Returns Attr

  • Creates a CDATA section owned by targetDocument.

    Parameters

    • data: string

      CDATA text

    Returns CDATASection

  • Creates a Comment owned by targetDocument.

    Parameters

    • data: string

      text

    Returns Comment

  • Creates an empty DocumentFragment owned by targetDocument.

    Returns DocumentFragment

  • Creates the element with given local name with default namespace of the target document.

    Parameters

    • localName: string

      local name of the element to create

    Returns Element

  • Forwards to createElementNS in targetDocument.

    Parameters

    • namespaceURI: null | string

      namespace URI

    • qualifiedName: string

      qualified name of the element to create

    Returns Element

  • Creates a Range owned by targetDocument.

    Returns Range

  • Creates a Text node owned by targetDocument.

    Parameters

    • data: string

      text

    Returns Text

  • Imports nodes similar to Document.importNode. In contrast to `Document.importNode´ this method tries to also adapt the namespace URIs of corresponding nodes: If they were of the default namespace in the source document, they will now use the default namespace of the target document.

    @param node - node to import @param deep - if to include children; defaults to false.

    Parameters

    • node: Node
    • deep: boolean = false

    Returns Node