Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.poi.hssf.usermodel
Class HSSFObjectData

    java.lang.Object
      org.apache.poi.hssf.usermodel.HSSFObjectData

    public final class HSSFObjectData

extends java.lang.Object

Represents binary object (i.e. OLE) data stored in the file. Eg. A GIF, JPEG etc...

Author:
  Daniel Noll

Constructor Summary
`HSSFObjectData(ObjRecord record, DirectoryEntry root)` Constructs object data by wrapping a lower level object record.

Method Summary
`DirectoryEntry` | `getDirectory()` Gets the object data.
`byte[]` | `getObjectData()` Returns the data portion, for an ObjectData that doesn't have an associated POIFS Directory Entry
`java.lang.String` | `getOLE2ClassName()` Returns the OLE2 Class Name of the object
`boolean` | `hasDirectoryEntry()` Does this ObjectData have an associated POIFS Directory Entry? (Not all do, those that don't have a data portion)

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### HSSFObjectData

    public HSSFObjectData(ObjRecord record,
                          DirectoryEntry root)

  Constructs object data by wrapping a lower level object record.

  Parameters:
    `record` - the low-level object record.
    `root` - the root of the filesystem, required for retrieving the object data.

Method Detail

### getOLE2ClassName

    public java.lang.String getOLE2ClassName()

  Returns the OLE2 Class Name of the object

### getDirectory

    public DirectoryEntry getDirectory()
                                throws java.io.IOException

  Gets the object data. Only call for ones that have data though. See `hasDirectoryEntry()`

  Returns:
    the object data as an OLE2 directory.
  Throws:
    `java.io.IOException` - if there was an error reading the data.

### getObjectData

    public byte[] getObjectData()

  Returns the data portion, for an ObjectData that doesn't have an associated POIFS Directory Entry

### hasDirectoryEntry

    public boolean hasDirectoryEntry()

  Does this ObjectData have an associated POIFS Directory Entry? (Not all do, those that don't have a data portion)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD