Panda3D
|
This is similar to PointerToBase, but it manages objects of type NodeReferenceCount or NodeCachedReferenceCount, and it updates the node_ref_count instead of the regular ref_count. More...
#include "nodePointerToBase.h"
Public Types | |
typedef T | To |
Public Member Functions | |
void | clear () |
A convenient way to set the NodePointerTo object to NULL. | |
size_t | get_hash () const |
bool | is_null () const |
Returns true if the PointerTo is a NULL pointer, false otherwise. | |
void | operator delete (void *ptr) |
void | operator delete (void *ptr, void *) |
void | operator delete[] (void *, void *) |
void | operator delete[] (void *ptr) |
void * | operator new (size_t size) |
void * | operator new (size_t size, void *ptr) |
void * | operator new[] (size_t size, void *ptr) |
void * | operator new[] (size_t size) |
bool | operator!= (const PointerToVoid &other) const |
bool | operator< (const void *other) const |
bool | operator< (const PointerToVoid &other) const |
bool | operator== (const PointerToVoid &other) const |
void | output (ostream &out) const |
A handy function to output NodePointerTo's as a hex pointer followed by a reference count. | |
Protected Member Functions | |
NodePointerToBase (To *ptr) | |
NodePointerToBase (const NodePointerToBase< T > ©) | |
void | reassign (To *ptr) |
This is the main work of the NodePointerTo family. | |
void | reassign (const NodePointerToBase< To > ©) |
Protected Attributes | |
void * | _void_ptr |
This is similar to PointerToBase, but it manages objects of type NodeReferenceCount or NodeCachedReferenceCount, and it updates the node_ref_count instead of the regular ref_count.
It is intended for use only in PandaNode, to hold a pointer to RenderState and TransformState, although it could be used by any object that wanted to maintain a separate reference count for reporting purposes.
Definition at line 36 of file nodePointerToBase.h.
void NodePointerToBase< T >::clear | ( | ) | [inline] |
A convenient way to set the NodePointerTo object to NULL.
(Assignment to a NULL pointer also works, of course.)
Definition at line 113 of file nodePointerToBase.I.
bool PointerToVoid::is_null | ( | ) | const [inline, inherited] |
Returns true if the PointerTo is a NULL pointer, false otherwise.
(Direct comparison to a NULL pointer also works.)
Reimplemented in PointerTo< T >, ThreadSafePointerTo< T >, and WeakConstPointerTo< T >.
Definition at line 54 of file pointerToVoid.I.
Referenced by TexturePeeker::is_valid().
void NodePointerToBase< T >::output | ( | ostream & | out | ) | const [inline] |
A handy function to output NodePointerTo's as a hex pointer followed by a reference count.
Definition at line 125 of file nodePointerToBase.I.
void NodePointerToBase< T >::reassign | ( | To * | ptr | ) | [protected] |
This is the main work of the NodePointerTo family.
When the pointer is reassigned, decrement the old reference count and increment the new one.
Definition at line 58 of file nodePointerToBase.I.
References TypeHandle::none().