CFx SDK Documentation  2020SP3
Public Member Functions | List of all members
OdDbOsnapOverrule Class Reference

#include <DbEntityOverrule.h>

Inheritance diagram for OdDbOsnapOverrule:
OdRxOverrule OdRxObject

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdDbOsnapOverrule)
 
 OdDbOsnapOverrule ()
 
virtual OdResult getOsnapPoints (const OdDbEntity *pSubject, OdDb::OsnapMode osnapMode, OdGsMarker gsSelectionMark, const OdGePoint3d &pickPoint, const OdGePoint3d &lastPoint, const OdGeMatrix3d &xWorldToEye, OdGePoint3dArray &snapPoints)
 
virtual OdResult getOsnapPoints (const OdDbEntity *pSubject, OdDb::OsnapMode osnapMode, OdGsMarker gsSelectionMark, const OdGePoint3d &pickPoint, const OdGePoint3d &lastPoint, const OdGeMatrix3d &xWorldToEye, OdGePoint3dArray &snapPoints, const OdGeMatrix3d &insertionMat)
 
virtual bool isContentSnappable (const OdDbEntity *pSubject)
 
- Public Member Functions inherited from OdRxOverrule
 ODRX_DECLARE_MEMBERS (OdRxOverrule)
 
virtual ~OdRxOverrule ()
 
virtual bool isApplicable (const OdRxObject *pOverruledSubject) 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 OdRxOverrule
static OdResult addOverrule (OdRxClass *pClass, OdRxOverrule *pOverrule, bool bAddAtLast=false)
 
static OdResult removeOverrule (OdRxClass *pClass, OdRxOverrule *pOverrule)
 
static void setIsOverruling (bool bIsOverruling)
 
static bool isOverruling ()
 
static bool hasOverrule (const OdRxObject *pSubject, OdRxClass *pOverruleClass)
 
- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 

Detailed Description

This class overrules a subset of osnap linked operations which an entity specifies. It is used as a base class for classes derived from OdDbEntity to change their behavior. Each default implementation calls the corresponding method of the target class.

Corresponding C++ library: TD_Db <group OdDb_Classes>

Definition at line 38 of file DbEntityOverrule.h.

Constructor & Destructor Documentation

◆ OdDbOsnapOverrule()

OdDbOsnapOverrule::OdDbOsnapOverrule ( )

Constructor creates an instance of this class.

Member Function Documentation

◆ getOsnapPoints() [1/2]

virtual OdResult OdDbOsnapOverrule::getOsnapPoints ( const OdDbEntity pSubject,
OdDb::OsnapMode  osnapMode,
OdGsMarker  gsSelectionMark,
const OdGePoint3d pickPoint,
const OdGePoint3d lastPoint,
const OdGeMatrix3d xWorldToEye,
OdGePoint3dArray snapPoints 
)
virtual

Overrules the OdDbEntity::subGetOsnapPoints() method and calls it in the default implementation. This method returns eOk if successful.

Parameters
pSubject[in] A raw pointer to an entity.
osnapMode[in] Osnap mode to be requested.
gsSelectionMark[in] GS marker of the subentity involved in the snap operation.
pickPoint[in] WCS coordinates of the point picked during the snap operation.
lastPoint[in] WCS coordinates of the point selected just before pickPoint.
xWorldToEye[in] A transformation matrix to transform from WCS to DCS.
snapPoints[in] An existing array to append osnap points.

◆ getOsnapPoints() [2/2]

virtual OdResult OdDbOsnapOverrule::getOsnapPoints ( const OdDbEntity pSubject,
OdDb::OsnapMode  osnapMode,
OdGsMarker  gsSelectionMark,
const OdGePoint3d pickPoint,
const OdGePoint3d lastPoint,
const OdGeMatrix3d xWorldToEye,
OdGePoint3dArray snapPoints,
const OdGeMatrix3d insertionMat 
)
virtual

Overrules the OdDbEntity::subGetOsnapPoints() method and calls it in the default implementation. This method returns eOk if successful.

Parameters
pSubject[in] A raw pointer to an entity.
osnapMode[in] Osnap mode to be requested.
gsSelectionMark[in] GS marker of the subentity involved in the snap operation.
pickPoint[in] WCS coordinates of the point picked during the snap operation.
lastPoint[in] WCS coordinates of the point selected just before pickPoint.
xWorldToEye[in] A transformation matrix to transform from WCS to DCS.
snapPoints[in] An existing array to append osnap points.
insertionMat[in] A transformation matrix for block transformation.

◆ isContentSnappable()

virtual bool OdDbOsnapOverrule::isContentSnappable ( const OdDbEntity pSubject)
virtual

Returns True when it is a block entity which requires investigating the block definition, or False otherwise.

Remarks
The application can override this function to inform the host application: don't investigate the compounded objects that use a block definition for osnap points. This method is not called for objects that don't use a block definition in the worldDraw() implementation.
Parameters
pSubject[in] A raw pointer to an entity.

◆ ODRX_DECLARE_MEMBERS()

OdDbOsnapOverrule::ODRX_DECLARE_MEMBERS ( OdDbOsnapOverrule  )

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