.
Constructor Summary |
RMXMLMapMaker()
Creates a plain map-maker instance. |
Method Summary |
java.lang.Object |
convertFromAppServerType(java.lang.Object anObj)
This is an override hook to convert object relations to List/Map if they are otherwise (eg, WebObjects/NSArray). |
java.lang.String |
getClassName(java.lang.Object anObj)
Returns a className for an Object whether String or Class (may trim class name according to _useShortClassNames). |
RMSchema |
getSchema(java.util.Map aMap)
This code returns an RMSchema for a given object graph of Java primatives (Map, List, String, Number, Date). |
boolean |
ignore(java.lang.String aName)
Returns whether map-maker should ignore any member with the given name. |
boolean |
ignore(java.lang.String aClassName,
java.lang.String aFieldName)
Returns whether map-maker should ignore the specific class/member combination. |
void |
ignoreClass(java.lang.Class aClass)
Tells map-maker to ignore any members encountered with the given class. |
void |
ignoreClass(java.lang.String aClassName)
Tells map-maker to ignore any members encountered with the given class (by class name). |
void |
ignoreMember(java.lang.Class aClass,
java.lang.String aMemberName)
Tells map-make to ignore members for a particular class. |
void |
ignoreMember(java.lang.String aName)
Tells map-maker to ignore any members encountered with the given name. |
void |
ignoreMember(java.lang.String aClassName,
java.lang.String aMemberName)
Tells map-make to ignore members for a particular class name. |
boolean |
isVerbose()
Returns whether map maker logs calls to methods. |
java.util.Map |
makeMap(java.lang.Object anObj)
Core method to abstract anObject into Java Collections and Java core types (degree of separation is 3). |
java.util.Map |
makeMap(java.lang.Object anObj,
int degreeOfSeparation)
Core method to abstract anObject into Java Collections and Java core types with a given degree of separation. |
void |
setUseGetAndIsMethodsOnly(boolean aFlag)
Sets whether RM only explores getXXX accessor methods (as opposed to any method returning a value). |
void |
setUseShortClassNames(boolean aFlag)
Returns whether map-maker should make schema prettier by not using fully specified class names. |
void |
setVerbose(boolean aFlag)
Sets whether map maker logs calls to methods. |
boolean |
useGetAndIsMethodsOnly()
Returns whether RM only explores getXXX accessor methods (as opposed to any method returning a value). |
boolean |
useShortClassNames()
Returns whether map-maker should make schema prettier by not using fully specified class names. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RMXMLMapMaker
public RMXMLMapMaker()
- Creates a plain map-maker instance.
useGetAndIsMethodsOnly
public boolean useGetAndIsMethodsOnly()
- Returns whether RM only explores getXXX accessor methods (as opposed to any method returning a value).
setUseGetAndIsMethodsOnly
public void setUseGetAndIsMethodsOnly(boolean aFlag)
- Sets whether RM only explores getXXX accessor methods (as opposed to any method returning a value).
isVerbose
public boolean isVerbose()
- Returns whether map maker logs calls to methods.
setVerbose
public void setVerbose(boolean aFlag)
- Sets whether map maker logs calls to methods.
useShortClassNames
public boolean useShortClassNames()
- Returns whether map-maker should make schema prettier by not using fully specified class names.
setUseShortClassNames
public void setUseShortClassNames(boolean aFlag)
- Returns whether map-maker should make schema prettier by not using fully specified class names.
ignoreClass
public void ignoreClass(java.lang.Class aClass)
- Tells map-maker to ignore any members encountered with the given class.
ignoreClass
public void ignoreClass(java.lang.String aClassName)
- Tells map-maker to ignore any members encountered with the given class (by class name).
ignoreMember
public void ignoreMember(java.lang.String aName)
- Tells map-maker to ignore any members encountered with the given name.
ignoreMember
public void ignoreMember(java.lang.Class aClass,
java.lang.String aMemberName)
- Tells map-make to ignore members for a particular class.
ignoreMember
public void ignoreMember(java.lang.String aClassName,
java.lang.String aMemberName)
- Tells map-make to ignore members for a particular class name.
ignore
public boolean ignore(java.lang.String aName)
- Returns whether map-maker should ignore any member with the given name.
ignore
public boolean ignore(java.lang.String aClassName,
java.lang.String aFieldName)
- Returns whether map-maker should ignore the specific class/member combination.
convertFromAppServerType
public java.lang.Object convertFromAppServerType(java.lang.Object anObj)
- This is an override hook to convert object relations to List/Map if they are otherwise (eg, WebObjects/NSArray).
makeMap
public java.util.Map makeMap(java.lang.Object anObj)
- Core method to abstract anObject into Java Collections and Java core types (degree of separation is 3).
makeMap
public java.util.Map makeMap(java.lang.Object anObj,
int degreeOfSeparation)
- Core method to abstract anObject into Java Collections and Java core types with a given degree of separation.
getSchema
public RMSchema getSchema(java.util.Map aMap)
- This code returns an RMSchema for a given object graph of Java primatives (Map, List, String, Number, Date).
getClassName
public java.lang.String getClassName(java.lang.Object anObj)
- Returns a className for an Object whether String or Class (may trim class name according to _useShortClassNames).