org.apache.xerces.impl.xs.psvi
Interface XSNamedMap

All Known Implementing Classes:
XSNamedMapImpl

public interface XSNamedMap

Objects implementing the XSNamedMap interface are used to represent collections of objects that can be accessed by name. Objects contained in an object implementing XSNamedMap may also be accessed by an ordinal index, but this is simply to allow convenient enumeration of the contents of a XSNamedMap, and does not imply that the this API specifies an order to these XSObjects.

Version:
$Id: XSNamedMap.java,v 1.1 2002/05/13 21:31:34 sandygao Exp $
Author:
Elena Litani, IBM

Method Summary
 XSObject getItem(int index)
          Returns the indexth item in the map.
 int getMapLength()
          The number of XSObjects in the XSObjectList.
 XSObject getNSItem(java.lang.String namespace, java.lang.String localName)
          Retrieves an XSObject specified by local name and namespace URI.
 

Method Detail

getMapLength

public int getMapLength()
The number of XSObjects in the XSObjectList. The range of valid child node indices is 0 to length-1 inclusive.


getNSItem

public XSObject getNSItem(java.lang.String namespace,
                          java.lang.String localName)
Retrieves an XSObject specified by local name and namespace URI.

Parameters:
namespace - The namespace URI of the XSObject to retrieve.
localName - The local name of the XSObject to retrieve.
Returns:
A XSObject (of any type) with the specified local name and namespace URI, or null if they do not identify any XSObject in this map.

getItem

public XSObject getItem(int index)
Returns the indexth item in the map. The index starts at 0. If index is greater than or equal to the number of nodes in the list, this returns null.

Parameters:
index - The position in the map from which the item is to be retrieved.
Returns:
The XSObject at the indexth position in the XSNamedMap, or null if that is not a valid index.


Copyright © 1999-2002 Apache XML Project. All Rights Reserved.