org.springframework.integration.adapter.stream
Class ByteStreamSource

java.lang.Object
  extended by org.springframework.integration.adapter.stream.ByteStreamSource
All Implemented Interfaces:
org.springframework.integration.adapter.PollableSource<byte[]>

public class ByteStreamSource
extends java.lang.Object
implements org.springframework.integration.adapter.PollableSource<byte[]>

A pollable source for receiving bytes from an InputStream.

Author:
Mark Fisher

Constructor Summary
ByteStreamSource(java.io.InputStream stream)
           
ByteStreamSource(java.io.InputStream stream, int bufferSize)
           
 
Method Summary
 java.util.Collection<byte[]> poll(int limit)
           
 void setBytesPerMessage(int bytesPerMessage)
           
 void setShouldTruncate(boolean shouldTruncate)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ByteStreamSource

public ByteStreamSource(java.io.InputStream stream)

ByteStreamSource

public ByteStreamSource(java.io.InputStream stream,
                        int bufferSize)
Method Detail

setBytesPerMessage

public void setBytesPerMessage(int bytesPerMessage)

setShouldTruncate

public void setShouldTruncate(boolean shouldTruncate)

poll

public java.util.Collection<byte[]> poll(int limit)
Specified by:
poll in interface org.springframework.integration.adapter.PollableSource<byte[]>