Package com.independentsoft.office.odf.drawing

# 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.

- ## Field Summary

  ### Fields inherited from class com.independentsoft.office.odf.drawing.FrameContentElement

  `parent`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `OleObject()`
  Instantiates a new ole object.
  `OleObject​(InternalXMLStreamReader reader)`
  Instantiates a new ole object.
  `OleObject​(String filePath)`
  Instantiates a new ole object.
  `OleObject​(String fileName, byte[] buffer)`
  Instantiates a new ole object.
  `OleObject​(String fileName, InputStream inputStream)`
  Instantiates a new ole object.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `OleObject`
  `clone()`
  Creates a new object that is a deep copy of the current instance.
  `byte[]`
  `getBuffer()`
  Gets the buffer.
  `List<IContentElement>`
  `getContentElements()`
  Returns all content elements.
  `String`
  `getFileName()`
  Gets the file name.
  `String`
  `getFilter()`
  Gets the filter name for an image.
  `InputStream`
  `getInputStream()`
  Gets the input stream.
  `IContentElement`
  `getParent()`
  Returns the parent content element.
  `void`
  `load​(String filePath)`
  Load.
  `void`
  `load​(String fileName, byte[] buffer)`
  Load.
  `void`
  `load​(String fileName, InputStream inputStream)`
  Load.
  `void`
  `save​(OutputStream outputStream)`
  Save.
  `void`
  `save​(String filePath)`
  Save.
  `void`
  `save​(String filePath, boolean overwrite)`
  Save.
  `void`
  `setBuffer​(byte[] buffer)`
  Sets the buffer.
  `void`
  `setFileName​(String fileName)`
  Sets the file name.
  `void`
  `setFilter​(String filter)`
  Sets the filter name for an image.
  `void`
  `setParent​(IContentElement parent)`
  Sets the parent content element.
  `String`
  `toString()`
  Converts the value of the current OleObject object to its equivalent string representation.

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

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

- ## 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