Class OleObject

java.lang.Object
com.independentsoft.office.odf.drawing.FrameContentElement
com.independentsoft.office.odf.drawing.OleObject
All Implemented Interfaces:
IContentElement

public class OleObject extends FrameContentElement
The Class OleObject.
  • Constructor Details

    • OleObject

      public OleObject()
      Instantiates a new ole object.
    • OleObject

      public OleObject(InternalXMLStreamReader reader) throws XMLStreamException
      Instantiates a new ole object.
      Parameters:
      reader - the reader
      Throws:
      XMLStreamException - the xML stream exception
    • OleObject

      public OleObject(String filePath) throws IOException
      Instantiates a new ole object.
      Parameters:
      filePath - the file path
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • OleObject

      public OleObject(String fileName, InputStream inputStream) throws IOException
      Instantiates a new ole object.
      Parameters:
      fileName - the file name
      inputStream - the input stream
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • OleObject

      public OleObject(String fileName, byte[] buffer)
      Instantiates a new ole object.
      Parameters:
      fileName - the file name
      buffer - the buffer
  • Method Details

    • load

      public void load(String filePath) throws IOException
      Load.
      Parameters:
      filePath - the file path
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • load

      public void load(String fileName, InputStream inputStream) throws IOException
      Load.
      Parameters:
      fileName - the file name
      inputStream - the input stream
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • load

      public void load(String fileName, byte[] buffer)
      Load.
      Parameters:
      fileName - the file name
      buffer - the buffer
    • save

      public void save(String filePath) throws IOException
      Save.
      Parameters:
      filePath - the file path
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • save

      public void save(String filePath, boolean overwrite) throws IOException
      Save.
      Parameters:
      filePath - the file path
      overwrite - the overwrite
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • save

      public void save(OutputStream outputStream) throws IOException
      Save.
      Parameters:
      outputStream - the output stream
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • getInputStream

      public InputStream getInputStream()
      Gets the input stream.
      Returns:
      the input stream
    • getContentElements

      public List<IContentElement> getContentElements()
      Returns all content elements.
      Specified by:
      getContentElements in interface IContentElement
      Specified by:
      getContentElements in class FrameContentElement
      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 FrameContentElement
      Returns:
      the parent
    • setParent

      public void setParent(IContentElement parent)
      Sets the parent content element.
      Specified by:
      setParent in interface IContentElement
      Overrides:
      setParent in class FrameContentElement
      Parameters:
      parent - the new parent
    • clone

      public OleObject clone()
      Creates a new object that is a deep copy of the current instance.
      Specified by:
      clone in interface IContentElement
      Specified by:
      clone in class FrameContentElement
      Returns:
      A new object that is a copy of this instance.
    • toString

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

      public String getFilter()
      Gets the filter name for an image. This attribute contains the internal filter name that an consumer has used to load the graphic.
      Returns:
      the filter
    • setFilter

      public void setFilter(String filter)
      Sets the filter name for an image. This attribute contains the internal filter name that an consumer has used to load the graphic.
      Parameters:
      filter - the new filter
    • getFileName

      public String getFileName()
      Gets the file name.
      Returns:
      the file name
    • setFileName

      public void setFileName(String fileName)
      Sets the file name.
      Parameters:
      fileName - the new file name
    • getBuffer

      public byte[] getBuffer()
      Gets the buffer.
      Returns:
      the buffer
    • setBuffer

      public void setBuffer(byte[] buffer)
      Sets the buffer.
      Parameters:
      buffer - the new buffer