org.apache.xerces.impl.xs.util

Class StringListImpl

Implemented Interfaces:
org.apache.xerces.xs.StringList

public class StringListImpl
extends java.lang.Object
implements org.apache.xerces.xs.StringList

Containts a list of Object's.
Version:
$Id: StringListImpl.java 320098 2004-10-06 15:14:55Z mrglavas $
Author:
Sandy Gao, IBM

Field Summary

static org.apache.xerces.xs.StringList
EMPTY_LIST
An immutable empty list.

Constructor Summary

StringListImpl(String[] array, int length)
Construct an XSObjectList implementation
StringListImpl(Vector v)

Method Summary

boolean
contains(String item)
Checks if the GenericString item is a member of this list.
int
getLength()
The number of Objects in the list.
String
item(int index)

Field Details

EMPTY_LIST

public static final org.apache.xerces.xs.StringList EMPTY_LIST
An immutable empty list.

Constructor Details

StringListImpl

public StringListImpl(String[] array,
                      int length)
Construct an XSObjectList implementation
Parameters:
array - the data array
length - the number of elements

StringListImpl

public StringListImpl(Vector v)

Method Details

contains

public boolean contains(String item)
Checks if the GenericString item is a member of this list.
Specified by:
contains in interface org.apache.xerces.xs.StringList
Parameters:
item - GenericString whose presence in this list is to be tested.
Returns:
True if this list contains the GenericString item.

getLength

public int getLength()
The number of Objects in the list. The range of valid child node indices is 0 to length-1 inclusive.
Specified by:
getLength in interface org.apache.xerces.xs.StringList

item

public String item(int index)
Specified by:
item in interface org.apache.xerces.xs.StringList

Copyright B) 1999-2006 The Apache Software Foundation. All Rights Reserved.