|
My Project
|
The ref_ptr class template stores a pointer to a dynamically allocated (AssetEntity|CRefCounted|BaseAsset) derived object. More...
#include <PERefPtr.h>
Public Types | |
| typedef T | element_type |
| typedef T | value_type |
| typedef T * | pointer |
Public Member Functions | |
| template<class Y > | |
| ref_ptr (Y *p) | |
| ref_ptr (const ref_ptr &r) | |
| ref_ptr & | operator= (const ref_ptr &r) |
| template<class Y > | |
| ref_ptr & | operator= (Y *r) |
| T & | operator* () const |
| T * | operator-> () const |
| T * | get () const |
| operator bool () const | |
| bool | operator! () const |
| int | use_count () const |
| bool | unique () const |
| void | reset (T *r=0) |
Protected Attributes | |
| T * | px |
The ref_ptr class template stores a pointer to a dynamically allocated (AssetEntity|CRefCounted|BaseAsset) derived object.
Every ref_ptr meets the CopyConstructible and Assignable requirements of the C++ Standard Library, and so can be used in standard library containers. this is similar to boost::shared_ptr, except that it mainly works with AssetEntity. i.e. use in a class like this: ref_ptr<TextureEntity> p;
1.8.12