intarsys PDF library API

de.intarsys.tools.randomaccess
Class AbstractRandomAccess

java.lang.Object
  extended by de.intarsys.tools.randomaccess.AbstractRandomAccess
All Implemented Interfaces:
IRandomAccess
Direct Known Subclasses:
BufferedRandomAccess, RandomAccessByteArray, RandomAccessFile, RandomAccessFilter

public abstract class AbstractRandomAccess
extends Object
implements IRandomAccess

Supports reading and writing to a random access data container. A random access data container behaves like a large array of bytes.


Constructor Summary
AbstractRandomAccess()
           
 
Method Summary
 InputStream asInputStream()
          A InputStream view on the data structure.
 OutputStream asOutputStream()
          A OutputStream view on the data structure.
 void mark()
          Mark the current offset into the data in a stack like manner.
 void reset()
          Reset to the last position on the mark-stack.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.intarsys.tools.randomaccess.IRandomAccess
close, flush, getLength, getOffset, isReadOnly, read, read, read, seek, seekBy, setLength, write, write, write
 

Constructor Detail

AbstractRandomAccess

public AbstractRandomAccess()
Method Detail

asInputStream

public InputStream asInputStream()
Description copied from interface: IRandomAccess
A InputStream view on the data structure.

Specified by:
asInputStream in interface IRandomAccess
Returns:
A InputStream view on the data structure.

asOutputStream

public OutputStream asOutputStream()
Description copied from interface: IRandomAccess
A OutputStream view on the data structure.

Specified by:
asOutputStream in interface IRandomAccess
Returns:
A OutputStream view on the data structure.

mark

public void mark()
          throws IOException
Description copied from interface: IRandomAccess
Mark the current offset into the data in a stack like manner.

Specified by:
mark in interface IRandomAccess
Throws:
IOException

reset

public void reset()
           throws IOException
Description copied from interface: IRandomAccess
Reset to the last position on the mark-stack.

Specified by:
reset in interface IRandomAccess
Throws:
IOException

intarsys PDF library API

Copyright © 2006 intarsys consulting GmbH. All Rights Reserved.