Package com.independentsoft.office.odf.charts

# Class Chart

java.lang.Object
com.independentsoft.office.odf.Document
com.independentsoft.office.odf.charts.Chart

public class Chart extends Document
The Class Chart.

- ## Field Summary

  ### Fields inherited from class com.independentsoft.office.odf.Document

  `commonStyles, customFileTable, inputFileTable, isTemplate, manifest, metaData, mimeType, outputStream, settings, utf8`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Chart()`
  Instantiates a new chart.
  `Chart​(InputStream inputStream)`
  Instantiates a new chart.
  `Chart​(String file)`
  Instantiates a new chart.
  `Chart​(String folder, FileTable inputFileTable)`
  Instantiates a new chart.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Chart`
  `clone()`
  Creates a new object that is a deep copy of the current instance.
  `AutomaticStyles`
  `getAutomaticStyles()`
  Gets the automatic styles.
  `byte[]`
  `getBytes()`
  Gets the bytes.
  `ChartContent`
  `getContent()`
  Gets the content.
  `List<IContentElement>`
  `getContentElements()`
  Returns all content elements.
  `List<Font>`
  `getFonts()`
  Gets the fonts.
  `InputStream`
  `getInputStream()`
  Gets the input stream.
  `OfficeScripts`
  `getOfficeScripts()`
  Gets the office scripts.
  `void`
  `open​(InputStream inputStream)`
  Open.
  `void`
  `open​(String filePath)`
  Open.
  `protected void`
  `openImplementation​(InputStream inputStream)`
  `void`
  `renameStyle​(Style style, String newName)`
  Rename style.
  `void`
  `save​(OutputStream outputStream)`
  Save.
  `void`
  `save​(String filePath)`
  Save.
  `void`
  `save​(String filePath, boolean overwrite)`
  Save.

  ### Methods inherited from class com.independentsoft.office.odf.Document

  `addFile, addFile, addManifestEntry, addMimeTypeFile, getAttributedTexts, getCommonStyles, getConfigurations, getCreationDate, getCreator, getCustomFileTable, getDescription, getEditingCycles, getEditingDuration, getFields, getFileInputTable, getGenerator, getHeadings, getImages, getInitialCreator, getInputFileTable, getKeywords, getLanguage, getLastModified, getLists, getManifest, getMetaData, getMimeType, getParagraphs, getPreservedPackageParts, getPrintDate, getPrintedBy, getSections, getStatistic, getSubject, getTables, getTemplate, getTexts, getTitle, getUserDefinedMetadataElements, isTemplate, replace, replace, setCreationDate, setCreator, setDescription, setEditingCycles, setEditingDuration, setInitialCreator, setKeywords, setLanguage, setLastModified, setMimeType, setPrintDate, setPrintedBy, setStatistic, setSubject, setTemplate, setTemplate, setTitle`

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

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

- ## Constructor Details

  - ### Chart

    public Chart()
    Instantiates a new chart.

  - ### Chart

    public Chart​(String file) throws IOException, XMLStreamException
    Instantiates a new chart.
    Parameters:
      `file` - the file
    Throws:
      `IOException` - Signals that an I/O exception has occurred.
      `XMLStreamException` - the xML stream exception

  - ### Chart

    public Chart​(InputStream inputStream) throws IOException, XMLStreamException
    Instantiates a new chart.
    Parameters:
      `inputStream` - the input stream
    Throws:
      `IOException` - Signals that an I/O exception has occurred.
      `XMLStreamException` - the xML stream exception

  - ### Chart

    public Chart​(String folder, FileTable inputFileTable) throws IOException, XMLStreamException
    Instantiates a new chart.
    Parameters:
      `folder` - the folder
      `inputFileTable` - the input file table
    Throws:
      `IOException` - Signals that an I/O exception has occurred.
      `XMLStreamException` - the xML stream exception

- ## Method Details

  - ### open

    public void open​(String filePath) throws IOException, XMLStreamException
    Description copied from class: `Document`
    Open.
    Specified by:
      `open` in class `Document`
    Parameters:
      `filePath` - the file
    Throws:
      `IOException` - Signals that an I/O exception has occurred.
      `XMLStreamException` - the xML stream exception

  - ### open

    public void open​(InputStream inputStream) throws IOException, XMLStreamException
    Description copied from class: `Document`
    Open.
    Specified by:
      `open` in class `Document`
    Parameters:
      `inputStream` - the stream
    Throws:
      `IOException` - Signals that an I/O exception has occurred.
      `XMLStreamException` - the xML stream exception

  - ### openImplementation

    protected void openImplementation​(InputStream inputStream) throws IOException, XMLStreamException
    Overrides:
      `openImplementation` in class `Document`
    Throws:
      `IOException`
      `XMLStreamException`

  - ### renameStyle

    public void renameStyle​(Style style, String newName)
    Rename style.
    Parameters:
      `style` - the style
      `newName` - the new name

  - ### getContentElements

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

  - ### clone

    public Chart clone()
    Creates a new object that is a deep copy of the current instance.
    Overrides:
      `clone` in class `Object`
    Returns:
      A new object that is a copy of this instance.

  - ### save

    public void save​(String filePath) throws IOException
    Description copied from class: `Document`
    Save.
    Specified by:
      `save` in class `Document`
    Parameters:
      `filePath` - the file
    Throws:
      `IOException` - Signals that an I/O exception has occurred.

  - ### save

    public void save​(String filePath, boolean overwrite) throws IOException
    Description copied from class: `Document`
    Save.
    Specified by:
      `save` in class `Document`
    Parameters:
      `filePath` - the file
      `overwrite` - the overwrite
    Throws:
      `IOException` - Signals that an I/O exception has occurred.

  - ### save

    public void save​(OutputStream outputStream) throws IOException
    Description copied from class: `Document`
    Save.
    Specified by:
      `save` in class `Document`
    Parameters:
      `outputStream` - the stream
    Throws:
      `IOException` - Signals that an I/O exception has occurred.

  - ### getInputStream

    public InputStream getInputStream() throws IOException
    Description copied from class: `Document`
    Gets the input stream.
    Specified by:
      `getInputStream` in class `Document`
    Returns:
      the input stream
    Throws:
      `IOException` - Signals that an I/O exception has occurred.

  - ### getBytes

    public byte[] getBytes() throws IOException
    Description copied from class: `Document`
    Gets the bytes.
    Specified by:
      `getBytes` in class `Document`
    Returns:
      the bytes
    Throws:
      `IOException` - Signals that an I/O exception has occurred.

  - ### getContent

    public ChartContent getContent()
    Gets the content.
    Returns:
      the content

  - ### getFonts

    public List<Font> getFonts()
    Gets the fonts.
    Returns:
      the fonts

  - ### getOfficeScripts

    public OfficeScripts getOfficeScripts()
    Gets the office scripts.
    Returns:
      the office scripts

  - ### getAutomaticStyles

    public AutomaticStyles getAutomaticStyles()
    Gets the automatic styles.
    Returns:
      the automatic styles