Package com.documents4j.api
Interface IInputStreamConsumer
-
public interface IInputStreamConsumerConsumes an input stream after a terminated conversion.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidonCancel()Invoked if the conversion was cancelled.voidonComplete(InputStream inputStream)Invoked if the conversion was completed successfully.voidonException(Exception e)Invoked if the conversion finished with an exception.
-
-
-
Method Detail
-
onComplete
void onComplete(InputStream inputStream)
Invoked if the conversion was completed successfully. If this callback throws an exception, the conversion will be marked as unsuccessful and the exception is rethrown on any invocation of the resulting future'sFuture.get()method.- Parameters:
inputStream- The input stream representing the converted file.
-
onCancel
void onCancel()
Invoked if the conversion was cancelled. If this callback throws an exception, the exception will be suppressed.
-
onException
void onException(Exception e)
Invoked if the conversion finished with an exception. If this callback throws an exception, the exception will be suppressed.- Parameters:
e- An exception representing the reason for the failed conversion.
-
-