|
Data Request Broker 2-3-release |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfr.gael.drb.value.AbstractValueArray
public abstract class AbstractValueArray
Generic array value wrapper.
| Field Summary |
|---|
| Fields inherited from interface fr.gael.drb.value.Value |
|---|
ARRAY_ID, BINARY_ID, BINARY_INTEGER_ID, BOOLEAN_ID, BYTE_ID, DATE_ID, DATE_TIME_ID, DAY_ID, DAY_TIME_DURATION_ID, DECIMAL_ID, DOUBLE_ID, DURATION_ID, FLOAT_ID, INT_ID, INTEGER_ID, LONG_ID, MONTH_DAY_ID, MONTH_ID, NULL_ID, NUMERIC_ID, OTHER_ID, SHORT_ID, STRING_ID, TIME_ID, UNKNOWN_ID, UNSIGNED_BYTE_ID, UNSIGNED_INT_ID, UNSIGNED_LONG_ID, UNSIGNED_SHORT_ID, YEAR_ID, YEAR_MONTH_DURATION_ID, YEAR_MONTH_ID |
| Fields inherited from interface fr.gael.drb.DrbItem |
|---|
ATTRIBUTE_ITEM, NODE_ITEM, UNDEFINED_ITEM, VALUE_ITEM |
| Constructor Summary | |
|---|---|
AbstractValueArray()
|
|
| Method Summary | |
|---|---|
DrbSequence |
addItem(int index,
DrbItem item)
Inserts a item at a given position. |
ValueArray |
atomize()
The atomic values of this sequence. |
int |
compareTo(Value value)
Compare this array with another array. |
ValueArray |
convertArrayTo(int array_type)
Convert the array values into the specified type. |
Value |
convertTo(int type)
Convert the value into the specified type. |
DrbItem |
getItem(int index)
Returns a specific item of the list. |
int |
getItemType()
A code that identifies the value items. |
int |
getLength()
The number of items in the list. |
String |
getName()
Name of the item. |
String |
getNamespaceURI()
Get namespace URI. |
int |
getType()
The type identifier of the value. |
Value |
getValue()
The value of the item. |
static void |
main(String[] args)
Main. |
DrbSequence |
removeItem(int index)
Removes an existing item. |
void |
rename(String name)
Changes the name of the item. |
void |
setNamespaceURI(String namespace_uri)
Sets a namespace resource identifier. |
Value |
setValue(Value value)
Changes the value of the item. |
Numeric |
toNumeric()
Convert the value into the numeric type. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface fr.gael.drb.value.ValueArray |
|---|
assign, getArrayType, getElement, length |
| Methods inherited from interface fr.gael.drb.value.Value |
|---|
assign, getPriority, getType |
| Methods inherited from interface fr.gael.drb.DrbItem |
|---|
getItemType, getName, getNamespaceURI, getValue, rename, setNamespaceURI, setValue |
| Constructor Detail |
|---|
public AbstractValueArray()
| Method Detail |
|---|
public Value convertTo(int type)
throws ClassCastException
convertTo in interface Valuetype - The target type.
ClassCastException - the conversion is impossible
public ValueArray convertArrayTo(int array_type)
throws ClassCastException
array_type - The target element type.
ClassCastException - if the conversion is impossible.public int compareTo(Value value)
compareTo in interface Comparisonvalue - another array.
The values are compared by increasing rank.
A specific case occurs when the two arrays have not the same size. In that case the result is negative if this array is the smallest and positive otherwise.
public DrbItem getItem(int index)
getItem in interface DrbSequenceindex - The position of the item starting from and not greater or
equal to the item count in the list.
public ValueArray atomize()
atomize in interface DrbSequencepublic int getLength()
getLength in interface DrbSequence
public DrbSequence addItem(int index,
DrbItem item)
throws NullPointerException,
UnsupportedOperationException,
IndexOutOfBoundsException
addItem in interface DrbSequenceindex - The expected index of the item after the insertion.item - A reference to the item to be inserted.
NullPointerException - This exception is raised when the passed item
a null reference. This exception may be overriden by an
UnsupportedOperationException.
IndexOutOfBoundsException - This exception is raised when the passe
index is less than zero or if it is greater or equal to the
number of item in the sequence prior the call
UnsupportedOperationException - This exception is raised when the
implementation does not support the requested insertion for any
reason (e.g. impossible in this current specific case or in
general).
public DrbSequence removeItem(int index)
throws IndexOutOfBoundsException,
UnsupportedOperationException
removeItem in interface DrbSequenceindex - Index of the item to be removed.
IndexOutOfBoundsException - This exception is raised when the passed
index is less than zero or greater or equal to the current
number of children.
UnsupportedOperationException - This exception is raised when the
implementation does not support the requested removal for any
reason.public static void main(String[] args)
public int getItemType()
getItemType in interface DrbItempublic String getName()
getName in interface DrbItem
public void rename(String name)
throws NullPointerException,
UnsupportedOperationException
rename in interface DrbItemname - Reference to the new name.
UnsupportedOperationException - This exception always raised because
the name property is not defined for values.
NullPointerException - This exception is overriden by an
UnsupportedOperationException.public String getNamespaceURI()
getNamespaceURI in interface DrbItem
public void setNamespaceURI(String namespace_uri)
throws NullPointerException,
UnsupportedOperationException
setNamespaceURI in interface DrbItemnamespace_uri - A reference to the new namespace identifier.
UnsupportedOperationException - This exception always raised because
the name property is not defined for values.
NullPointerException - This exception is overriden by an
UnsupportedOperationException.public Value getValue()
getValue in interface DrbItem
public Value setValue(Value value)
throws NullPointerException,
ClassCastException,
UnsupportedOperationException
setValue in interface DrbItemvalue - The new value of the node. This value shall not be null.
NullPointerException - This exception is raised when the passed
reference to the value is null. This exception may be overriden
by an UnsupportedOperationException.
ClassCastException - This exception is raised when the
implementation has not succeeded to cast the input value in a
type compatible with the current node.
UnsupportedOperationException - This exception is raised when the
implementation does not support the requested assignment for
any reason.public int getType()
getType in interface Value
public Numeric toNumeric()
throws ClassCastException
ClassCastException - is the convertion is impossible
|
Data Request Broker - DRB API® 2-3-release |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||