public interface OracleBfile
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close a previously opened external LOB.
|
void |
closeFile()
Close the FILE.
|
boolean |
fileExists()
Find out if a given BFILE (whose locator) points to a file that actually exists on the server's filesystem.
|
InputStream |
getBinaryStream()
Retrieve the entire BFILE as a stream.
|
InputStream |
getBinaryStream(long pos)
Read from the external LOB as a stream at the requested position.
|
byte[] |
getBytes(long pos, int length)
Return a copy of the contents of the BFILE at the requested position.
|
int |
getBytes(long pos, int length, byte[] buf)
Copy the contents of the BFILE at the requested position to suppied buffer.
|
String |
getDirAlias()
Gets the Bfile's directory alias.
|
String |
getName()
Gets the Bfile's file name.
|
boolean |
isFileOpen()
Find out whether a BFILE was opened
|
boolean |
isOpen()
Check whether the external LOB is opened.
|
long |
length()
The length of the BFILE in bytes.
|
void |
open(LargeObjectAccessMode mode)
Open a external LOB in the indicated mode.
|
void |
openFile()
Open the FILE.
|
long |
position(byte[] pattern, long start)
Determine the byte position at which the given byte pattern
|
long |
position(OracleBfile pattern, long start)
Determine the byte position at which the given pattern
|
long length()
throws SQLException
SQLExceptionbyte[] getBytes(long pos,
int length)
throws SQLException
pos - is the first byte of the bfile to be extracted.(1-based)length - is the number of consecutive bytes to be copied.SQLExceptionint getBytes(long pos,
int length,
byte[] buf)
throws SQLException
pos - is the first byte of the bfile to be extracted. (1-based)length - is the number of consecutive bytes to be copied.buf - is the buffer to had the extracted bytes.SQLExceptionInputStream getBinaryStream() throws SQLException
SQLExceptionInputStream getBinaryStream(long pos) throws SQLException
pos - is the position data to be read.SQLExceptionlong position(byte[] pattern,
long start)
throws SQLException
pattern - is the pattern to search for.start - is the position at which to begin searching. (1-based)SQLExceptionlong position(OracleBfile pattern, long start) throws SQLException
pattern - is the pattern to search for.start - is the position at which to begin searching. (1-based)SQLExceptionString getName() throws SQLException
bfile - The Bfile for which to get the file name.SQLExceptionString getDirAlias() throws SQLException
bfile - The Bfile for which to get the directory alias.SQLExceptionvoid openFile()
throws SQLException
SQLExceptionboolean isFileOpen()
throws SQLException
SQLExceptionboolean fileExists()
throws SQLException
SQLExceptionvoid closeFile()
throws SQLException
SQLExceptionvoid open(LargeObjectAccessMode mode) throws SQLException
SQLExceptionvoid close()
throws SQLException
SQLExceptionboolean isOpen()
throws SQLException
SQLException