public interface DataFormat extends Service
| Modifier and Type | Method and Description |
|---|---|
void |
marshal(Exchange exchange,
Object graph,
OutputStream stream)
Marshals the object to the given Stream.
|
Object |
unmarshal(Exchange exchange,
InputStream stream)
Unmarshals the given stream into an object.
|
void marshal(Exchange exchange, Object graph, OutputStream stream) throws Exception
exchange - the current exchangegraph - the object to be marshalledstream - the output stream to write the marshalled result toException - can be thrownObject unmarshal(Exchange exchange, InputStream stream) throws Exception
Message object as well which will be used as the OUT message of exchange.exchange - the current exchangestream - the input stream with the object to be unmarshalledException - can be thrownApache Camel