public class XWPFNumbering extends POIXMLDocumentPart
Modifier and Type | Field and Description |
---|---|
protected java.util.List<XWPFAbstractNum> |
abstractNums |
protected java.util.List<XWPFNum> |
nums |
DEFAULT_XML_OPTIONS
Constructor and Description |
---|
XWPFNumbering()
create a new XWPFNumbering object for use in a new document
|
XWPFNumbering(PackagePart part,
PackageRelationship rel)
create a new styles object with an existing document
|
Modifier and Type | Method and Description |
---|---|
java.math.BigInteger |
addAbstractNum(XWPFAbstractNum abstractNum)
add a new AbstractNum and return its AbstractNumID
|
java.math.BigInteger |
addNum(java.math.BigInteger abstractNumID)
Add a new num with an abstractNumID
|
void |
addNum(java.math.BigInteger abstractNumID,
java.math.BigInteger numID)
Add a new num with an abstractNumID and a numID
|
java.math.BigInteger |
addNum(XWPFNum num)
add a new number to the numbering document
|
protected void |
commit()
save and commit numbering
|
XWPFAbstractNum |
getAbstractNum(java.math.BigInteger abstractNumID)
get AbstractNum by abstractNumID
|
java.math.BigInteger |
getAbstractNumID(java.math.BigInteger numID)
return the abstractNumID
If the AbstractNumID not exists
return null
|
java.math.BigInteger |
getIdOfAbstractNum(XWPFAbstractNum abstractNum)
Compare AbstractNum with abstractNums of this numbering document.
|
XWPFNum |
getNum(java.math.BigInteger numID)
get Num by NumID
|
boolean |
numExist(java.math.BigInteger numID)
Checks whether number with numID exists
|
protected void |
onDocumentRead()
read numbering form an existing package
|
boolean |
removeAbstractNum(java.math.BigInteger abstractNumID)
remove an existing abstractNum
|
void |
setNumbering(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTNumbering numbering)
Sets the ctNumbering
|
addRelation, clearMemoryPackagePart, createRelationship, createRelationship, createRelationship, getPackagePart, getPackageRelationship, getParent, getRelationById, getRelationCounter, getRelationId, getRelations, getTargetPart, onDocumentCreate, onDocumentRemove, onSave, read, rebase, removeRelation, removeRelation, toString
protected java.util.List<XWPFAbstractNum> abstractNums
protected java.util.List<XWPFNum> nums
public XWPFNumbering(PackagePart part, PackageRelationship rel) throws java.io.IOException, OpenXML4JException
java.io.IOException
OpenXML4JException
public XWPFNumbering()
protected void onDocumentRead() throws java.io.IOException
onDocumentRead
in class POIXMLDocumentPart
java.io.IOException
protected void commit() throws java.io.IOException
commit
in class POIXMLDocumentPart
java.io.IOException
public void setNumbering(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTNumbering numbering)
numbering
- public boolean numExist(java.math.BigInteger numID)
numID
- public java.math.BigInteger addNum(XWPFNum num)
num
- public java.math.BigInteger addNum(java.math.BigInteger abstractNumID)
public void addNum(java.math.BigInteger abstractNumID, java.math.BigInteger numID)
abstractNumID
- numID
- public XWPFNum getNum(java.math.BigInteger numID)
numID
- public XWPFAbstractNum getAbstractNum(java.math.BigInteger abstractNumID)
abstractNumID
- public java.math.BigInteger getIdOfAbstractNum(XWPFAbstractNum abstractNum)
abstractNum
- public java.math.BigInteger addAbstractNum(XWPFAbstractNum abstractNum)
abstractNum
- public boolean removeAbstractNum(java.math.BigInteger abstractNumID)
abstractNumID
- public java.math.BigInteger getAbstractNumID(java.math.BigInteger numID)
numID
- Copyright © 2005-2010 Potix Corporation. All Rights Reserved.