public interface SimpleChannel
SecureOptions.SourceDocument
,
SecureOptions.ScrubbedDocument
and SecureOptions.ResultDocument
options.Modifier and Type | Field and Description |
---|---|
static int |
DIRECTBYTEBUFFERS
Indicates the SimpleChannel requires direct ByteBuffers to operate correctly.
|
static int |
READ
Indicates the SimpleChannel supports reading bytes.
|
static int |
READWRITE
Indicates the SimpleChannel supports both reading and writing bytes.
|
static int |
WRITE
Indicates the SimpleChannel supports writing bytes.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close resources associated with this SimpleChannel
|
int |
read(java.nio.ByteBuffer buffer,
long position)
Read bytes into the buffer from the developer's bytes.
|
long |
size()
The size of the developer's bytes.
|
int |
supports()
Return what operations the SimpleChannel supports
|
void |
truncate(long size)
Truncate the stream to the given length.
|
void |
write(java.nio.ByteBuffer buffer,
long position)
Writes bytes from the buffer to the developer's bytes.
|
static final int READ
static final int WRITE
static final int READWRITE
static final int DIRECTBYTEBUFFERS
int read(java.nio.ByteBuffer buffer, long position) throws java.io.IOException
buffer
- Target buffer for the read bytesposition
- Location in the underlying byte stream where the method should being reading bytesjava.io.IOException
- Any failure to readvoid write(java.nio.ByteBuffer buffer, long position) throws java.io.IOException
buffer
- position
- Location in the underlying byte stream where the method should being writing bytesjava.io.IOException
- Any failure to writelong size() throws java.io.IOException
java.io.IOException
- Any failure to get the sizeint supports()
void truncate(long size) throws java.io.IOException
size
- Size of the file after truncation.java.io.IOException
void close()
Copyright © 2021 Oracle. All right reserved. Restricted and confidential property of Oracle. Solely for use by recipent under agreement forbidding disclosure.