Package org.apache.poi.hpsf.extractor
Class HPSFPropertiesExtractor
- java.lang.Object
-
- org.apache.poi.hpsf.extractor.HPSFPropertiesExtractor
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,POIOLE2TextExtractor
,POITextExtractor
public class HPSFPropertiesExtractor extends java.lang.Object implements POIOLE2TextExtractor
Extracts all of the HPSF properties, both build in and custom, returning them in textual form.
-
-
Constructor Summary
Constructors Constructor Description HPSFPropertiesExtractor(POIOLE2TextExtractor mainExtractor)
HPSFPropertiesExtractor(POIDocument document)
HPSFPropertiesExtractor(POIFSFileSystem fs)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
POIDocument
getDocument()
Return the underlying POIDocumentjava.lang.String
getDocumentSummaryInformationText()
POIDocument
getFilesystem()
POITextExtractor
getMetadataTextExtractor()
Prevent recursion!java.lang.String
getSummaryInformationText()
java.lang.String
getText()
Retrieves all the text from the document.int
hashCode()
boolean
isCloseFilesystem()
void
setCloseFilesystem(boolean doCloseFilesystem)
-
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.poi.extractor.POIOLE2TextExtractor
getDocSummaryInformation, getRoot, getSummaryInformation
-
Methods inherited from interface org.apache.poi.extractor.POITextExtractor
close
-
-
-
-
Constructor Detail
-
HPSFPropertiesExtractor
public HPSFPropertiesExtractor(POIOLE2TextExtractor mainExtractor)
-
HPSFPropertiesExtractor
public HPSFPropertiesExtractor(POIDocument document)
-
HPSFPropertiesExtractor
public HPSFPropertiesExtractor(POIFSFileSystem fs)
-
-
Method Detail
-
getDocumentSummaryInformationText
public java.lang.String getDocumentSummaryInformationText()
-
getSummaryInformationText
public java.lang.String getSummaryInformationText()
-
getText
public java.lang.String getText()
Description copied from interface:POITextExtractor
Retrieves all the text from the document. How cells, paragraphs etc are separated in the text is implementation specific - see the javadocs for a specific project for details.- Specified by:
getText
in interfacePOITextExtractor
- Returns:
- the text of all the properties defined in the document.
-
getMetadataTextExtractor
public POITextExtractor getMetadataTextExtractor()
Prevent recursion!- Specified by:
getMetadataTextExtractor
in interfacePOIOLE2TextExtractor
- Specified by:
getMetadataTextExtractor
in interfacePOITextExtractor
- Returns:
- an instance of POIExtractor that can extract meta-data.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
getDocument
public POIDocument getDocument()
Description copied from interface:POIOLE2TextExtractor
Return the underlying POIDocument- Specified by:
getDocument
in interfacePOIOLE2TextExtractor
- Specified by:
getDocument
in interfacePOITextExtractor
- Returns:
- the underlying POIDocument
-
setCloseFilesystem
public void setCloseFilesystem(boolean doCloseFilesystem)
- Specified by:
setCloseFilesystem
in interfacePOITextExtractor
- Parameters:
doCloseFilesystem
-true
(default), if underlying resources/filesystem should be closed onPOITextExtractor.close()
-
isCloseFilesystem
public boolean isCloseFilesystem()
- Specified by:
isCloseFilesystem
in interfacePOITextExtractor
- Returns:
true
, if resources/filesystem should be closed onPOITextExtractor.close()
-
getFilesystem
public POIDocument getFilesystem()
- Specified by:
getFilesystem
in interfacePOITextExtractor
- Returns:
- The underlying resources/filesystem
-
-