com.openharbor.beck.unmarshal
Class JavaBeanUnmarshaller

java.lang.Object
  extended bycom.openharbor.beck.unmarshal.DefaultUnmarshaller
      extended bycom.openharbor.beck.unmarshal.JavaBeanUnmarshaller
All Implemented Interfaces:
MapFromXML.Aware, Unmarshaller
Direct Known Subclasses:
ContractionUnmarshaller, XsiTypeUnmarshaller

public class JavaBeanUnmarshaller
extends DefaultUnmarshaller

Maps to a JavaBean, with properties mapped from attributes and contained elements.


Field Summary
protected static java.lang.Class[] STRING_PARAMETER
           
 
Fields inherited from class com.openharbor.beck.unmarshal.DefaultUnmarshaller
data, documentState, log
 
Constructor Summary
JavaBeanUnmarshaller()
           
 
Method Summary
 void addChild(Unmarshaller child)
          Create a reference from this object to the given child object.
 java.lang.Class getChildClass(XMLThing source)
          Choose the class of the object to be mapped from a contained XML attribute or element.
protected  Setter getSetter(XMLThing childSource, Unmarshaller child)
           
protected  void setValue(java.lang.StringBuffer data)
          Convert the text and store the resulting data into the object.
 void startElement(Unmarshaller parent, XMLThing source)
           
 
Methods inherited from class com.openharbor.beck.unmarshal.DefaultUnmarshaller
addToParent, addValue, afterEndObject, disengage, disengaged, endElement, endObject, engage, getMap, getMapFromXML, getObject, getObjectClass, getParent, getSource, getSourceXPath, getXMLContext, getXName, getXPath, isEngaged, newObject, processAttributes, referToThis, reset, rethrow, setMapFromXML, setObject, setObjectClass, setParentAndSource, setXMLContext, startObject, toString, trim
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STRING_PARAMETER

protected static final java.lang.Class[] STRING_PARAMETER
Constructor Detail

JavaBeanUnmarshaller

public JavaBeanUnmarshaller()
Method Detail

startElement

public void startElement(Unmarshaller parent,
                         XMLThing source)
                  throws java.lang.Exception
Overrides:
startElement in class DefaultUnmarshaller
Throws:
java.lang.Exception

getChildClass

public java.lang.Class getChildClass(XMLThing source)
                              throws java.lang.Exception
Description copied from interface: Unmarshaller
Choose the class of the object to be mapped from a contained XML attribute or element.

Specified by:
getChildClass in interface Unmarshaller
Overrides:
getChildClass in class DefaultUnmarshaller
Throws:
java.lang.Exception

addChild

public void addChild(Unmarshaller child)
              throws java.lang.Exception
Description copied from interface: Unmarshaller
Create a reference from this object to the given child object. For example, set a reference-valued JavaBean property, or add a member to a Collection.

Specified by:
addChild in interface Unmarshaller
Overrides:
addChild in class DefaultUnmarshaller
Throws:
java.lang.Exception

getSetter

protected Setter getSetter(XMLThing childSource,
                           Unmarshaller child)
                    throws java.lang.Exception
Throws:
java.lang.Exception

setValue

protected void setValue(java.lang.StringBuffer data)
                 throws java.lang.Exception
Description copied from class: DefaultUnmarshaller
Convert the text and store the resulting data into the object.

Overrides:
setValue in class DefaultUnmarshaller
Throws:
java.lang.Exception