org.apache.qpid.management.wsdm.muse.serializer
Class ByteArraySerializer

java.lang.Object
  extended by org.apache.qpid.management.wsdm.muse.serializer.ByteArraySerializer
All Implemented Interfaces:
org.apache.muse.core.serializer.Serializer

public class ByteArraySerializer
extends Object
implements org.apache.muse.core.serializer.Serializer

Implementation of Muse Serializer for byte array type.


Constructor Summary
ByteArraySerializer()
           
 
Method Summary
 Object fromXML(Element xml)
          Return a byte array representation of the given xml element.
 Class<?> getSerializableType()
          Returns the java type associated to this class.
 Element toXML(Object object, QName qname)
          Return an xml representation of the given byte array with the given name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ByteArraySerializer

public ByteArraySerializer()
Method Detail

fromXML

public Object fromXML(Element xml)
               throws org.apache.muse.ws.addressing.soap.SoapFault
Return a byte array representation of the given xml element.

Specified by:
fromXML in interface org.apache.muse.core.serializer.Serializer
Parameters:
xml - the element to unmarshal.
Throws:
org.apache.muse.ws.addressing.soap.SoapFault - when the unmarshalling fails.

getSerializableType

public Class<?> getSerializableType()
Returns the java type associated to this class.

Specified by:
getSerializableType in interface org.apache.muse.core.serializer.Serializer
Returns:
the java type associated to this class.

toXML

public Element toXML(Object object,
                     QName qname)
              throws org.apache.muse.ws.addressing.soap.SoapFault
Return an xml representation of the given byte array with the given name.

Specified by:
toXML in interface org.apache.muse.core.serializer.Serializer
Parameters:
object - the byte array to marshal.
qname - the qualified (xml) name of the object to use in xml representation.
Returns:
the xml representation of the byte array.
Throws:
org.apache.muse.ws.addressing.soap.SoapFault - when the marshalling fails.


Licensed to the Apache Software Foundation