33 #ifndef DART_COMMON_SUB_PTR_HPP_
34 #define DART_COMMON_SUB_PTR_HPP_
The Observer class should be inherited by any class that wants to respond in a customized way to the ...
Definition: Observer.hpp:52
The Subject class is a base class for any object that wants to report when it gets destroyed.
Definition: Subject.hpp:58
sub_ptr is a pointer to a Subject.
Definition: sub_ptr.hpp:47
T * operator->() const
Dereferencing operation.
Definition: sub_ptr.hpp:94
sub_ptr & operator=(const sub_ptr &_sp)
Change the Subject of this sub_ptr.
Definition: sub_ptr.hpp:64
Subject * mSubjectBase
Store the pointer to the virtual Subject base.
Definition: sub_ptr.hpp:90
void set(T *_ptr)
Set the subject of this sub_ptr.
Definition: sub_ptr.hpp:108
T * mT
Store the pointer to the full object.
Definition: sub_ptr.hpp:87
sub_ptr()
Default constructor.
Definition: sub_ptr.hpp:43
T * get() const
Get the Subject of this sub_ptr.
Definition: sub_ptr.hpp:101
void handleDestructionNotification(const Subject *_subject) override
Called by receiveDestructionNotification().
Definition: sub_ptr.hpp:128
T & operator*() const
Dereferencing operator.
Definition: sub_ptr.hpp:87
bool valid()
True if and only if this sub_ptr still points to a valid Subject.
Definition: sub_ptr.hpp:121
Definition: BulletCollisionDetector.cpp:65