FBX C++ API Reference
RefCount Class Reference

FbxSharedPtr class describes an object that stores a pointer to a single allocated object of type Type* that ensures that the object to which it points gets destroyed automatically when the control leaves a scope and the reference count is 0. More...

#include <fbxalloc.h>

Public Member Functions

 RefCount ()
 
 ~RefCount ()
 
void Init ()
 
void IncRef ()
 
int DecRef ()
 

Detailed Description

FbxSharedPtr class describes an object that stores a pointer to a single allocated object of type Type* that ensures that the object to which it points gets destroyed automatically when the control leaves a scope and the reference count is 0.

Definition at line 296 of file fbxalloc.h.

Constructor & Destructor Documentation

RefCount ( )
inline

Definition at line 299 of file fbxalloc.h.

299 { Init(); };
void Init()
Definition: fbxalloc.h:302
~RefCount ( )
inline

Definition at line 300 of file fbxalloc.h.

300 { Init(); };
void Init()
Definition: fbxalloc.h:302

Member Function Documentation

void Init ( )
inline

Definition at line 302 of file fbxalloc.h.

302 { count = 0; }
void IncRef ( )
inline

Definition at line 303 of file fbxalloc.h.

303 { count++; }
int DecRef ( )
inline

Definition at line 304 of file fbxalloc.h.

304 { count--; if (count < 0) count = 0; return count; }

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