org.apache.pdfbox.io
Class RandomAccessFile

java.lang.Object
  extended by org.apache.pdfbox.io.RandomAccessFile
All Implemented Interfaces:
RandomAccess, RandomAccessRead, SequentialRead

public class RandomAccessFile
extends java.lang.Object
implements RandomAccess

An interface to allow temp PDF data to be stored in a scratch file on the disk to reduce memory consumption.

Version:
$Revision: 1.2 $
Author:
Ben Litchfield

Constructor Summary
RandomAccessFile(java.io.File file, java.lang.String mode)
          Constructor.
 
Method Summary
 void close()
          Release resources that are being held.
 long length()
          The total number of bytes that are available.
 int read()
          Read a single byte of data.
 int read(byte[] b, int offset, int length)
          Read a buffer of data.
 void seek(long position)
          Seek to a position in the data.
 void write(byte[] b, int offset, int length)
          Write a buffer of data to the stream.
 void write(int b)
          Write a byte to the stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RandomAccessFile

public RandomAccessFile(java.io.File file,
                        java.lang.String mode)
                 throws java.io.FileNotFoundException
Constructor.

Parameters:
file - The file to write the data to.
mode - The writing mode.
Throws:
java.io.FileNotFoundException - If the file cannot be created.
Method Detail

close

public void close()
           throws java.io.IOException
Release resources that are being held.

Specified by:
close in interface SequentialRead
> Classes in org.apache.pdfbox.io used by org.apache.pdfbox.pdmodel RandomAccess
          An interface to allow PDF files to be stored completely in memory or to use a scratch file on the disk.  

Classes in org.apache.pdfbox.io used by org.apache.pdfbox.pdmodel.common
RandomAccess
          An interface to allow PDF files to be stored completely in memory or to use a scratch file on the disk.
 

Classes in org.apache.pdfbox.io used by org.apache.pdfbox.pdmodel.graphics.xobject
RandomAccess
          An interface to allow PDF files to be stored completely in memory or to use a scratch file on the disk.
 



./usr/share/doc/libpdfbox-java-doc/html/org/apache/pdfbox/io/RandomAccessFile.html0000644000000000000000000004415212101772017026725 0ustar rootroot RandomAccessFile (pdfbox-1.7.0 API)