@DoNotMock("Implement it normally")
@GwtIncompatible
public interface ByteProcessor<T extends @Nullable Object>
A callback interface to process bytes from a stream.
 
processBytes(byte[], int, int) will be called for each chunk of data that is read, and should return
 false when you want to stop processing.
- Since:
- 1.0
- Author:
- Chris Nokleberg
- 
Method SummaryModifier and TypeMethodDescriptionReturn the result of processing all the bytes.booleanprocessBytes(byte[] buf, int off, int len) This method will be called for each chunk of bytes in an input stream.
- 
Method Details- 
processBytesThis method will be called for each chunk of bytes in an input stream. The implementation should process the bytes frombuf[off]throughbuf[off + len - 1](inclusive).- Parameters:
- buf- the byte array containing the data to process
- off- the initial offset into the array
- len- the length of data to be processed
- Returns:
- true to continue processing, false to stop
- Throws:
- IOException
 
- 
getResultT getResult()Return the result of processing all the bytes.
 
-