public abstract class Story extends CompositeNode
Paragraph and Table.
To learn more, visit the Logical Levels of Nodes in a Document documentation article.
Text of a Word document is said to consist of several stories. The main text is stored in the main text story represented by Body, each header and footer is stored in a separate story represented by HeaderFooter.
| Constructor and Description |
|---|
Story() |
| Modifier and Type | Method and Description |
|---|---|
Paragraph |
appendParagraph(java.lang.String text)
A shortcut method that creates a
Paragraph object with optional text and appends it to the end of this object. |
void |
deleteShapes()
Deletes all shapes from the text of this story.
|
Paragraph |
getFirstParagraph()
Gets the first paragraph in the story.
|
Paragraph |
getLastParagraph()
Gets the last paragraph in the story.
|
ParagraphCollection |
getParagraphs()
Gets a collection of paragraphs that are immediate children of the story.
|
int |
getStoryType()
Gets the type of this story.
|
TableCollection |
getTables()
Gets a collection of tables that are immediate children of the story.
|
acceptChildren, acceptCore, appendChild, coreRemoveSelfOnly, getChild, getChildNodes, getChildNodes, getContainer, getCount, getCurrentNode, getFirstChild, getLastChild, getNextMatchingNode, getText, hasChildNodes, indexOf, insertAfter, insertBefore, isComposite, iterator, prependChild, removeAllChildren, removeChild, removeSmartTags, selectNodes, selectSingleNodeaccept, dd, deepClone, getAncestor, getAncestor, getCustomNodeId, getDocument, getNextSibling, getNodeType, getParentNode, getPreviousSibling, getRange, memberwiseClone, nextPreOrder, nodeTypeToString, previousPreOrder, remove, setCustomNodeId, toString, toString, toString, visitorActionToBoolpublic int getStoryType()
StoryType constants.public Paragraph getFirstParagraph()
public Paragraph getLastParagraph()
public ParagraphCollection getParagraphs()
public TableCollection getTables()
public void deleteShapes()
public Paragraph appendParagraph(java.lang.String text)
Paragraph object with optional text and appends it to the end of this object.text - The text for the paragraph. Can be null or empty string.