OSVR-Core
|
Holds on to smart pointers by value, and lets you free them by providing the corresponding void *. More...
#include <KeyedOwnershipContainer.h>
Public Member Functions | |
template<typename T > | |
void * | acquire (T ptr) |
Adds an object held by a smart pointer to our ownership, returning its void * usable to release it before the destruction of this object. More... | |
bool | release (void *ptr) |
Releases the indicated smart pointer in our ownership, if we have it. More... | |
Holds on to smart pointers by value, and lets you free them by providing the corresponding void *.
|
inline |
Adds an object held by a smart pointer to our ownership, returning its void * usable to release it before the destruction of this object.
|
inline |
Releases the indicated smart pointer in our ownership, if we have it.
Note that this just releases the smart pointer object that we have - the underlying memory may not be freed if your smart pointer is still referenced elsewhere, for instance.