|
Open SiteSearch 4.1.1 Final |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.util.AbstractCollection | +--java.util.AbstractList | +--java.util.Vector | +--ORG.oclc.jassi.DataPairs
The DataPairs class defines a vector where DataPair objects will be stored.
DataPair
,
Action
,
RequestManager
,
Verb
, Serialized FormFields inherited from class java.util.Vector |
capacityIncrement,
elementCount,
elementData |
Fields inherited from class java.util.AbstractList |
modCount |
Constructor Summary | |
DataPairs()
Constructs a DataPairs object vector of initial size 10. |
|
DataPairs(int initialCapacity)
Constructs a DataPairs object vector of initial size as specified in the input parameter. |
|
DataPairs(int initialCapacity,
int capacityIncrement)
Constructs a DataPairs object vector of initial size and incremental size as specified in the input parameters. |
Method Summary | |
void |
addElement(String name,
String value)
Adds the input name/value Strings to the end of this DataPairs vector as a DataPair object. |
boolean |
contains(String elem)
Tests if the specified input DataPair name is contained in this vector. |
String |
get(String elem)
Searches for the input DataPair name and returns the DataPair String value. |
String |
get(String elem,
String def)
Searches for the input DataPair name and returns the DataPair String value or the input parameter default String value. |
String |
getall(String elem)
Deprecated. Incorrectly named. |
String |
getAll(String elem)
Searches the vector for ALL occurrences of the input DataPair name and builds a space separated String of all the DataPair object values. |
Vector |
getAllStartsWithVector(String elem)
Searches the vector for ALL occurrences that start with the input DataPair name and returns the values in a vector. |
Vector |
getAllVector(String elem)
Searches the vector for ALL occurrences of the input DataPair name and returns the values in a vector. |
int |
getInt(String elem,
int def)
Searches for the input DataPair name and returns the DataPair integer value or a default integer value if not found. |
String |
getKey(String value)
Searches for the input DataPair value and returns the DataPair String name. |
int |
indexOf(String elem)
Searches for the first occurrence of the input DataPair name and tests for equality using the String equals method. |
int |
indexOf(String elem,
int index)
Searches for the first occurrence of the input DataPair name, beginning the search at the input index value, and testing
for equality using the String equals method. |
void |
insertElementAt(String name,
String value,
int index)
Inserts a new DataPair object at the specified index
using the input DataPair name and value parameters. |
int |
lastIndexOf(String elem)
Searches backwards for the input DataPair name by starting from the end of the vector. |
int |
lastIndexOf(String elem,
int index)
Searches backwards for the input DataPair name by starting from the input index value within the vector. |
void |
remove(String elem)
Removes the first occurrence of the DataPair object matching the input DataPair name. |
void |
removeall(String elem)
Deprecated. Incorrectly named. |
void |
removeAll(String elem)
Removes all occurrences of the DataPair object matching the input DataPair name. |
void |
replaceElement(String name,
String value)
Replaces the DataPair value of the first occurrence of the DataPair object with the input DataPair name. |
void |
setElementAt(String name,
String value,
int index)
Sets the DataPair object at the specified index of this
vector to be the input DataPair name and value parameters. |
String |
toString(String separator)
Returns the String representation of this object. |
String |
toString(String separator,
String lineSeparator)
Returns the String representation of this object. |
String |
toString(String separator,
String lineSeparator,
boolean encode)
Returns the String representation of this object. |
Methods inherited from class java.util.Vector |
add,
add,
addAll,
addAll,
addElement,
capacity,
clear,
clone,
contains,
containsAll,
copyInto,
elementAt,
elements,
ensureCapacity,
equals,
firstElement,
get,
hashCode,
indexOf,
indexOf,
insertElementAt,
isEmpty,
lastElement,
lastIndexOf,
lastIndexOf,
remove,
remove,
removeAll,
removeAllElements,
removeElement,
removeElementAt,
removeRange,
retainAll,
set,
setElementAt,
setSize,
size,
subList,
toArray,
toArray,
toString,
trimToSize |
Methods inherited from class java.util.AbstractList |
iterator,
listIterator,
listIterator |
Methods inherited from class java.lang.Object |
finalize,
getClass,
notify,
notifyAll,
wait,
wait,
wait |
Constructor Detail |
public DataPairs()
public DataPairs(int initialCapacity)
initialCapacity
- the initial size of the DataPairs vector.public DataPairs(int initialCapacity, int capacityIncrement)
initialCapacity
- the initial size of the DataPairs vector.capacityIncrement
- the increment size when increasing
the current capacity of the DataPairs vector.Method Detail |
public final boolean contains(String elem)
elem
- the name of the DataPair object.true
if the DataPair object is a component in
this vector; false
otherwise.public final void addElement(String name, String value)
name
- the name of the DataPair object.value
- the value of the DataPair object.public final int indexOf(String elem)
String equals
method.elem
- the name of the DataPair object.index
or later in the
vector; returns -1
if the DataPair object
is not found.public final int indexOf(String elem, int index)
index
value, and testing
for equality using the String equals
method.elem
- the name of the DataPair object.index
- the index in the vector to start the search.index
or later in the
vector; returns -1
if the DataPair object
is not found.public final int lastIndexOf(String elem)
elem
- the name of the DataPair object.-1
if the DataPair object is not found.public final int lastIndexOf(String elem, int index)
elem
- the name of the DataPair object.index
- the index in the vector to start the search.index
in the vector;
-1
if the DataPair object is not found.public final String getKey(String value)
value
- the value of the DataPair object.null
if a DataPair object is not found.public final String get(String elem)
elem
- the name of the DataPair object.null
if a DataPair object is not found.public final String get(String elem, String def)
elem
- the name of the DataPair object.def
- the default String value.public final int getInt(String elem, int def)
elem
- the name of the DataPair object.def
- the default integer value.public final String getall(String elem)
elem
- the name of the DataPair object.null
if the DataPair object(s) is not found.getAll
public final String getAll(String elem)
elem
- the name of the DataPair object.null
if the DataPair object(s) is not found.public final Vector getAllVector(String elem)
elem
- the name of the DataPair object.null
if the DataPair object(s) is not found.public final Vector getAllStartsWithVector(String elem)
elem
- the stem name of the DataPair object.null
if the DataPair object(s) is not found.public final void replaceElement(String name, String value)
name
- the name of the DataPair object.value
- the new value for the DataPair object.public final void setElementAt(String name, String value, int index)
index
of this
vector to be the input DataPair name and value parameters.
The previous DataPair object at that position is discarded.
The index must be a value greater than or equal to 0
and less than the current size of the vector.
name
- the new name of the DataPair object.value
- the new value for the DataPair object.index
- the index of the DataPair object to replace.public final void insertElementAt(String name, String value, int index)
index
using the input DataPair name and value parameters.
Each DataPair object in this vector with
an index greater or equal to the specified index
is
shifted upward to have an index one greater than the value it had
previously.
The index must be a value greater than or equal to 0
and less than or equal to the current size of the vector.
name
- the new name of the DataPair object.value
- the new value for the DataPair object.index
- the index of the DataPair object to insert.public final void remove(String elem)
elem
- the name of the DataPair object.public final void removeAll(String elem)
elem
- the name of the DataPair object.public final void removeall(String elem)
elem
- the name of the DataPair object.removeAll
public final String toString(String separator, String lineSeparator, boolean encode)
separator
- the string to separate DataPair Name and Value with.lineSeparator
- the string to separate each DataPair in the vector
with.public final String toString(String separator)
public final String toString(String separator, String lineSeparator)
|
Open SiteSearch 4.1.1 Final |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |