WeakRawPtr< TYPE >::WeakRawPtrProxy Struct Reference

#include <weakrawptr.h>

Detailed Description

template<typename TYPE>
struct maxon::WeakRawPtr< TYPE >::WeakRawPtrProxy

Proxy object: Locks the target object until the scope is left and ensures that the target is not released while you access it.

Note
Concurrent access to the target is still possible, the proxy just ensures that the memory block is stil allocated.

Public Member Functions

 WeakRawPtrProxy ()
 
 WeakRawPtrProxy (const WeakRefTargetBase &data, const void *t)
 
 ~WeakRawPtrProxy ()
 
TYPE * operator-> ()
 
 operator Bool () const
 

Public Attributes

const WeakRefTargetBase_data
 
TYPE * _target
 

Constructor & Destructor Documentation

◆ WeakRawPtrProxy() [1/2]

◆ WeakRawPtrProxy() [2/2]

WeakRawPtrProxy ( const WeakRefTargetBase data,
const void *  t 
)

◆ ~WeakRawPtrProxy()

Member Function Documentation

◆ operator->()

TYPE* operator-> ( )

◆ operator Bool()

operator Bool ( ) const
explicit

Member Data Documentation

◆ _data

const WeakRefTargetBase* _data

◆ _target

TYPE* _target