org.apache.camel.converter.jaxb
Class JaxbDataFormat
java.lang.Object
org.apache.camel.converter.jaxb.JaxbDataFormat
- All Implemented Interfaces:
- DataFormat
public class JaxbDataFormat
- extends Object
- implements DataFormat
A data format (DataFormat)
using JAXB2 to marshal to and from XML
- Version:
- $Revision: 901192 $
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JaxbDataFormat
public JaxbDataFormat()
JaxbDataFormat
public JaxbDataFormat(JAXBContext context)
JaxbDataFormat
public JaxbDataFormat(String contextPath)
marshal
public void marshal(Exchange exchange,
Object graph,
OutputStream stream)
throws IOException
- Specified by:
marshal in interface DataFormat
- Throws:
IOException
unmarshal
public Object unmarshal(Exchange exchange,
InputStream stream)
throws IOException
- Specified by:
unmarshal in interface DataFormat
- Throws:
IOException
needFiltering
protected boolean needFiltering(Exchange exchange)
isIgnoreJAXBElement
public boolean isIgnoreJAXBElement()
setIgnoreJAXBElement
public void setIgnoreJAXBElement(boolean flag)
getContext
public JAXBContext getContext()
throws JAXBException
- Throws:
JAXBException
setContext
public void setContext(JAXBContext context)
getContextPath
public String getContextPath()
setContextPath
public void setContextPath(String contextPath)
isPrettyPrint
public boolean isPrettyPrint()
setPrettyPrint
public void setPrettyPrint(boolean prettyPrint)
isFilterNonXmlChars
public boolean isFilterNonXmlChars()
setFilterNonXmlChars
public void setFilterNonXmlChars(boolean filterNonXmlChars)
getEncoding
public String getEncoding()
setEncoding
public void setEncoding(String encoding)
getPartNamespace
public final QName getPartNamespace()
setPartNamespace
public final void setPartNamespace(QName partNamespace)
getPartClass
public final String getPartClass()
setPartClass
public final void setPartClass(String partClass)
createContext
protected JAXBContext createContext()
throws JAXBException
- Throws:
JAXBException
Copyright © 2007-2010 The Apache Software Foundation. All Rights Reserved.