net.sf.saxon.tree.wrapper

## Interface VirtualNode

- All Superinterfaces:
    Item, NodeInfo, PullEvent, Sequence, Source
  All Known Implementing Classes:
    AbstractNodeWrapper, AbstractVirtualNode, AxiomAttributeWrapper, AxiomDocumentWrapper, AxiomElementNodeWrapper, AxiomLeafNodeWrapper, AxiomParentNodeWrapper, DocumentWrapper, DOM4JDocumentWrapper, DOM4JNodeWrapper, DOMNodeWrapper, JDOM2DocumentWrapper, JDOM2NodeWrapper, JDOMDocumentWrapper, JDOMNodeWrapper, SpaceStrippedDocument, SpaceStrippedNode, TypeStrippedDocument, TypeStrippedNode, XOMDocumentWrapper, XOMNodeWrapper

      public interface VirtualNode
      extends NodeInfo

  This interface is implemented by NodeInfo implementations that act as wrappers on some underlying tree. It provides a method to access the real node underlying the virtual node, for use by applications that need to drill down to the underlying data.

- - ### Field Summary

    - ### Fields inherited from interface net.sf.saxon.om.NodeInfo

      `ALL_NAMESPACES, IS_DTD_TYPE, IS_NILLED, LOCAL_NAMESPACES, NO_NAMESPACES`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `Object` | `getRealNode()` Get the node underlying this virtual node.
    `Object` | `getUnderlyingNode()` Get the node underlying this virtual node.

    - ### Methods inherited from interface net.sf.saxon.om.NodeInfo

      `atomize, compareOrder, comparePosition, copy, equals, generateId, getAttributeValue, getBaseURI, getColumnNumber, getConfiguration, getDeclaredNamespaces, getDisplayName, getDocumentNumber, getDocumentRoot, getFingerprint, getLineNumber, getLocalPart, getNameCode, getNamePool, getNodeKind, getParent, getPrefix, getRoot, getSchemaType, getStringValue, getSystemId, getTypeAnnotation, getURI, hasChildNodes, hashCode, isId, isIdref, isNilled, isSameNodeInfo, iterateAxis, iterateAxis`

    - ### Methods inherited from interface javax.xml.transform.Source

      `setSystemId`

    - ### Methods inherited from interface net.sf.saxon.om.Item

      `getStringValueCS`

    - ### Methods inherited from interface net.sf.saxon.om.Sequence

      `head, iterate`

- - ### Method Detail

    - #### getUnderlyingNode

          Object getUnderlyingNode()

      Get the node underlying this virtual node. Note that this may itself be a VirtualNode; you may have to drill down through several layers of wrapping.

      In some cases a single VirtualNode may represent an XPath text node that maps to a sequence of adjacent nodes (for example text nodes and CDATA nodes) in the underlying tree. In this case the first node in this sequence is returned.

      Returns:
        The underlying node.

    - #### getRealNode

          Object getRealNode()

      Get the node underlying this virtual node. If this is a VirtualNode the method will automatically drill down through several layers of wrapping.

      In some cases a single VirtualNode may represent an XPath text node that maps to a sequence of adjacent nodes (for example text nodes and CDATA nodes) in the underlying tree. In this case the first node in this sequence is returned.

      Returns:
        The underlying node.

Copyright (c) 2004-2013 Saxonica Limited. All rights reserved.