public class DbInputStream
extends org.apache.commons.io.input.AutoCloseInputStream
This class does not support mark/reset. It is always to be wrapped using a BufferedInputStream.
Modifier and Type | Field and Description |
---|---|
protected boolean |
endOfStream |
protected DataIdentifier |
identifier |
protected ResultSet |
rs |
protected DbDataStore |
store |
in
Modifier | Constructor and Description |
---|---|
protected |
DbInputStream(DbDataStore store,
DataIdentifier identifier)
Create a database input stream for the given identifier.
|
Modifier and Type | Method and Description |
---|---|
int |
available() |
void |
close()
When the stream is consumed, the database objects held by the instance are closed.
|
void |
mark(int readlimit)
This method does nothing.
|
boolean |
markSupported()
Check whether mark and reset are supported.
|
protected void |
openStream()
Open the stream if required.
|
int |
read()
When the stream is consumed, the database objects held by the instance are closed.
|
int |
read(byte[] b)
When the stream is consumed, the database objects held by the instance are closed.
|
int |
read(byte[] b,
int off,
int len)
When the stream is consumed, the database objects held by the instance are closed.
|
void |
reset()
This method does nothing.
|
long |
skip(long n) |
afterRead, builder, finalize
protected DbDataStore store
protected DataIdentifier identifier
protected boolean endOfStream
protected ResultSet rs
protected DbInputStream(DbDataStore store, DataIdentifier identifier)
store
- the database data storeidentifier
- the data identifierprotected void openStream() throws IOException
IOException
public int read() throws IOException
read
in class org.apache.commons.io.input.ProxyInputStream
IOException
public int read(byte[] b) throws IOException
read
in class org.apache.commons.io.input.ProxyInputStream
IOException
public int read(byte[] b, int off, int len) throws IOException
read
in class org.apache.commons.io.input.ProxyInputStream
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class org.apache.commons.io.input.AutoCloseInputStream
IOException
public long skip(long n) throws IOException
skip
in class org.apache.commons.io.input.ProxyInputStream
IOException
public int available() throws IOException
available
in class org.apache.commons.io.input.ProxyInputStream
IOException
public void mark(int readlimit)
mark
in class org.apache.commons.io.input.ProxyInputStream
public void reset() throws IOException
reset
in class org.apache.commons.io.input.ProxyInputStream
IOException
public boolean markSupported()
markSupported
in class org.apache.commons.io.input.ProxyInputStream
Copyright © 2004–2024 The Apache Software Foundation. All rights reserved.