Methods Summary |
---|
public boolean | contains(short item)Checks if the unsigned short item is a
member of this list.
for (int i = 0; i < fLength; i++) {
if (fArray[i] == item)
return true;
}
return false;
|
public boolean | equals(java.lang.Object obj)
if (obj == null || !(obj instanceof ShortList)) {
return false;
}
ShortList rhs = (ShortList)obj;
if (fLength != rhs.getLength()) {
return false;
}
for (int i = 0;i < fLength; ++i) {
if (fArray[i] != rhs.item(i)) {
return false;
}
}
return true;
|
public int | getLength()The number of Objects in the list. The range of valid
child node indices is 0 to length-1 inclusive.
return fLength;
|
public short | item(int index)
if (index < 0 || index >= fLength)
throw new XSException(XSException.INDEX_SIZE_ERR, null);
return fArray[index];
|