Package com.ibatis.common.beans
Class DomProbe
java.lang.Object
com.ibatis.common.beans.BaseProbe
com.ibatis.common.beans.DomProbe
- All Implemented Interfaces:
Probe
A Probe implementation for working with DOM objects.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets an Object property from another object.protected ObjectgetProperty(Object object, String property) Gets the property.getPropertyTypeForGetter(Object object, String name) Returns the class that the getter will return when reading a property.getPropertyTypeForSetter(Object object, String name) Returns the class that the setter expects when setting a property.String[]getReadablePropertyNames(Object object) Returns an array of the readable properties exposed by an object.String[]getWriteablePropertyNames(Object object) Returns an array of the writeable properties exposed by an object.booleanhasReadableProperty(Object object, String propertyName) Checks to see if an object has a readable property by a given name.booleanhasWritableProperty(Object object, String propertyName) Checks to see if an object has a writable property by a given name.static StringnodeToString(Node node, String indent) Converts a DOM node to a complete xml string.voidSets the value of a property on an object.protected voidsetProperty(Object object, String property, Object value) Sets the property.Methods inherited from class com.ibatis.common.beans.BaseProbe
getIndexedProperty, getIndexedType, setIndexedProperty
-
Constructor Details
-
DomProbe
public DomProbe()
-
-
Method Details
-
getReadablePropertyNames
Description copied from class:BaseProbeReturns an array of the readable properties exposed by an object.- Specified by:
getReadablePropertyNamesin classBaseProbe- Parameters:
object- - the object- Returns:
- The array of property names
-
getWriteablePropertyNames
Description copied from class:BaseProbeReturns an array of the writeable properties exposed by an object.- Specified by:
getWriteablePropertyNamesin classBaseProbe- Parameters:
object- - the object- Returns:
- The array of property names
-
getPropertyTypeForSetter
Description copied from interface:ProbeReturns the class that the setter expects when setting a property.- Parameters:
object- - the object to checkname- - the name of the property- Returns:
- The type of the property
-
getPropertyTypeForGetter
Description copied from interface:ProbeReturns the class that the getter will return when reading a property.- Parameters:
object- - the object to checkname- - the name of the property- Returns:
- The type of the property
-
hasWritableProperty
Description copied from interface:ProbeChecks to see if an object has a writable property by a given name.- Parameters:
object- - the object to checkpropertyName- - the property to check for- Returns:
- True if the property exists and is writable
-
hasReadableProperty
Description copied from interface:ProbeChecks to see if an object has a readable property by a given name.- Parameters:
object- - the object to checkpropertyName- - the property to check for- Returns:
- True if the property exists and is readable
-
getObject
Description copied from interface:ProbeGets an Object property from another object.- Parameters:
object- - the objectname- - the property name- Returns:
- The property value (as an Object)
-
setObject
Description copied from interface:ProbeSets the value of a property on an object.- Parameters:
object- - the object to changename- - the name of the property to setvalue- - the new value to set
-
setProperty
Description copied from class:BaseProbeSets the property.- Specified by:
setPropertyin classBaseProbe- Parameters:
object- the objectproperty- the propertyvalue- the value
-
getProperty
Description copied from class:BaseProbeGets the property.- Specified by:
getPropertyin classBaseProbe- Parameters:
object- the objectproperty- the property- Returns:
- the property
-
nodeToString
Converts a DOM node to a complete xml string.- Parameters:
node- - the node to processindent- - how to indent the children of the node- Returns:
- The node as a String
-