Classes | Defines | Functions
opennurbs_object.h File Reference

Go to the source code of this file.

Classes

class  ON_ClassId
class  ON_Object
class  ON_UserString

Defines

#define ON__SET__THIS__PTR(ptr)   if (ptr) *((void**)this) = ptr
#define ON_CLASS_ID(cls)   ON_ClassId::ClassId( #cls )
#define ON_OBJECT_DECLARE(cls)
#define ON_OBJECT_IMPLEMENT(cls, basecls, uuid)
#define ON_VIRTUAL_OBJECT_IMPLEMENT(cls, basecls, uuid)

Functions

ON_DECL ON_UUID ON_GetMostRecentClassIdCreateUuid ()
ON_DECL bool ON_IsNotValid ()

Define Documentation

#define ON__SET__THIS__PTR (   ptr)    if (ptr) *((void**)this) = ptr

Definition at line 332 of file opennurbs_object.h.

#define ON_CLASS_ID (   cls)    ON_ClassId::ClassId( #cls )

Definition at line 235 of file opennurbs_object.h.

#define ON_OBJECT_DECLARE (   cls)
Value:
protected:                                                    \
    static void* m_s_##cls##_ptr;                               \
  public:                                                       \
    static const ON_ClassId m_##cls##_class_id;                 \
    /*record used for ON_Object runtime type information*/      \
                                                                \
    static cls * Cast( ON_Object* );                            \
    /*Description: Similar to C++ dynamic_cast*/                \
    /*Returns: object on success. NULL on failure*/             \
                                                                \
    static const cls * Cast( const ON_Object* );                \
    /*Description: Similar to C++ dynamic_cast*/                \
    /*Returns: object on success. NULL on failure*/             \
                                                                \
    virtual const ON_ClassId* ClassId() const;                  \
    /*Description:*/                                            \
                                                                \
  private:                                                      \
    virtual ON_Object* DuplicateObject() const;                 \
    /*used by Duplicate to create copy of an object.*/          \
                                                                \
    static bool Copy##cls( const ON_Object*, ON_Object* );      \
    /* used by ON_Object::CopyFrom copy object into this. */    \
    /* In V6 Copy##cls will vanish and be replaced with   */    \
    /* virtual bool CopyFrom( const ON_Object* src )      */    \
                                                                \
  public:                                                       \
    cls * Duplicate() const;                                    \
    /*Description: Expert level tool - no support available.*/  \
    /*If this class is derived from CRhinoObject, use CRhinoObject::DuplicateRhinoObject instead*/

Definition at line 266 of file opennurbs_object.h.

#define ON_OBJECT_IMPLEMENT (   cls,
  basecls,
  uuid 
)
Value:
void* cls::m_s_##cls##_ptr = 0;\
  static ON_Object* CreateNew##cls() {return new cls();} \
  const ON_ClassId cls::m_##cls##_class_id(#cls,#basecls,CreateNew##cls,cls::Copy##cls,uuid);\
  cls * cls::Cast( ON_Object* p) {return(cls *)Cast((const ON_Object*)p);} \
  const cls * cls::Cast( const ON_Object* p) {return(p&&p->IsKindOf(&cls::m_##cls##_class_id))?(const cls *)p:0;} \
  const ON_ClassId* cls::ClassId() const {return &cls::m_##cls##_class_id;} \
  ON_Object* cls::DuplicateObject() const {cls* p = new cls(); if (p) *p=*this; return p;} \
  bool cls::Copy##cls( const ON_Object* src, ON_Object* dst ){cls* d;const cls* s;if (0!=(s=cls::Cast(src))&&0!=(d=cls::Cast(dst))) {d->cls::operator=(*s);return true;}return false;} \
  cls * cls::Duplicate() const {return static_cast<cls *>(DuplicateObject());}

Definition at line 321 of file opennurbs_object.h.

#define ON_VIRTUAL_OBJECT_IMPLEMENT (   cls,
  basecls,
  uuid 
)
Value:
void* cls::m_s_##cls##_ptr = 0;\
  const ON_ClassId cls::m_##cls##_class_id(#cls,#basecls,0,0,uuid);\
  cls * cls::Cast( ON_Object* p) {return(cls *)Cast((const ON_Object*)p);} \
  const cls * cls::Cast( const ON_Object* p) {return(p&&p->IsKindOf(&cls::m_##cls##_class_id))?(const cls *)p:0;} \
  const ON_ClassId* cls::ClassId() const {return &cls::m_##cls##_class_id;} \
  ON_Object* cls::DuplicateObject() const {return 0;} \
  bool cls::Copy##cls( const ON_Object*, ON_Object* ) {return false;} \
  cls * cls::Duplicate() const {return static_cast<cls *>(DuplicateObject());}

Definition at line 306 of file opennurbs_object.h.


Function Documentation

Definition at line 870 of file opennurbs_object.cpp.

Definition at line 108 of file opennurbs_error.cpp.



pcl
Author(s): Open Perception
autogenerated on Wed Aug 26 2015 15:38:46