public class POIFSReader extends Object
| Modifier and Type | Class and Description |
|---|---|
private static class |
POIFSReader.SampleListener |
| Modifier and Type | Field and Description |
|---|---|
private int |
bigBlockSize |
private POIFSReaderRegistry |
registry |
private boolean |
registryClosed |
private RandomAccessInputStream |
stream |
| Constructor and Description |
|---|
POIFSReader()
Create a POIFSReader
|
| Modifier and Type | Method and Description |
|---|---|
static void |
main(String[] args)
read in files
|
private void |
processProperties(BlockList small_blocks,
BlockList big_blocks,
Iterator properties,
POIFSDocumentPath path) |
void |
read(RandomAccessInputStream stream,
int size)
Read from an InputStream and process the documents we get
|
void |
registerListener(POIFSReaderListener listener)
Register a POIFSReaderListener for all documents
|
void |
registerListener(POIFSReaderListener listener,
POIFSDocumentPath path,
String name)
Register a POIFSReaderListener for a document in the specified
directory
|
void |
registerListener(POIFSReaderListener listener,
String name)
Register a POIFSReaderListener for a document in the root
directory
|
private POIFSReaderRegistry registry
private boolean registryClosed
private int bigBlockSize
private RandomAccessInputStream stream
public void read(RandomAccessInputStream stream, int size) throws IOException
stream - the InputStream from which to read the dataIOException - on errors reading, or on invalid datapublic void registerListener(POIFSReaderListener listener)
listener - the listener to be registeredNullPointerException - if listener is nullIllegalStateException - if read() has already been
calledpublic void registerListener(POIFSReaderListener listener, String name)
listener - the listener to be registeredname - the document nameNullPointerException - if listener is null or name is
null or emptyIllegalStateException - if read() has already been
calledpublic void registerListener(POIFSReaderListener listener, POIFSDocumentPath path, String name)
listener - the listener to be registeredpath - the document path; if null, the root directory is
assumedname - the document nameNullPointerException - if listener is null or name is
null or emptyIllegalStateException - if read() has already been
calledpublic static void main(String[] args) throws IOException
args - names of the filesIOExceptionprivate void processProperties(BlockList small_blocks, BlockList big_blocks, Iterator properties, POIFSDocumentPath path) throws IOException
IOExceptionCopyright © 2016 Open Microscopy Environment