org.apache.derby.iapi.services.io
Class NewByteArrayInputStream
java.lang.Object
java.io.InputStream
org.apache.derby.iapi.services.io.NewByteArrayInputStream
- public final class NewByteArrayInputStream
- extends java.io.InputStream
An InputStream that is like java.io.ByteArrayInputStream but supports
a close() call that causes all methods to throw an IOException.
Java's ByteInputStream has a close() method that does not do anything.
Fields inherited from class java.io.InputStream |
|
Methods inherited from class java.io.InputStream |
mark, markSupported, read, reset |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
data
private byte[] data
offset
private int offset
length
private int length
NewByteArrayInputStream
public NewByteArrayInputStream(byte[] data)
NewByteArrayInputStream
public NewByteArrayInputStream(byte[] data,
int offset,
int length)
read
public int read()
throws java.io.IOException
- Throws:
java.io.IOException
read
public int read(byte[] b,
int off,
int len)
throws java.io.IOException
- Throws:
java.io.IOException
skip
public long skip(long count)
throws java.io.IOException
- Throws:
java.io.IOException
available
public int available()
throws java.io.IOException
- Throws:
java.io.IOException
getData
public byte[] getData()
close
public void close()
Apache Derby V10.0 Engine Documentation - Copyright © 1997,2004 The Apache Software Foundation or its licensors, as applicable.