Package com.ning.compress
Interface DataHandler
-
public interface DataHandlerInterface used byUncompressorimplementations: receives uncompressed data and processes it appropriately.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidallDataHandled()Method called after last call tohandleData(byte[], int, int), for successful operation, if and when caller is informed about end of content Note that if an exception thrown byhandleData(byte[], int, int)has caused processing to be aborted, this method might not get called.booleanhandleData(byte[] buffer, int offset, int len)Method called with uncompressed data as it becomes available.
-
-
-
Method Detail
-
handleData
boolean handleData(byte[] buffer, int offset, int len) throws java.io.IOExceptionMethod called with uncompressed data as it becomes available.NOTE: return value was added (from void to boolean) in 0.9.9
- Returns:
- True, if caller should process and feed more data; false if
caller is not interested in more data and processing should be terminated
(and
allDataHandled()should be called immediately) - Throws:
java.io.IOException
-
allDataHandled
void allDataHandled() throws java.io.IOExceptionMethod called after last call tohandleData(byte[], int, int), for successful operation, if and when caller is informed about end of content Note that if an exception thrown byhandleData(byte[], int, int)has caused processing to be aborted, this method might not get called. Implementation may choose to free resources, flush state, or perform validation at this point.- Throws:
java.io.IOException
-
-