|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xml.sax.helpers.DefaultHandler org.apache.axis.message.SOAPHandler org.apache.axis.encoding.DeserializerImpl org.apache.axis.encoding.ser.SimpleDeserializer
A deserializer for any simple type with a (String) constructor. Note: this class is designed so that subclasses need only override the makeValue method in order to construct objects of their own type.
Field Summary | |
protected SimpleDeserializer |
cacheStringDSer
|
protected javax.xml.namespace.QName |
cacheXMLType
|
Class |
javaType
|
javax.xml.namespace.QName |
xmlType
|
Fields inherited from class org.apache.axis.encoding.DeserializerImpl |
defaultType, id, isEnded, isHref, isNil, targets, value |
Fields inherited from class org.apache.axis.message.SOAPHandler |
myElement |
Constructor Summary | |
SimpleDeserializer(Class javaType,
javax.xml.namespace.QName xmlType)
The Deserializer is constructed with the xmlType and javaType (which could be a java primitive like int.class) |
|
SimpleDeserializer(Class javaType,
javax.xml.namespace.QName xmlType,
TypeDesc typeDesc)
|
Method Summary | |
void |
characters(char[] chars,
int start,
int end)
Append any characters received to the value. |
Object |
makeValue(String source)
Convert the string that has been accumulated into an Object. |
void |
onEndElement(String namespace,
String localName,
DeserializationContext context)
Append any characters to the value. |
SOAPHandler |
onStartChild(String namespace,
String localName,
String prefix,
Attributes attributes,
DeserializationContext context)
There should not be nested elements, so thow and exception if this occurs. |
void |
onStartElement(String namespace,
String localName,
String prefix,
Attributes attributes,
DeserializationContext context)
Set the bean properties that correspond to element attributes. |
void |
removeValueTargets()
Remove the Value Targets of the Deserializer. |
void |
reset()
Reset deserializer for re-use |
void |
setConstructor(Constructor c)
The Factory calls setConstructor. |
Methods inherited from class org.apache.axis.encoding.DeserializerImpl |
addChildDeserializer, componentsReady, endElement, getDefaultType, getMechanismType, getValue, getValue, getValueTargets, moveValueTargets, registerValueTarget, setChildValue, setDefaultType, setValue, setValue, startElement, valueComplete |
Methods inherited from class org.apache.axis.message.SOAPHandler |
makeNewElement, onEndChild |
Methods inherited from class org.xml.sax.helpers.DefaultHandler |
endDocument, endElement, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startElement, startPrefixMapping, unparsedEntityDecl, warning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public javax.xml.namespace.QName xmlType
public Class javaType
protected SimpleDeserializer cacheStringDSer
protected javax.xml.namespace.QName cacheXMLType
Constructor Detail |
public SimpleDeserializer(Class javaType, javax.xml.namespace.QName xmlType)
public SimpleDeserializer(Class javaType, javax.xml.namespace.QName xmlType, TypeDesc typeDesc)
Method Detail |
public void reset()
public void removeValueTargets()
removeValueTargets
in interface Deserializer
removeValueTargets
in class DeserializerImpl
public void setConstructor(Constructor c)
public SOAPHandler onStartChild(String namespace, String localName, String prefix, Attributes attributes, DeserializationContext context) throws SAXException
onStartChild
in interface Deserializer
onStartChild
in class DeserializerImpl
namespace
- is the namespace of the child elementlocalName
- is the local name of the child elementprefix
- is the prefix used on the name of the child elementattributes
- are the attributes of the child elementcontext
- is the deserialization context.
SAXException
public void characters(char[] chars, int start, int end) throws SAXException
SAXException
public void onEndElement(String namespace, String localName, DeserializationContext context) throws SAXException
onEndElement
in interface Deserializer
onEndElement
in class DeserializerImpl
namespace
- is the namespace of the child elementlocalName
- is the local name of the child elementcontext
- is the deserialization context
SAXException
public Object makeValue(String source) throws Exception
source
- the serialized value to be deserialized
Exception
- any exception thrown by this method will be wrappedpublic void onStartElement(String namespace, String localName, String prefix, Attributes attributes, DeserializationContext context) throws SAXException
onStartElement
in interface Deserializer
onStartElement
in class DeserializerImpl
namespace
- is the namespace of the elementlocalName
- is the name of the elementprefix
- is the prefix of the elementattributes
- are the attributes on the element...used to get the typecontext
- is the DeserializationContext
SAXException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |