CFx SDK Documentation  2023 SP0
Public Types | Public Member Functions | List of all members
OdOleItemHandler Class Referenceabstract

#include <OleItemHandler.h>

Inheritance diagram for OdOleItemHandler:
OdGiSelfGdiDrawable OdRxObject OdOleItemHandlerBase OdOleItemSimplestHandler

Public Types

enum  Type { kUnknown = 0 , kLink = 1 , kEmbedded = 2 , kStatic = 3 }
 
enum  DvAspect { kContent = 1 , kThumbnail = 2 , kIcon = 4 , kDocPrint = 8 }
 
enum  PlotQuality { kMonochrome = 0 , kLowGraphics = 1 , kHighGraphics = 2 , kAutomatic = 3 }
 

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdOleItemHandler)
 
virtual void load (OdStreamBuf &streamBuf)=0
 
virtual void save (OdStreamBuf &streamBuf) const =0
 
virtual OdUInt32 getCompoundDocumentDataSize () const =0
 
virtual void getCompoundDocument (OdStreamBuf &streamBuf) const =0
 
virtual void setCompoundDocument (OdUInt32 numBytes, OdStreamBuf &streamBuf)=0
 
virtual Type type () const =0
 
virtual DvAspect drawAspect () const =0
 
virtual OdString linkName () const =0
 
virtual OdString linkPath () const =0
 
virtual OdString userType () const =0
 
virtual void setDrawAspect (DvAspect drawAspect)=0
 
virtual PlotQuality outputQuality () const =0
 
virtual void setOutputQuality (PlotQuality quality)=0
 
virtual COleClientItem * getOleClientItem (void) const =0
 
virtual bool embedRaster (OdSmartPtr< class OdGiRasterImage > pImage, OdRxObject *pRxDb=NULL)=0
 
virtual OdGiRasterImagePtr getRaster (bool bDisplayedOnly=true) const =0
 
- Public Member Functions inherited from OdGiSelfGdiDrawable
 ODRX_DECLARE_MEMBERS (OdGiSelfGdiDrawable)
 
virtual bool draw (const OdGiCommonDraw &drawObj, void *hdc, const OdGsDCRect &screenRect) const =0
 
- Public Member Functions inherited from OdRxObject
 ODRX_HEAP_OPERATORS ()
 
 OdRxObject ()
 
virtual ~OdRxObject ()
 
virtual OdRxObjectqueryX (const OdRxClass *pClass) const
 
virtual OdRxObjectx (const OdRxClass *pClass) const
 
virtual OdRxClassisA () const
 
virtual void addRef ()=0
 
virtual void release ()=0
 
virtual long numRefs () const
 
bool isKindOf (const OdRxClass *pClass) const
 
virtual OdRxObjectPtr clone () const
 
virtual void copyFrom (const OdRxObject *pSource)
 
virtual OdRx::Ordering comparedTo (const OdRxObject *pOther) const
 
virtual bool isEqualTo (const OdRxObject *pOther) const
 

Additional Inherited Members

- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 

Detailed Description

This class defines the interface for custom OLE handlers.

<group Other_Classes>

Definition at line 69 of file OleItemHandler.h.

Member Enumeration Documentation

◆ DvAspect

Enumerator
kContent 
kThumbnail 
kIcon 
kDocPrint 

Definition at line 137 of file OleItemHandler.h.

◆ PlotQuality

Enumerator
kMonochrome 
kLowGraphics 
kHighGraphics 
kAutomatic 

Definition at line 193 of file OleItemHandler.h.

◆ Type

Enumerator
kUnknown 
kLink 
kEmbedded 
kStatic 

Definition at line 114 of file OleItemHandler.h.

Member Function Documentation

◆ drawAspect()

virtual DvAspect OdOleItemHandler::drawAspect ( ) const
pure virtual

Returns the draw aspect of this OleItemHandler object.

Remarks
drawAspect() returns one of the following:

Value kContent 1 kThumbnail 2 kIcon 4 kDocPrint 8

Implemented in OdOleItemHandlerBase.

◆ embedRaster()

virtual bool OdOleItemHandler::embedRaster ( OdSmartPtr< class OdGiRasterImage pImage,
OdRxObject pRxDb = NULL 
)
pure virtual

Embeds a raster image to this OLE object.

Parameters
pImage[in] Pointer to a raster image.
pRxDb[in] Pointer to a database object.
Returns
Returns true if a raster image is successfully embedded to the OLE object, or returns false in the other case.

Implemented in OdOleItemHandlerBase.

◆ getCompoundDocument()

virtual void OdOleItemHandler::getCompoundDocument ( OdStreamBuf streamBuf) const
pure virtual

Writes the compound document data of this OleItemHandler object to the specified stream.

