|
UC Berkeley Group for User Interface Research Updated November 17, 2000 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.berkeley.guir.lib.introspect.IntrospectHandler
Callback for Java object introspection traversal.
Unfortunately, this class requires JDK1.3, because it uses the
Modifier
class to access values outside of our access scope.
This software is distributed under the Berkeley Software License.
Revisions: - GUIRLib-v1.0-1.0.0, Apr 25 2000, JH Created class - GUIRLib-v1.2-1.0.0, Jun 22 2000, JH Touched for GUIRLib release - GUIRLib-v1.3-1.0.0, Aug 11 2000, JH Touched for GUIRLib release - GUIRLib-v1.4-1.0.0, Aug 31 2000, JH Touched for GUIRLib release
Introspect.parseObject(Object, IntrospectHandler)
Fields inherited from interface edu.berkeley.guir.lib.introspect.IntrospectConstants |
CL_BOOLEAN, CL_BOOLEAN_ARR, CL_BYTE, CL_BYTE_ARR, CL_CHAR, CL_CHAR_ARR, CL_DOUBLE, CL_DOUBLE_ARR, CL_FLOAT, CL_FLOAT_ARR, CL_INT, CL_INT_ARR, CL_LONG, CL_LONG_ARR, CL_SHORT, CL_SHORT_ARR, CL_STRING, CL_STRINGBUFFER |
Constructor Summary | |
IntrospectHandler()
|
|
IntrospectHandler(IntrospectFilter newFilter)
|
Method Summary | |
boolean |
acceptField(int depth,
Field f,
Object obj)
Accept this field or not? |
IntrospectFilter |
getFilter()
Get the current filter. |
void |
onArray(int depth,
Field f,
Object arr)
|
void |
onBoolean(int depth,
Field f,
boolean val)
|
void |
onByte(int depth,
Field f,
byte val)
|
void |
onChar(int depth,
Field f,
char val)
|
void |
onDouble(int depth,
Field f,
double val)
|
void |
onException(int depth,
Field f,
Exception e)
Error in processing. |
void |
onFloat(int depth,
Field f,
float val)
|
void |
onInt(int depth,
Field f,
int val)
|
void |
onLong(int depth,
Field f,
long val)
|
void |
onNull(int depth,
Field f)
Rather than calling onObject or onArray, calls this if value is null. |
void |
onObject(int depth,
Field f,
Object obj)
|
void |
onRoot(Object obj)
Start traversal. |
void |
onShort(int depth,
Field f,
short val)
|
void |
setFilter(IntrospectFilter newFilter)
Set the current filter. |
boolean |
shouldRecurse(int depth,
Field f,
Object obj)
Should return the correct value as to whether we should recurse on this object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public IntrospectHandler()
public IntrospectHandler(IntrospectFilter newFilter)
Method Detail |
public void setFilter(IntrospectFilter newFilter)
newFilter
- is null to clear out the current filter.public IntrospectFilter getFilter()
public void onRoot(Object obj)
public void onObject(int depth, Field f, Object obj)
depth
- is the depth of the node in the tree.field
- is the Field information, and is null for the start object.obj
- is the object value, which may or may not be null.public void onArray(int depth, Field f, Object arr)
depth
- is the depth of the node in the tree.field
- is the Field information.obj
- is the array, which may or may not be null.public void onNull(int depth, Field f)
public void onBoolean(int depth, Field f, boolean val)
public void onChar(int depth, Field f, char val)
public void onByte(int depth, Field f, byte val)
public void onShort(int depth, Field f, short val)
public void onInt(int depth, Field f, int val)
public void onLong(int depth, Field f, long val)
public void onFloat(int depth, Field f, float val)
public void onDouble(int depth, Field f, double val)
public void onException(int depth, Field f, Exception e)
public boolean shouldRecurse(int depth, Field f, Object obj)
public boolean acceptField(int depth, Field f, Object obj)
|
Copyright Information | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |