public class DynamicGetter
extends java.lang.Object
Getter
class in that instead of creating the chain of methods when the getter is
instantiated it will instead get the actual method from the object passed in.Constructor and Description |
---|
DynamicGetter(java.lang.String ref,
java.lang.Object obj)
Get the getter associated with the named reference.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Class |
getBaseClass() |
java.lang.Class |
getType()
Get the class of the type of object we would return from the
getValue(Object)
method. |
java.lang.Object |
getValue(java.lang.Object obj) |
public DynamicGetter(java.lang.String ref, java.lang.Object obj) throws java.lang.IllegalArgumentException, java.lang.IllegalAccessException, java.lang.reflect.InvocationTargetException
ref
- The reference for the getter.obj
- The Object to build up the getter from.java.lang.IllegalArgumentException
java.lang.IllegalAccessException
java.lang.reflect.InvocationTargetException
public java.lang.Class getBaseClass()
public java.lang.Class getType()
getValue(Object)
method.public java.lang.Object getValue(java.lang.Object obj) throws java.lang.IllegalAccessException, java.lang.reflect.InvocationTargetException
java.lang.IllegalAccessException
java.lang.reflect.InvocationTargetException