More tests.

This commit is contained in:
Harald Kuhr
2012-02-01 15:57:06 +01:00
parent ed441a7d6a
commit cda19ece0d
8 changed files with 110 additions and 7 deletions
@@ -354,6 +354,10 @@ public abstract class ImageReaderBase extends ImageReader {
Thread.currentThread().interrupt();
}
catch (InvocationTargetException e) {
if (e.getCause() instanceof RuntimeException) {
throw (RuntimeException) e.getCause();
}
throw new RuntimeException(e);
}
}
@@ -57,6 +57,9 @@ public final class IIOUtil {
/**
* Creates an {@code OutputStream} adapter that writes to an underlying {@code ImageOutputStream}.
* <p/>
* Note: The adapter is buffered, and <em>MUST</em> be properly flushed/closed after use,
* otherwise data may be lost.
*
* @param pStream the stream to write to.
* @return an {@code OutputSteam} writing to {@code pStream}.