com.aspose.pdf.elements
Class Sections

java.lang.Object
  extended by com.aspose.pdf.elements.PdfElementBase
      extended by com.aspose.pdf.elements.Sections
All Implemented Interfaces:
java.lang.Cloneable

public class Sections
extends PdfElementBase

Represents a collection of Section objects.


Constructor Summary
Sections(Pdf pdf)
          Initializes a new instance of the Sections class.
 
Method Summary
 Section add()
          Initializes a new instance of the Section class and add it to the Sections collection.
 void add(Section section)
          Adds a new Section object into the collection.
 void clear()
          Clear sections of pdf.
 java.lang.Object clone()
          Sections does not support clone method.
 Section getAt(int index)
          Gets a Section object from the collection at the index.
 Section getByID(java.lang.String ID)
          Gets a Section object by the ID.
 org.w3c.dom.Element getDOMElement()
          Gets a DOM representation of the pdf element.
 int indexOf(Section section)
          Gets the index of a specified section in the collection.
 void Insert(int index, Section section)
          Inserts a new Section object into the collection at specified position.
 boolean isEmpty()
          Returns true if the collection contains no section.
 java.util.Iterator iterator()
          Returns an iterator over the section objects in sections in proper sequence.
 void remove(int index)
          Removes a Section object from the collection at the specified position.
 void remove(Section section)
          Removes a Section object from the collection.
 int size()
          Gets the size of section objects collection.
 
Methods inherited from class com.aspose.pdf.elements.PdfElementBase
getElementFactory, getID, getNameIndex, setID
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Sections

public Sections(Pdf pdf)
Initializes a new instance of the Sections class.

Method Detail

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Sections does not support clone method.

Overrides:
clone in class PdfElementBase
Throws:
java.lang.CloneNotSupportedException
See Also:
Object.clone()

add

public void add(Section section)
Adds a new Section object into the collection.

Parameters:
section - the section that will be added.

add

public Section add()
            throws AsposeBaseException
Initializes a new instance of the Section class and add it to the Sections collection.

Returns:
a section object that has beened add to sections of pdf
Throws:
AsposeBaseException

clear

public void clear()
Clear sections of pdf.


indexOf

public int indexOf(Section section)
Gets the index of a specified section in the collection.

Returns:
The index of the specified section

Insert

public void Insert(int index,
                   Section section)
Inserts a new Section object into the collection at specified position.

Parameters:
index - The position that the section will be inserted at.
section - the section that willed inserted.

getAt

public Section getAt(int index)
Gets a Section object from the collection at the index.


getByID

public Section getByID(java.lang.String ID)
Gets a Section object by the ID.


remove

public void remove(Section section)
Removes a Section object from the collection.

Parameters:
section - The section that willed removed.

remove

public void remove(int index)
Removes a Section object from the collection at the specified position.

Parameters:
index - The index of the section that willed removed.

size

public int size()
Gets the size of section objects collection.


iterator

public java.util.Iterator iterator()
Returns an iterator over the section objects in sections in proper sequence.


isEmpty

public boolean isEmpty()
Returns true if the collection contains no section.


getDOMElement

public org.w3c.dom.Element getDOMElement()
                                  throws AsposeBaseException
Description copied from class: PdfElementBase
Gets a DOM representation of the pdf element.

Overrides:
getDOMElement in class PdfElementBase
Throws:
AsposeBaseException
See Also:
PdfElementBase.getDOMElement()