Package org.apache.xerces.impl.xs.util
Class XSNamedMap4Types
java.lang.Object
java.util.AbstractMap
org.apache.xerces.impl.xs.util.XSNamedMapImpl
org.apache.xerces.impl.xs.util.XSNamedMap4Types
- All Implemented Interfaces:
Map,org.apache.xerces.xs.XSNamedMap
Contains the map between qnames and XSObject's.
INTERNAL:
- Usage of this class is not supported. It may be altered or removed at any time.
- Version:
- $Id: XSNamedMap4Types.java 726359 2008-12-14 05:04:10Z mrglavas $
- Author:
- Sandy Gao, IBM
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K, V> -
Field Summary
Fields inherited from class org.apache.xerces.impl.xs.util.XSNamedMapImpl
EMPTY_MAP -
Constructor Summary
ConstructorsConstructorDescriptionXSNamedMap4Types(String[] namespaces, SymbolHash[] maps, int num, short type) Construct an XSNamedMap implementation for a list of namespacesXSNamedMap4Types(String namespace, SymbolHash map, short type) Construct an XSNamedMap implementation for one namespace -
Method Summary
Modifier and TypeMethodDescriptionintThe number ofXSObjectsin theXSObjectList.org.apache.xerces.xs.XSObjectitem(int index) Returns theindexth item in the map.org.apache.xerces.xs.XSObjectitemByName(String namespace, String localName) Retrieves anXSObjectspecified by local name and namespace URI.Methods inherited from class org.apache.xerces.impl.xs.util.XSNamedMapImpl
containsKey, entrySet, get, sizeMethods inherited from class java.util.AbstractMap
clear, clone, containsValue, equals, hashCode, isEmpty, keySet, put, putAll, remove, toString, valuesMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
clear, compute, computeIfAbsent, computeIfPresent, containsValue, equals, forEach, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, values
-
Constructor Details
-
XSNamedMap4Types
Construct an XSNamedMap implementation for one namespace- Parameters:
namespace- the namespace to which the components belongmap- the map from local names to componentstype- the type of components
-
XSNamedMap4Types
Construct an XSNamedMap implementation for a list of namespaces- Parameters:
namespaces- the namespaces to which the components belongmaps- the maps from local names to componentsnum- the number of namespacestype- the type of components
-
-
Method Details
-
getLength
public int getLength()The number ofXSObjectsin theXSObjectList. The range of valid child node indices is 0 tolength-1inclusive.- Specified by:
getLengthin interfaceorg.apache.xerces.xs.XSNamedMap- Overrides:
getLengthin classXSNamedMapImpl
-
itemByName
Retrieves anXSObjectspecified by local name and namespace URI.- Specified by:
itemByNamein interfaceorg.apache.xerces.xs.XSNamedMap- Overrides:
itemByNamein classXSNamedMapImpl- Parameters:
namespace- The namespace URI of theXSObjectto retrieve.localName- The local name of theXSObjectto retrieve.- Returns:
- A
XSObject(of any type) with the specified local name and namespace URI, ornullif they do not identify anyXSObjectin this map.
-
item
public org.apache.xerces.xs.XSObject item(int index) Returns theindexth item in the map. The index starts at 0. Ifindexis greater than or equal to the number of nodes in the list, this returnsnull.- Specified by:
itemin interfaceorg.apache.xerces.xs.XSNamedMap- Overrides:
itemin classXSNamedMapImpl- Parameters:
index- The position in the map from which the item is to be retrieved.- Returns:
- The
XSObjectat theindexth position in theXSNamedMap, ornullif that is not a valid index.
-