|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AccessImpl
Interface for the implementation of read/write access to the pixels of an array. This is the interface via which array implementations provide pixel read/write services to the BridgeNDArray class. BridgeNDArray, which performs parameter validations, is expected to be the only client of AccessImpl, so that implementations of this interface can in general assume that the arguments they receive make sense.
Method Summary | |
---|---|
void |
close()
This method will be called when read/write access to this object is no longer required. |
void |
read(Object buffer,
int start,
int size)
Reads a number of pixels from the current offset into a specified part of a supplied java array. |
void |
setOffset(long off)
Sets the offset into the array at which the next read/write will occur. |
void |
write(Object buffer,
int start,
int size)
Writes a number of pixels starting at the current offset from a specified part of a supplied array. |
Method Detail |
---|
void setOffset(long off) throws IOException
off
- the offset into the data array
IOException
void read(Object buffer, int start, int size) throws IOException
buffer
- an array of the appropriate primitive type for this
NDArray into whose elements
start..start+size
the pixels will be
readstart
- the starting offset into array into which the
pixels should be readsize
- the number of pixels to read (also the amount by
which the current offset will be incremented)
IOException
- if there is an I/O errorvoid write(Object buffer, int start, int size) throws IOException
buffer
- an array of the appropriate primitive type for this
ArrayImpl whose elements start..start+size
will be written outstart
- the starting point in the array from which pixels
will be writtensize
- the number of pixels to write (also the amount by
which the current offset will be incremented)
IOException
- if there is an I/O errorvoid close() throws IOException
This method will not be invoked more than once.
IOException
- if there is an I/O error
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |