|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.portal.common.value.Value
A read only interface used to retrieve data. It represents both for mono value and multi values. It must implement equals and hashCode.
The semantics :storage | mono | multi |
---|---|---|
xxx | xxx | [xxx] |
null | null | [null] |
[] | null | [] |
[null,..] | null | [null,..] |
["1",..] | "1" | ["1",..] |
Nested Class Summary | |
private static class |
Value.ValueList
|
Field Summary | |
private int |
hashCode
The cached hashCode. |
private java.util.List |
objectList
The object list representation. |
private java.util.List |
stringList
The string list representation. |
Constructor Summary | |
Value()
|
Method Summary | |
java.lang.Object |
asObject()
Return the value. |
java.lang.Object[] |
asObjectArray()
Create a new array and fill it with the values. |
java.util.List |
asObjectList()
Return an immutable list of objects. |
java.lang.String |
asString()
Return the value as a string or null if the value is null. |
java.lang.String[] |
asStringArray()
Creates a new array and fill it with the string values. |
java.util.List |
asStringList()
Return an immutable list of strings. |
java.lang.Object |
clone()
Clone this object. |
boolean |
equals(java.lang.Object obj)
|
protected abstract java.lang.Object[] |
getObjectArray()
Return the values as an array of converted object. |
int |
hashCode()
|
boolean |
isEmpty()
Return true if it contains zero value. |
abstract boolean |
isInstanceOf(java.lang.Class clazz)
|
boolean |
isMultiValued()
Return true if it contains more than one value. |
boolean |
isNull()
Return true if the value is null. |
int |
size()
Return the size. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
private transient int hashCode
private transient java.util.List objectList
private transient java.util.List stringList
Constructor Detail |
public Value()
Method Detail |
public abstract boolean isInstanceOf(java.lang.Class clazz)
public final int hashCode()
public final boolean equals(java.lang.Object obj)
public final java.lang.String toString()
public final java.lang.Object clone()
public final boolean isNull()
public final java.lang.String asString()
public final java.lang.Object asObject()
public final boolean isMultiValued()
public final boolean isEmpty()
public final int size()
public final java.lang.String[] asStringArray()
public final java.lang.Object[] asObjectArray()
public final java.util.List asStringList()
public final java.util.List asObjectList()
protected abstract java.lang.Object[] getObjectArray()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |