Class EmbeddedXMLObject

java.lang.Object
writer2latex.office.EmbeddedObject
writer2latex.office.EmbeddedXMLObject

public class EmbeddedXMLObject extends EmbeddedObject
This class represents those embedded objects in an ODF document that have an XML representation: Formulas, charts, spreadsheets, text, drawings and presentations. These object types are stored using a combination of content, settings and styles XML files. The settings are application specific and ignored.
  • Field Details

    • contentDOM

      protected Document contentDOM
    • stylesDOM

      protected Document stylesDOM
  • Constructor Details

    • EmbeddedXMLObject

      protected EmbeddedXMLObject(String sName, String sType, OfficeDocument doc, SimpleZipReader source)
      Read an object from an ODF package document
      Parameters:
      sName - The name of the object.
      sType - The MIME-type of the object.
      source - A ZIP reader providing the contents of the package
  • Method Details

    • getContentDOM

      public Document getContentDOM() throws SAXException, IOException
      Returns the content data for this embedded object.
      Returns:
      DOM representation of "content.xml"
      Throws:
      SAXException - If any parser error occurs
      IOException - If any IO error occurs
    • getStylesDOM

      public Document getStylesDOM() throws SAXException, IOException
      Returns the style data for this embedded object.
      Returns:
      DOM representation of "styles.xml"
      Throws:
      SAXException - If any parser error occurs
      IOException - If any IO error occurs
    • dispose

      public void dispose()
      Description copied from class: EmbeddedObject
      Dispose this EmbeddedObject. This implies that the content is nullified and the object is removed from the collection in the OfficeDocument.
      Overrides:
      dispose in class EmbeddedObject