Parameters
streamBuf[out] StreamBuf object to which the data are to be written.

Implemented in OdOleItemSimplestHandler.

◆ getCompoundDocumentDataSize()

virtual OdUInt32 OdOleItemHandler::getCompoundDocumentDataSize ( ) const
pure virtual

Returns the data size (in bytes) of the compound document of this OleItemHandler object.

Implemented in OdOleItemSimplestHandler.

◆ getOleClientItem()

virtual COleClientItem* OdOleItemHandler::getOleClientItem ( void  ) const
pure virtual

Implemented in OdOleItemHandlerBase.

◆ getRaster()

virtual OdGiRasterImagePtr OdOleItemHandler::getRaster ( bool  bDisplayedOnly = true) const
pure virtual

Implemented in OdOleItemHandlerBase.

◆ linkName()

virtual OdString OdOleItemHandler::linkName ( ) const
pure virtual

Returns the link name of this OleItemHandler object.

Implemented in OdOleItemHandlerBase.

◆ linkPath()

virtual OdString OdOleItemHandler::linkPath ( ) const
pure virtual

Returns the link path of this OleItemHandler object.

Implemented in OdOleItemHandlerBase.

◆ load()

virtual void OdOleItemHandler::load ( OdStreamBuf streamBuf)
pure virtual

Reads the binary data for the OdDbOle2Frame of this OleItemHandler object from the specified stream.

Parameters
streamBuf[in] StreamBuf object from which the data are to be read.
Remarks
See MFC COleClientItem::Serialize(CArchive& ar) for details. Assume that ar.m_bForceFlat is TRUE.

Implemented in OdOleItemHandlerBase.

◆ ODRX_DECLARE_MEMBERS()

OdOleItemHandler::ODRX_DECLARE_MEMBERS ( OdOleItemHandler  )

◆ outputQuality()

virtual PlotQuality OdOleItemHandler::outputQuality ( ) const
pure virtual

Returns the output quality for this OLE object (DXF 73).

Remarks
Controls the color depth and resolution when plotted.

outputQuality() returns one of the following:

Value Example kMonochrome 0 Spreadsheet kLowGraphics 1 Color text & pie charts kHighGraphics 2 Photograph kAutomatic 3 Automatic dependent on document type

Implemented in OdOleItemHandlerBase.

◆ save()

virtual void OdOleItemHandler::save ( OdStreamBuf streamBuf) const
pure virtual

Writes the binary data for the OdDbOle2Frame of this OleItemHandler object to the specified stream.

Parameters
streamBuf[out] StreamBuf object to which the data are to be written.
Remarks
See MFC COleClientItem::Serialize(CArchive& ar) for details. Assume that ar.m_bForceFlat is TRUE.

Implemented in OdOleItemHandlerBase.

◆ setCompoundDocument()

virtual void OdOleItemHandler::setCompoundDocument ( OdUInt32  numBytes,
OdStreamBuf streamBuf 
)
pure virtual

Reads the compound document data of this OleItemHandler object from the specified stream.

Parameters
streamBuf[in] StreamBuf object from which the data are to be read.
numBytes[in] Number of bytes to be written.

Implemented in OdOleItemSimplestHandler.

◆ setDrawAspect()

virtual void OdOleItemHandler::setDrawAspect ( DvAspect  drawAspect)
pure virtual

Sets the draw aspect of this OleItemHandler object.

Parameters
drawAspect[in] Draw aspect.
Remarks
drawAspect must be one of the following:

Value kContent 1 kThumbnail 2 kIcon 4 kDocPrint 8

Implemented in OdOleItemHandlerBase.

◆ setOutputQuality()

virtual void OdOleItemHandler::setOutputQuality ( PlotQuality  quality)
pure virtual

Sets the output quality for this OLE object (DXF 73).

Parameters
quality[in] Output quality.
Remarks
Controls the color depth and resolution when plotted.

quality must be one of the following:

Value Example kMonochrome 0 Spreadsheet kLowGraphics 1 Color text & pie charts kHighGraphics 2 Photograph kAutomatic 3 Automatic dependent on document type

Implemented in OdOleItemHandlerBase.

◆ type()

virtual Type OdOleItemHandler::type ( ) const
pure virtual

Returns the type of the OdDbOleFrame of this OdOleItemHandler.

Remarks
type() returns one of the following:

Value kUnknown 0 kLink 1 kEmbedded 2 kStatic 3

Implemented in OdOleItemHandlerBase.

◆ userType()

virtual OdString OdOleItemHandler::userType ( ) const
pure virtual

Returns the user type of this OleItemHandler object.

Implemented in OdOleItemHandlerBase.


The documentation for this class was generated from the following file: