org.apache.xalan.xsltc.dom
Class DOMAdapter

java.lang.Object
  extended by org.apache.xalan.xsltc.dom.DOMAdapter
All Implemented Interfaces:
DOM

public final class DOMAdapter
extends java.lang.Object
implements DOM


Field Summary
private  DOM _dom
           
private  DOMEnhancedForDTM _enhancedDOM
           
private  StripFilter _filter
           
private  short[] _mapping
           
private  int _multiDOMMask
           
private  java.lang.String[] _namesArray
           
private  java.lang.String[] _namespaceArray
           
private  short[] _NSmapping
           
private  short[] _NSreverse
           
private  int[] _reverse
           
private  int[] _typesArray
           
private  java.lang.String[] _urisArray
           
 
Fields inherited from interface org.apache.xalan.xsltc.DOM
ADAPTIVE_RTF, FIRST_TYPE, NO_TYPE, NULL, RETURN_CURRENT, RETURN_PARENT, SIMPLE_RTF, TREE_RTF
 
Constructor Summary
DOMAdapter(DOM dom, java.lang.String[] namesArray, java.lang.String[] urisArray, int[] typesArray, java.lang.String[] namespaceArray)
           
 
Method Summary
 void characters(int textNode, SerializationHandler handler)
           
 void copy(DTMAxisIterator nodes, SerializationHandler handler)
           
 void copy(int node, SerializationHandler handler)
           
 int getAttributeNode(int type, int element)
           
 DTMAxisIterator getAxisIterator(int axis)
           
 DTMAxisIterator getChildren(int node)
           
 int getDocument()
           
 java.lang.String getDocumentURI()
           
 java.lang.String getDocumentURI(int node)
           
 DOM getDOMImpl()
           
 Hashtable getElementsWithIDs()
           
 int getExpandedTypeID(int node)
           
 DTMAxisIterator getIterator()
          Returns singleton iterator containg the document root
 java.lang.String getLanguage(int node)
           
private  short[] getMapping()
           
 int getMultiDOMMask()
           
 java.lang.String[] getNamesArray()
           
 java.lang.String[] getNamespaceArray()
           
 DTMAxisIterator getNamespaceAxisIterator(int axis, int ns)
           
 java.lang.String getNamespaceName(int node)
           
 int getNamespaceType(int node)
           
 int getNodeHandle(int nodeId)
           
 int getNodeIdent(int nodeHandle)
           
 java.lang.String getNodeName(int node)
           
 java.lang.String getNodeNameX(int node)
           
 DTMAxisIterator getNodeValueIterator(DTMAxisIterator iterator, int type, java.lang.String value, boolean op)
           
private  short[] getNSMapping()
           
private  short[] getNSReverse()
           
 int getNSType(int node)
           
 DTMAxisIterator getNthDescendant(int type, int n, boolean includeself)
           
 SerializationHandler getOutputDomBuilder()
          Returns a SerializationHandler class wrapped in a SAX adapter.
 int getParent(int node)
           
 DOM getResultTreeFrag(int initSize, int rtfType)
          Return a instance of a DOM class to be used as an RTF
 DOM getResultTreeFrag(int initSize, int rtfType, boolean addToManager)
          Return a instance of a DOM class to be used as an RTF
private  int[] getReverse()
           
 int getSize()
           
 java.lang.String getStringValue()
           
 java.lang.String getStringValueX(int node)
           
 DTMAxisIterator getTypedAxisIterator(int axis, int type)
           
 DTMAxisIterator getTypedChildren(int type)
           
 int[] getTypesArray()
           
 java.lang.String getUnparsedEntityURI(java.lang.String entity)
           
 java.lang.String[] getUrisArray()
           
 boolean isAttribute(int node)
           
 boolean isElement(int node)
           
 boolean lessThan(int node1, int node2)
           
 java.lang.String lookupNamespace(int node, java.lang.String prefix)
           
 org.w3c.dom.Node makeNode(DTMAxisIterator iter)
           
 org.w3c.dom.Node makeNode(int index)
           
 org.w3c.dom.NodeList makeNodeList(DTMAxisIterator iter)
           
 org.w3c.dom.NodeList makeNodeList(int index)
           
 DTMAxisIterator orderNodes(DTMAxisIterator source, int node)
           
 void setDocumentURI(java.lang.String uri)
           
 void setFilter(StripFilter filter)
           
 void setMultiDOMMask(int mask)
           
 void setupMapping(java.lang.String[] names, java.lang.String[] urisArray, int[] typesArray, java.lang.String[] namespaces)
           
 java.lang.String shallowCopy(int node, SerializationHandler handler)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_enhancedDOM

private DOMEnhancedForDTM _enhancedDOM

_dom

private DOM _dom

_namesArray

private java.lang.String[] _namesArray

_urisArray

private java.lang.String[] _urisArray

_typesArray

private int[] _typesArray

_namespaceArray

private java.lang.String[] _namespaceArray

_mapping

private short[] _mapping

_reverse

private int[] _reverse

_NSmapping

private short[] _NSmapping

_NSreverse

private short[] _NSreverse

_filter

private StripFilter _filter

_multiDOMMask

private int _multiDOMMask
Constructor Detail

DOMAdapter

public DOMAdapter(DOM dom,
                  java.lang.String[] namesArray,
                  java.lang.String[] urisArray,
                  int[] typesArray,
                  java.lang.String[] namespaceArray)
Method Detail

setupMapping

public void setupMapping(java.lang.String[] names,
                         java.lang.String[] urisArray,
                         int[] typesArray,
                         java.lang.String[] namespaces)
Specified by:
setupMapping in interface DOM

getNamesArray

public java.lang.String[] getNamesArray()

getUrisArray

public java.lang.String[] getUrisArray()

getTypesArray

public int[] getTypesArray()

getNamespaceArray

public java.lang.String[] getNamespaceArray()

getDOMImpl

public DOM getDOMImpl()

getMapping

private short[] getMapping()

getReverse

private int[] getReverse()

getNSMapping

private short[] getNSMapping()

getNSReverse

private short[] getNSReverse()

getIterator

public DTMAxisIterator getIterator()
Returns singleton iterator containg the document root

Specified by:
getIterator in interface DOM

getStringValue

public java.lang.String getStringValue()
Specified by:
getStringValue in interface DOM

getChildren

public DTMAxisIterator getChildren(int node)
Specified by:
getChildren in interface DOM

setFilter

public void setFilter(StripFilter filter)
Specified by:
setFilter in interface DOM

getTypedChildren

public DTMAxisIterator getTypedChildren(int type)
Specified by:
getTypedChildren in interface DOM

getNamespaceAxisIterator

public DTMAxisIterator getNamespaceAxisIterator(int axis,
                                                int ns)
Specified by:
getNamespaceAxisIterator in interface DOM

getAxisIterator

public DTMAxisIterator getAxisIterator(int axis)
Specified by:
getAxisIterator in interface DOM

getTypedAxisIterator

public DTMAxisIterator getTypedAxisIterator(int axis,
                                            int type)
Specified by:
getTypedAxisIterator in interface DOM

getMultiDOMMask

public int getMultiDOMMask()

setMultiDOMMask

public void setMultiDOMMask(int mask)

getNthDescendant

public DTMAxisIterator getNthDescendant(int type,
                                        int n,
                                        boolean includeself)
Specified by:
getNthDescendant in interface DOM

getNodeValueIterator

public DTMAxisIterator getNodeValueIterator(DTMAxisIterator iterator,
                                            int type,
                                            java.lang.String value,
                                            boolean op)
Specified by:
getNodeValueIterator in interface DOM

orderNodes

public DTMAxisIterator orderNodes(DTMAxisIterator source,
                                  int node)
Specified by:
orderNodes in interface DOM

getExpandedTypeID

public int getExpandedTypeID(int node)
Specified by:
getExpandedTypeID in interface DOM

getNamespaceType

public int getNamespaceType(int node)
Specified by:
getNamespaceType in interface DOM

getNSType

public int getNSType(int node)
Specified by:
getNSType in interface DOM

getParent

public int getParent(int node)
Specified by:
getParent in interface DOM

getAttributeNode

public int getAttributeNode(int type,
                            int element)
Specified by:
getAttributeNode in interface DOM

getNodeName

public java.lang.String getNodeName(int node)
Specified by:
getNodeName in interface DOM

getNodeNameX

public java.lang.String getNodeNameX(int node)
Specified by:
getNodeNameX in interface DOM

getNamespaceName

public java.lang.String getNamespaceName(int node)
Specified by:
getNamespaceName in interface DOM

getStringValueX

public java.lang.String getStringValueX(int node)
Specified by:
getStringValueX in interface DOM

copy

public void copy(int node,
                 SerializationHandler handler)
          throws TransletException
Specified by:
copy in interface DOM
Throws:
TransletException

copy

public void copy(DTMAxisIterator nodes,
                 SerializationHandler handler)
          throws TransletException
Specified by:
copy in interface DOM
Throws:
TransletException

shallowCopy

public java.lang.String shallowCopy(int node,
                                    SerializationHandler handler)
                             throws TransletException
Specified by:
shallowCopy in interface DOM
Throws:
TransletException

lessThan

public boolean lessThan(int node1,
                        int node2)
Specified by:
lessThan in interface DOM

characters

public void characters(int textNode,
                       SerializationHandler handler)
                throws TransletException
Specified by:
characters in interface DOM
Throws:
TransletException

makeNode

public org.w3c.dom.Node makeNode(int index)
Specified by:
makeNode in interface DOM

makeNode

public org.w3c.dom.Node makeNode(DTMAxisIterator iter)
Specified by:
makeNode in interface DOM

makeNodeList

public org.w3c.dom.NodeList makeNodeList(int index)
Specified by:
makeNodeList in interface DOM

makeNodeList

public org.w3c.dom.NodeList makeNodeList(DTMAxisIterator iter)
Specified by:
makeNodeList in interface DOM

getLanguage

public java.lang.String getLanguage(int node)
Specified by:
getLanguage in interface DOM

getSize

public int getSize()
Specified by:
getSize in interface DOM

setDocumentURI

public void setDocumentURI(java.lang.String uri)

getDocumentURI

public java.lang.String getDocumentURI()

getDocumentURI

public java.lang.String getDocumentURI(int node)
Specified by:
getDocumentURI in interface DOM

getDocument

public int getDocument()
Specified by:
getDocument in interface DOM

isElement

public boolean isElement(int node)
Specified by:
isElement in interface DOM

isAttribute

public boolean isAttribute(int node)
Specified by:
isAttribute in interface DOM

getNodeIdent

public int getNodeIdent(int nodeHandle)
Specified by:
getNodeIdent in interface DOM

getNodeHandle

public int getNodeHandle(int nodeId)
Specified by:
getNodeHandle in interface DOM

getResultTreeFrag

public DOM getResultTreeFrag(int initSize,
                             int rtfType)
Return a instance of a DOM class to be used as an RTF

Specified by:
getResultTreeFrag in interface DOM

getResultTreeFrag

public DOM getResultTreeFrag(int initSize,
                             int rtfType,
                             boolean addToManager)
Return a instance of a DOM class to be used as an RTF

Specified by:
getResultTreeFrag in interface DOM

getOutputDomBuilder

public SerializationHandler getOutputDomBuilder()
Returns a SerializationHandler class wrapped in a SAX adapter.

Specified by:
getOutputDomBuilder in interface DOM

lookupNamespace

public java.lang.String lookupNamespace(int node,
                                        java.lang.String prefix)
                                 throws TransletException
Specified by:
lookupNamespace in interface DOM
Throws:
TransletException

getUnparsedEntityURI

public java.lang.String getUnparsedEntityURI(java.lang.String entity)
Specified by:
getUnparsedEntityURI in interface DOM

getElementsWithIDs

public Hashtable getElementsWithIDs()
Specified by:
getElementsWithIDs in interface DOM