|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.xml.dtm.ref.ExpandedNameTable
This is a default implementation of a table that manages mappings from expanded names to expandedNameIDs. %REVIEW% Note that this is not really a separate table, or a separate pool. Instead, it's an access method build on top of the existing pools, using three pieces of information: the index numbers for a node's namespaceURI, localName, and node type, which are combined to yield a composite index number. %TBD% startup sequence -- how this gets access to the appropriate string pools in the DTMDocument/stylesheet.
Nested Class Summary | |
private static class |
ExpandedNameTable.ExtendedType
Private class representing an extended type object |
Field Summary | |
static int |
ATTRIBUTE
|
static int |
CDATA_SECTION
|
static int |
COMMENT
|
static int |
DOCUMENT
|
static int |
DOCUMENT_FRAGMENT
|
static int |
DOCUMENT_TYPE
|
static int |
ELEMENT
|
static int |
ENTITY
|
static int |
ENTITY_REFERENCE
|
(package private) ExpandedNameTable.ExtendedType |
hashET
Workspace for lookup. |
private static Vector |
m_defaultExtendedTypes
|
private static Hashtable |
m_defaultHashtable
|
private Vector |
m_extendedTypes
Vector of extended types for this document |
(package private) Hashtable |
m_hashtable
|
private int |
m_nextType
Next available extended type |
static int |
NAMESPACE
|
static int |
NOTATION
|
static int |
PROCESSING_INSTRUCTION
|
static int |
TEXT
|
Constructor Summary | |
ExpandedNameTable()
Create an expanded name table that uses private string pool lookup. |
|
ExpandedNameTable(DTMStringPool locNamesPool,
DTMStringPool namespaceNames)
Constructor ExpandedNameTable |
Method Summary | |
int |
getExpandedTypeID(int type)
Given a type, return an expanded name ID.Any additional nodes that are created that have this expanded name will use this ID. |
int |
getExpandedTypeID(String namespace,
String localName,
int type)
Given an expanded name, return an ID. |
String |
getLocalName(int ExpandedNameID)
Given an expanded-name ID, return the local name part. |
int |
getLocalNameID(int ExpandedNameID)
Given an expanded-name ID, return the local name ID. |
String |
getNamespace(int ExpandedNameID)
Given an expanded-name ID, return the namespace URI part. |
int |
getNamespaceID(int ExpandedNameID)
Given an expanded-name ID, return the namespace URI ID. |
short |
getType(int ExpandedNameID)
Given an expanded-name ID, return the local name ID. |
private void |
initExtendedTypes()
Initialize the vector of extended types with the basic DOM node types. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private Vector m_extendedTypes
private int m_nextType
public static final int ELEMENT
public static final int ATTRIBUTE
public static final int TEXT
public static final int CDATA_SECTION
public static final int ENTITY_REFERENCE
public static final int ENTITY
public static final int PROCESSING_INSTRUCTION
public static final int COMMENT
public static final int DOCUMENT
public static final int DOCUMENT_TYPE
public static final int DOCUMENT_FRAGMENT
public static final int NOTATION
public static final int NAMESPACE
Hashtable m_hashtable
ExpandedNameTable.ExtendedType hashET
private static Hashtable m_defaultHashtable
private static Vector m_defaultExtendedTypes
Constructor Detail |
public ExpandedNameTable()
public ExpandedNameTable(DTMStringPool locNamesPool, DTMStringPool namespaceNames)
locNamesPool
- Local element names lookup.namespaceNames
- Namespace values lookup.Method Detail |
private void initExtendedTypes()
public int getExpandedTypeID(String namespace, String localName, int type)
namespace
- localName
-
public int getExpandedTypeID(int type)
public String getLocalName(int ExpandedNameID)
ExpandedNameID
- an ID that represents an expanded-name.
public final int getLocalNameID(int ExpandedNameID)
ExpandedNameID
- an ID that represents an expanded-name.
public String getNamespace(int ExpandedNameID)
ExpandedNameID
- an ID that represents an expanded-name.
public final int getNamespaceID(int ExpandedNameID)
ExpandedNameID
- an ID that represents an expanded-name.
public final short getType(int ExpandedNameID)
ExpandedNameID
- an ID that represents an expanded-name.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |