com.imagero.uio.blob
Class Blob.RoBlob
java.lang.Object
com.imagero.uio.blob.Blob
com.imagero.uio.blob.Blob.RoBlob
- Enclosing class:
- Blob
- public static class Blob.RoBlob
- extends Blob
|
Method Summary |
void |
clear()
release reloadable resources |
protected long |
computeLength()
|
int |
get(long start,
byte[] dest)
retrieve data from this Blob |
byte[] |
get(long start,
int length)
retrieve data from this Blob |
void |
set(long start,
byte[] data)
set data (work only if writable returns true) |
boolean |
writable()
determine if this Blob is writable and method set(long, byte[]) can be used to change content of this Blob |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Blob.RoBlob
public Blob.RoBlob(RandomAccessInput ro,
long start,
long length)
computeLength
protected long computeLength()
- Specified by:
computeLength in class Blob
get
public byte[] get(long start,
int length)
throws java.io.IOException
- Description copied from class:
Blob
- retrieve data from this Blob
- Specified by:
get in class Blob
- Parameters:
start - start offsetlength - how much bytes to get
- Returns:
- byte array with data
- Throws:
java.io.IOException
get
public int get(long start,
byte[] dest)
throws java.io.IOException
- Description copied from class:
Blob
- retrieve data from this Blob
- Specified by:
get in class Blob
- Parameters:
start - start offsetdest - where to copy data
- Returns:
- how much byte were copied
- Throws:
java.io.IOException
writable
public boolean writable()
- Description copied from class:
Blob
- determine if this Blob is writable and method set(long, byte[]) can be used to change content of this Blob
- Specified by:
writable in class Blob
- Returns:
- true if Blob is writable
set
public void set(long start,
byte[] data)
throws java.io.IOException
- Description copied from class:
Blob
- set data (work only if writable returns true)
- Specified by:
set in class Blob
- Parameters:
start - start in destinationdata - new data
- Throws:
java.io.IOException
clear
public void clear()
- Description copied from class:
Blob
- release reloadable resources
- Specified by:
clear in class Blob