|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.ojb.broker.metadata.fieldaccess.PersistentFieldBase
org.apache.ojb.broker.metadata.fieldaccess.PersistentFieldDynaBeanImpl
public class PersistentFieldDynaBeanImpl
A PersistentField implementation accesses a property
from a DynaBean.
Note that because of the way that PersistentField works,
at run time the type of the field could actually be different, since
it depends on the DynaClass of the DynaBean that is given at runtime.
This implementation does not support nested fields.
| Field Summary |
|---|
| Fields inherited from class org.apache.ojb.broker.metadata.fieldaccess.PersistentFieldBase |
|---|
PATH_TOKEN, rootObjectType |
| Constructor Summary | |
|---|---|
PersistentFieldDynaBeanImpl()
|
|
PersistentFieldDynaBeanImpl(Class aPropertyType,
String aPropertyName)
|
|
| Method Summary | |
|---|---|
Object |
get(Object anObject)
Returns the value of the field represented by this PersistentField, on the specified object. |
Class |
getType()
|
protected void |
logGetProblem(Object anObject,
String msg)
Let's give the user some hints as to what could be wrong. |
protected void |
logSetProblem(Object anObject,
Object aValue,
String msg)
Let's give the user some hints as to what could be wrong. |
protected boolean |
makeAccessible()
A value of true indicates that this field should suppress Java language access checking when it is used. |
void |
set(Object anObject,
Object aValue)
Sets the field represented by this PersistentField object on the specified object argument to the specified new value. |
boolean |
usesAccessorsAndMutators()
|
| Methods inherited from class org.apache.ojb.broker.metadata.fieldaccess.PersistentFieldBase |
|---|
buildErrorGetMsg, buildErrorSetMsg, getDeclaringClass, getFieldGraph, getLog, getName, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public PersistentFieldDynaBeanImpl()
public PersistentFieldDynaBeanImpl(Class aPropertyType,
String aPropertyName)
| Method Detail |
|---|
public void set(Object anObject,
Object aValue)
throws MetadataException
PersistentField
anObject - The target object (no proxy objects allowed).aValue - The value to set.
MetadataException - if there is an error setting this field value on objField
public Object get(Object anObject)
throws MetadataException
PersistentField
anObject - - The object instance (proxy objects are not allowed here) which we are
trying to get the field value from.
MetadataException - if there is an error getting this field value from objFieldpublic Class getType()
protected boolean makeAccessible()
PersistentFieldBase
makeAccessible in class PersistentFieldBasepublic boolean usesAccessorsAndMutators()
protected void logSetProblem(Object anObject,
Object aValue,
String msg)
protected void logGetProblem(Object anObject,
String msg)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||