|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.poi.POIDocument
org.apache.poi.hwpf.HWPFDocumentCore
org.apache.poi.hwpf.HWPFDocument
public final class HWPFDocument
This class acts as the bucket that we throw all of the Word data structures into.
Constructor Summary | |
---|---|
HWPFDocument(org.apache.poi.poifs.filesystem.DirectoryNode directory)
This constructor loads a Word document from a specific point in a POIFSFileSystem, probably not the default. |
|
HWPFDocument(org.apache.poi.poifs.filesystem.DirectoryNode directory,
org.apache.poi.poifs.filesystem.POIFSFileSystem pfilesystem)
Deprecated. Use HWPFDocument(DirectoryNode) instead |
|
HWPFDocument(java.io.InputStream istream)
This constructor loads a Word document from an InputStream. |
|
HWPFDocument(org.apache.poi.poifs.filesystem.POIFSFileSystem pfilesystem)
This constructor loads a Word document from a POIFSFileSystem |
Method Summary | |
---|---|
int |
characterLength()
Returns the character length of a document. |
void |
delete(int start,
int length)
|
Bookmarks |
getBookmarks()
|
Range |
getCommentsRange()
Returns the Range which covers all annotations. |
byte[] |
getDataStream()
|
DocumentProperties |
getDocProperties()
|
Range |
getEndnoteRange()
Returns the Range which covers all endnotes. |
Notes |
getEndnotes()
|
EscherRecordHolder |
getEscherRecordHolder()
|
Fields |
getFields()
Returns user-friendly interface to access document Field s |
FieldsTables |
getFieldsTables()
Deprecated. |
Range |
getFootnoteRange()
Returns the Range which covers all the Footnotes. |
Notes |
getFootnotes()
|
Range |
getHeaderStoryRange()
Returns the range which covers all "Header Stories". |
Range |
getMainTextboxRange()
Returns the Range which covers all textboxes. |
OfficeDrawings |
getOfficeDrawingsHeaders()
|
OfficeDrawings |
getOfficeDrawingsMain()
|
Range |
getOverallRange()
Returns the range that covers all text in the file, including main text, footnotes, headers and comments |
PicturesTable |
getPicturesTable()
|
Range |
getRange()
Returns the range which covers the whole of the document, but excludes any headers and footers. |
RevisionMarkAuthorTable |
getRevisionMarkAuthorTable()
Gets a reference to the revision mark author table, which holds the revision mark authors for the document. |
SavedByTable |
getSavedByTable()
Gets a reference to the saved -by table, which holds the save history for the document. |
ShapesTable |
getShapesTable()
Deprecated. use getOfficeDrawingsMain() instead |
byte[] |
getTableStream()
|
java.lang.StringBuffer |
getText()
Internal method to access document text |
TextPieceTable |
getTextTable()
|
int |
registerList(HWPFList list)
|
void |
write(java.io.OutputStream out)
Writes out the word file that is represented by an instance of this class. |
Methods inherited from class org.apache.poi.hwpf.HWPFDocumentCore |
---|
getCharacterTable, getDocumentText, getFileInformationBlock, getFontTable, getListTables, getObjectsPool, getParagraphTable, getSectionTable, getStyleSheet, verifyAndBuildPOIFS |
Methods inherited from class org.apache.poi.POIDocument |
---|
createInformationProperties, getDocumentSummaryInformation, getSummaryInformation |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public HWPFDocument(java.io.InputStream istream) throws java.io.IOException
istream
- The InputStream that contains the Word document.
java.io.IOException
- If there is an unexpected IOException from the passed
in InputStream.public HWPFDocument(org.apache.poi.poifs.filesystem.POIFSFileSystem pfilesystem) throws java.io.IOException
pfilesystem
- The POIFSFileSystem that contains the Word document.
java.io.IOException
- If there is an unexpected IOException from the passed
in POIFSFileSystem.public HWPFDocument(org.apache.poi.poifs.filesystem.DirectoryNode directory, org.apache.poi.poifs.filesystem.POIFSFileSystem pfilesystem) throws java.io.IOException
HWPFDocument(DirectoryNode)
instead
pfilesystem
- The POIFSFileSystem that contains the Word document.
java.io.IOException
- If there is an unexpected IOException from the passed
in POIFSFileSystem.public HWPFDocument(org.apache.poi.poifs.filesystem.DirectoryNode directory) throws java.io.IOException
directory
- The DirectoryNode that contains the Word document.
java.io.IOException
- If there is an unexpected IOException from the passed
in POIFSFileSystem.Method Detail |
---|
public TextPieceTable getTextTable()
getTextTable
in class HWPFDocumentCore
public java.lang.StringBuffer getText()
HWPFDocumentCore
getText
in class HWPFDocumentCore
public DocumentProperties getDocProperties()
public Range getOverallRange()
HWPFDocumentCore
getOverallRange
in class HWPFDocumentCore
public Range getRange()
getRange
in class HWPFDocumentCore
public Range getFootnoteRange()
Range
which covers all the Footnotes.
Range
which covers all the Footnotes.public Range getEndnoteRange()
Range
which covers all endnotes.
Range
which covers all endnotes.public Range getCommentsRange()
Range
which covers all annotations.
Range
which covers all annotations.public Range getMainTextboxRange()
Range
which covers all textboxes.
Range
which covers all textboxes.public Range getHeaderStoryRange()
public int characterLength()
public SavedByTable getSavedByTable()
public RevisionMarkAuthorTable getRevisionMarkAuthorTable()
public PicturesTable getPicturesTable()
public EscherRecordHolder getEscherRecordHolder()
public ShapesTable getShapesTable()
getOfficeDrawingsMain()
instead
public OfficeDrawings getOfficeDrawingsHeaders()
public OfficeDrawings getOfficeDrawingsMain()
public Bookmarks getBookmarks()
public Notes getEndnotes()
public Notes getFootnotes()
public FieldsTables getFieldsTables()
public Fields getFields()
Field
s
Field
spublic void write(java.io.OutputStream out) throws java.io.IOException
write
in class org.apache.poi.POIDocument
out
- The OutputStream to write to.
java.io.IOException
- If there is an unexpected IOException from the passed
in OutputStream.public byte[] getDataStream()
public byte[] getTableStream()
public int registerList(HWPFList list)
public void delete(int start, int length)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |