|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectariba.util.core.ClassExtension
ariba.util.fieldvalue.FieldValue
ariba.util.fieldvalue.FieldValue_Object
ariba.util.fieldvalue.FieldValue_JavaHashtable
public class FieldValue_JavaHashtable
The JavaHashtableFieldValueClassExtension converts the behavior of java.util.Map so that using fieldValue accessors on them does not attempt to access the fields or methods of the Map itself, but will access the values stored in the Map. The fieldName in the FieldPath will be treated as a key into the receiver hashtable.
Field Summary |
---|
Fields inherited from class ariba.util.fieldvalue.FieldValue |
---|
Getter, Setter |
Fields inherited from class ariba.util.core.ClassExtension |
---|
forClass |
Constructor Summary | |
---|---|
FieldValue_JavaHashtable()
|
Method Summary | |
---|---|
FieldValueAccessor |
createAccessor(java.lang.Object receiver,
java.lang.String fieldName,
int type)
Overridden to disable. |
FieldValueAccessor |
getAccessor(java.lang.Object receiver,
java.lang.String fieldName,
int type)
Overridden to disable. |
java.lang.Object |
getFieldValuePrimitive(java.lang.Object receiver,
FieldPath fieldPath)
Uses the fieldName of the first node of fieldPath as the key to the receiver (which MUST be a java.util.Map) to get the return value from the receiver. |
java.lang.Object |
getFieldValuePrimitive(java.lang.Object receiver,
java.lang.String key)
Uses the key to access the value in the receiver (which MUST be a java.util.Map). |
boolean |
hasFieldValuePrimitive(java.lang.Object receiver,
java.lang.String key)
|
void |
setFieldValue(java.lang.Object target,
FieldPath fieldPath,
java.lang.Object value)
Recursively calls getFieldValuePrimitive() with the head of the fieldPath list up to the last fieldPath node and then calls setFieldValuePrimitive(). |
void |
setFieldValuePrimitive(java.lang.Object receiver,
FieldPath fieldPath,
java.lang.Object value)
Uses the fieldName of the first node of fieldPath as the key to the receiver (which MUST be a java.util.Map) to put the value into the receiver. |
void |
setFieldValuePrimitive(java.lang.Object receiver,
java.lang.String key,
java.lang.Object value)
Uses the key to put the value into the receiver (which MUST be a java.util.Map). |
Methods inherited from class ariba.util.fieldvalue.FieldValue_Object |
---|
getFieldValue, populateFieldInfo |
Methods inherited from class ariba.util.fieldvalue.FieldValue |
---|
get, get, getFieldValue, registerClassExtension, setFieldValue |
Methods inherited from class ariba.util.core.ClassExtension |
---|
clone, forClass, getRealClass, setForClass |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FieldValue_JavaHashtable()
Method Detail |
---|
public FieldValueAccessor createAccessor(java.lang.Object receiver, java.lang.String fieldName, int type)
createAccessor
in class FieldValue_Object
receiver
- the object for which the accessor will be createdfieldName
- the name of the field for which the accessor will be createdtype
- the type of accessor will be created (either FieldValue.Setter
or FieldValue.Getter)
public FieldValueAccessor getAccessor(java.lang.Object receiver, java.lang.String fieldName, int type)
getAccessor
in class FieldValue_Object
receiver
- the object for which the accessor will be looked upfieldName
- the name of the field for the accessortype
- the type of accessor will be created (either FieldValue.Setter
or FieldValue.Getter)
public void setFieldValue(java.lang.Object target, FieldPath fieldPath, java.lang.Object value)
setFieldValue
in class FieldValue_Object
target
- a java.util.Map into which the value will be put at keyfieldPath
- the key used to put value into receiver (a java.util.Map)value
- the value to put into the receiver (a java.util.Map)public void setFieldValuePrimitive(java.lang.Object receiver, FieldPath fieldPath, java.lang.Object value)
setFieldValuePrimitive
in class FieldValue_Object
receiver
- a java.util.Map into which the value will be put at keyfieldPath
- the key used to put value into receiver (a java.util.Map)value
- the value to put into the receiver (a java.util.Map)public java.lang.Object getFieldValuePrimitive(java.lang.Object receiver, FieldPath fieldPath)
getFieldValuePrimitive
in class FieldValue_Object
receiver
- a java.util.Map from which to get the valuefieldPath
- the key used to get the value from receiver (a java.util.Map)
public void setFieldValuePrimitive(java.lang.Object receiver, java.lang.String key, java.lang.Object value)
receiver
- a java.util.Map into which the value will be put at keykey
- the key used to put value into receiver (a java.util.Map)value
- the value to put into the receiver (a java.util.Map)public java.lang.Object getFieldValuePrimitive(java.lang.Object receiver, java.lang.String key)
receiver
- a java.util.Map from which to get the valuekey
- the key used to get the value from receiver (a java.util.Map)
public boolean hasFieldValuePrimitive(java.lang.Object receiver, java.lang.String key)
receiver
- a Map
from which to get the valuekey
- the key used to get the value from receiver
true
if receiver
has a
a value for the given key
and false
otherwise; note that receiver
may have a
null
value for the requested key
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |