#include <ref.h>

Operations:
Assigning ptr to ref: ref = ptr OR ref.Set(ptr)
Invalidating: ref = NULL OR ref.Invalidate() OR ref.Set(NULL)
Checking if pointer is valid (non-null): ref.IsValid()
Public Member Functions | |
| Ref () | |
| Ref (TYPE *o) | |
| Ref (const Ref< TYPE > &rhs) | |
| ~Ref () | |
| Ref & | operator= (TYPE *obj) |
| Ref & | operator= (const Ref< TYPE > &rhs) |
| bool | operator== (const Ref< TYPE > &rhs) |
| bool | operator!= (const Ref< TYPE > &rhs) |
| bool | operator== (TYPE *obj) |
| bool | operator!= (TYPE *obj) |
| TYPE * | operator-> () const |
| TYPE & | operator * () const |
| operator TYPE * () const | |
| bool | IsValid () const |
| void | Invalidate () |
| void | Set (TYPE *obj) |
| TYPE * | Get () const |
| TYPE * | GetUnsafe () const |
Protected Attributes | |
| TYPE * | target_object |
Constructor with target object.
| obj | Pointer to target object. |
Copy constructor.
| ref | Reference to object. |
Assigns TYPE pointer.
Copy operator.
Equality operator.
Inequality operator.
| bool Ref< TYPE >::operator== | ( | TYPE * | obj | ) | [inline] |
Equality operator.
| bool Ref< TYPE >::operator!= | ( | TYPE * | obj | ) | [inline] |
Inequality operator.
| TYPE * Ref< TYPE >::operator-> | ( | ) | const [inline] |
Overrides -> operator.
| TYPE & Ref< TYPE >::operator * | ( | ) | const [inline] |
Dereferences operator.
| Ref< TYPE >::operator TYPE * | ( | ) | const [inline] |
Cast operator.
| bool Ref< TYPE >::IsValid | ( | void | ) | const [inline] |
Checks if target object exists.
True if pointer is still valid. | void Ref< TYPE >::Invalidate | ( | ) | [inline] |
Invalidate the reference.
| void Ref< TYPE >::Set | ( | TYPE * | obj | ) | [inline] |
Set target object.
| obj | Pointer to target object. |
| TYPE * Ref< TYPE >::Get | ( | ) | const [inline] |
Gets target object (safe).
| TYPE * Ref< TYPE >::GetUnsafe | ( | ) | const [inline] |
Gets target object (unsafe, may return NULL).
TYPE* Ref< TYPE >::target_object [protected] |
1.5.3