Package com.independentsoft.office.odf.fields

# Class ParagraphCount

java.lang.Object
com.independentsoft.office.odf.fields.Field
com.independentsoft.office.odf.fields.ParagraphCount

All Implemented Interfaces:
  `IContentElement`, `IParagraphContent`

public class ParagraphCount extends Field
Represents the number of paragraphs that an OpenDocument producer has counted for a document.

- ## Field Summary

  ### Fields inherited from class com.independentsoft.office.odf.fields.Field

  `parent`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ParagraphCount()`
  Initializes a new instance of the ParagraphCount class.
  `ParagraphCount​(InternalXMLStreamReader reader)`
  Instantiates a new paragraph count.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `ParagraphCount`
  `clone()`
  Creates a new object that is a deep copy of the current instance.
  `List<IContentElement>`
  `getContentElements()`
  Returns all content elements.
  `String`
  `getNumberFormat()`
  Specifies the numbering sequence.
  `IContentElement`
  `getParent()`
  Returns the parent content element.
  `String`
  `getValue()`
  Gets the number of paragraphs.
  `void`
  `setNumberFormat​(String numberFormat)`
  Specifies the numbering sequence.
  `void`
  `setParent​(IContentElement parent)`
  Sets the parent content element.
  `void`
  `setValue​(String value)`
  Sets the number of paragraphs.
  `String`
  `toString()`
  Converts the value of the current ParagraphCount object to its equivalent string representation.

  ### Methods inherited from class java.lang.Object

  `equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### ParagraphCount

    public ParagraphCount()
    Initializes a new instance of the ParagraphCount class.

  - ### ParagraphCount

    public ParagraphCount​(InternalXMLStreamReader reader) throws XMLStreamException
    Instantiates a new paragraph count.
    Parameters:
      `reader` - the reader
    Throws:
      `XMLStreamException` - the xML stream exception

- ## Method Details

  - ### getContentElements

    public List<IContentElement> getContentElements()
    Returns all content elements.
    Specified by:
      `getContentElements` in interface `IContentElement`
    Specified by:
      `getContentElements` in class `Field`
    Returns:
      A collection of content elements.

  - ### getParent

    public IContentElement getParent()
    Returns the parent content element.
    Specified by:
      `getParent` in interface `IContentElement`
    Overrides:
      `getParent` in class `Field`
    Returns:
      the parent

  - ### setParent

    public void setParent​(IContentElement parent)
    Sets the parent content element.
    Specified by:
      `setParent` in interface `IContentElement`
    Overrides:
      `setParent` in class `Field`
    Parameters:
      `parent` - the new parent

  - ### clone

    public ParagraphCount clone()
    Creates a new object that is a deep copy of the current instance.
    Specified by:
      `clone` in interface `IContentElement`
    Specified by:
      `clone` in interface `IParagraphContent`
    Specified by:
      `clone` in class `Field`
    Returns:
      A new object that is a copy of this instance.

  - ### toString

    public String toString()
    Converts the value of the current ParagraphCount object to its equivalent string representation.
    Overrides:
      `toString` in class `Object`
    Returns:
      the string

  - ### getNumberFormat

    public String getNumberFormat()
    Specifies the numbering sequence. The defined values are: - 1: Hindu-Arabic number sequence starts with 1. - a: number sequence of lowercase Modern Latin basic alphabet characters starts with "a". - A: number sequence of uppercase Modern Latin basic alphabet characters starts with "A". - i: number sequence of lowercase Roman numerals starts with "i". - I: number sequence of uppercase Roman numerals start with "I".
    Returns:
      the number format

  - ### setNumberFormat

    public void setNumberFormat​(String numberFormat)
    Specifies the numbering sequence. The defined values are: - 1: Hindu-Arabic number sequence starts with 1. - a: number sequence of lowercase Modern Latin basic alphabet characters starts with "a". - A: number sequence of uppercase Modern Latin basic alphabet characters starts with "A". - i: number sequence of lowercase Roman numerals starts with "i". - I: number sequence of uppercase Roman numerals start with "I".
    Parameters:
      `numberFormat` - the new number format

  - ### getValue

    public String getValue()
    Gets the number of paragraphs.
    Returns:
      the value

  - ### setValue

    public void setValue​(String value)
    Sets the number of paragraphs.
    Parameters:
      `value` - the new value