org.apache.camel.converter.stream
Class StreamCacheConverter

java.lang.Object
  extended by org.apache.camel.converter.stream.StreamCacheConverter

@Converter
public class StreamCacheConverter
extends Object

A set of Converter methods for wrapping stream-based messages in a StreamCache implementation to ensure message re-readability (eg multicasting, retrying)


Constructor Summary
StreamCacheConverter()
           
 
Method Summary
 byte[] convertToByteArray(StreamCache cache, Exchange exchange)
           
 Serializable convertToSerializable(StreamCache cache, Exchange exchange)
           
 StreamCache convertToStreamCache(BytesSource source)
           
 StreamCache convertToStreamCache(InputStream stream, Exchange exchange)
           
 StreamCache convertToStreamCache(Reader reader, Exchange exchange)
           
 StreamCache convertToStreamCache(SAXSource source, Exchange exchange)
           
 StreamCache convertToStreamCache(StreamSource source, Exchange exchange)
           
 StreamCache convertToStreamCache(StringSource source)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreamCacheConverter

public StreamCacheConverter()
Method Detail

convertToStreamCache

@Converter
public StreamCache convertToStreamCache(StreamSource source,
                                                  Exchange exchange)
                                 throws IOException
Throws:
IOException

convertToStreamCache

@Converter
public StreamCache convertToStreamCache(StringSource source)

convertToStreamCache

@Converter
public StreamCache convertToStreamCache(BytesSource source)

convertToStreamCache

@Converter
public StreamCache convertToStreamCache(SAXSource source,
                                                  Exchange exchange)
                                 throws TransformerException
Throws:
TransformerException

convertToStreamCache

@Converter
public StreamCache convertToStreamCache(InputStream stream,
                                                  Exchange exchange)
                                 throws IOException
Throws:
IOException

convertToStreamCache

@Converter
public StreamCache convertToStreamCache(Reader reader,
                                                  Exchange exchange)
                                 throws IOException
Throws:
IOException

convertToSerializable

@Converter
public Serializable convertToSerializable(StreamCache cache,
                                                    Exchange exchange)
                                   throws IOException
Throws:
IOException

convertToByteArray

@Converter
public byte[] convertToByteArray(StreamCache cache,
                                           Exchange exchange)
                          throws IOException
Throws:
IOException


Apache CAMEL