Details
-
Bug
-
Resolution: Done
-
Major
-
None
-
None
Description
in onDataAvailable I have to check:
if stream.isReady()
... read
else if stream.isFinished()
onAllDataRead() // call onAllDataRead manually because it's missed in most cases
For reference this is often running asynchronously, off the IO thread in most cases. The use case is a ReadListener implementation that writes data to an AsynchronousFileChannel.