All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
refPtrTracker.h File Reference
+ Include dependency graph for refPtrTracker.h:

Go to the source code of this file.

Classes

class  TfRefPtr< T >
 Reference-counted smart pointer utility class. More...
 
class  TfRefPtrTracker
 Provides tracking of TfRefPtr objects to particular objects. More...
 
struct  TfRefPtrTracker::Trace
 A track trace. More...
 

Macros

#define TF_DECLARE_REFPTR_TRACK(T)
 
#define TF_DEFINE_REFPTR_TRACK(T, COND)
 

Functions

 TF_API_TEMPLATE_CLASS (TfSingleton< TfRefPtrTracker >)
 

Class Documentation

struct TfRefPtrTracker::Trace

A track trace.

Definition at line 115 of file refPtrTracker.h.

Class Members
const TfRefBase * obj The object being pointed to.
vector< uintptr_t > trace The stack trace when the TfRefPtr was created or assigned to.
TraceType type Whether the TfRefPtr was created or assigned to.

Macro Definition Documentation

#define TF_DECLARE_REFPTR_TRACK (   T)
Value:
inline void Tf_RefPtrTracker_FirstRef(const void*, T* obj); \
inline void Tf_RefPtrTracker_LastRef(const void*, T* obj); \
inline void Tf_RefPtrTracker_New(const void* owner, T* obj); \
inline void Tf_RefPtrTracker_Delete(const void* owner, T* obj); \
inline void Tf_RefPtrTracker_Assign(const void* owner, T* obj, T* oldObj);

Definition at line 235 of file refPtrTracker.h.

#define TF_DEFINE_REFPTR_TRACK (   T,
  COND 
)
Value:
inline void Tf_RefPtrTracker_FirstRef(const void*, T* obj) { \
if (obj && COND(obj)) Tf_RefPtrTrackerUtil::Watch(obj); \
} \
inline void Tf_RefPtrTracker_LastRef(const void*, T* obj) { \
Tf_RefPtrTrackerUtil::Unwatch(obj); \
} \
inline void Tf_RefPtrTracker_New(const void* owner, T* obj) { \
Tf_RefPtrTrackerUtil::AddTrace(owner, obj); \
} \
inline void Tf_RefPtrTracker_Delete(const void* owner, T* obj) { \
Tf_RefPtrTrackerUtil::RemoveTraces(owner); \
} \
inline void Tf_RefPtrTracker_Assign(const void* owner, T* obj, T* oldObj) { \
if (oldObj != obj) { \
Tf_RefPtrTrackerUtil::AddTrace(owner, obj, TfRefPtrTracker::Assign);\
} \
}
void if(!TfPyIsInitialized())
Invokes wrapFunc to wrap type T if T is not already wrapped.
Definition: pyUtils.h:210

Definition at line 242 of file refPtrTracker.h.