Save This Page
Home » poi-src-3.2-FINAL-20081019 » org.apache.poi.poifs » filesystem » [javadoc | source]
org.apache.poi.poifs.filesystem
public class: POIFSDocument [javadoc | source]
java.lang.Object
   org.apache.poi.poifs.filesystem.POIFSDocument

All Implemented Interfaces:
    POIFSViewable, BlockWritable, BATManaged

This class manages a document in the POIFS filesystem.
Constructor:
 public POIFSDocument(String name,
    InputStream stream) throws IOException 
    Constructor
    Parameters:
    name - the name of the POIFSDocument
    stream - the InputStream we read data from
    Throws:
    IOException - thrown on read errors
    exception: IOException - thrown on read errors
 public POIFSDocument(String name,
    RawDataBlock[] blocks,
    int length) throws IOException 
    Constructor from large blocks
    Parameters:
    name - the name of the POIFSDocument
    blocks - the big blocks making up the POIFSDocument
    length - the actual length of the POIFSDocument
    Throws:
    IOException -
    exception: IOException -
 public POIFSDocument(String name,
    SmallDocumentBlock[] blocks,
    int length) 
    Constructor from small blocks
    Parameters:
    name - the name of the POIFSDocument
    blocks - the small blocks making up the POIFSDocument
    length - the actual length of the POIFSDocument
 public POIFSDocument(String name,
    ListManagedBlock[] blocks,
    int length) throws IOException 
    Constructor from small blocks
    Parameters:
    name - the name of the POIFSDocument
    blocks - the small blocks making up the POIFSDocument
    length - the actual length of the POIFSDocument
    Throws:
    IOException -
    exception: IOException -
 public POIFSDocument(String name,
    int size,
    POIFSDocumentPath path,
    POIFSWriterListener writer) throws IOException 
    Constructor
    Parameters:
    name - the name of the POIFSDocument
    size - the length of the POIFSDocument
    path - the path of the POIFSDocument
    writer - the writer who will eventually write the document contents
    Throws:
    IOException - thrown on read errors
    exception: IOException - thrown on read errors
Method from org.apache.poi.poifs.filesystem.POIFSDocument Summary:
countBlocks,   getDocumentProperty,   getShortDescription,   getSize,   getSmallBlocks,   getViewableArray,   getViewableIterator,   preferArray,   read,   setStartBlock,   writeBlocks
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.poi.poifs.filesystem.POIFSDocument Detail:
 public int countBlocks() 
    Return the number of BigBlock's this instance uses
 DocumentProperty getDocumentProperty() 
    Get the DocumentProperty
 public String getShortDescription() 
    Provides a short description of the object, to be used when a POIFSViewable object has not provided its contents.
 public int getSize() 
 public BlockWritable[] getSmallBlocks() 
    return the array of SmallDocumentBlocks used
 public Object[] getViewableArray() 
    Get an array of objects, some of which may implement POIFSViewable
 public Iterator getViewableIterator() 
    Get an Iterator of objects, some of which may implement POIFSViewable
 public boolean preferArray() 
    Give viewers a hint as to whether to call getViewableArray or getViewableIterator
  void read(byte[] buffer,
    int offset) 
    read data from the internal stores
 public  void setStartBlock(int index) 
    Set the start block for this instance
 public  void writeBlocks(OutputStream stream) throws IOException 
    Write the storage to an OutputStream