neoGFX
Cross-platform C++ app/game engine
Loading...
Searching...
No Matches
neolib::weak_ref_ptr< Interface > Class Template Reference

#include <reference_counted.hpp>

Inheritance diagram for neolib::weak_ref_ptr< Interface >:
neolib::i_weak_ref_ptr< abstract_t< Interface > > neolib::i_ref_ptr< Interface >

Public Types

typedef i_weak_ref_ptr< abstract_t< Interface > > abstract_type
 
typedef base_type::no_object no_object
 
typedef base_type::interface_not_found interface_not_found
 
typedef base_type::bad_release bad_release
 
typedef base_type::wrong_object wrong_object
 
- Public Types inherited from neolib::i_ref_ptr< Interface >
typedef self_type abstract_type
 

Public Member Functions

 weak_ref_ptr (Interface *aManagedPtr=nullptr) noexcept
 
 weak_ref_ptr (Interface &aManagedPtr) noexcept
 
 weak_ref_ptr (const weak_ref_ptr &aOther) noexcept
 
 weak_ref_ptr (const i_ref_ptr< abstract_t< Interface > > &aOther) noexcept
 
 weak_ref_ptr (i_discoverable &aDiscoverable)
 
 ~weak_ref_ptr ()
 
weak_ref_ptroperator= (weak_ref_ptr const &aOther)
 
weak_ref_ptroperator= (i_ref_ptr< abstract_t< Interface > > const &aOther)
 
weak_ref_ptroperator= (std::nullptr_t)
 
bool reference_counted () const noexcept override
 
int32_t use_count () const noexcept override
 
void reset () override
 
void reset (abstract_t< Interface > *aPtr) override
 
void reset (abstract_t< Interface > *, abstract_t< Interface > *aManagedPtr) override
 
void reset (abstract_t< Interface > *, abstract_t< Interface > *aManagedPtr, bool, bool) override
 
Interface * release () override
 
Interface * detach () override
 
bool valid () const noexcept override
 
bool managing () const noexcept override
 
bool expired () const noexcept override
 
Interface * ptr () const noexcept override
 
Interface * managed_ptr () const noexcept override
 
Interface * operator-> () const override
 
Interface & operator* () const override
 
- Public Member Functions inherited from neolib::i_ref_ptr< Interface >
virtual ~i_ref_ptr ()=default
 
virtual void reset (Interface *aPtr)=0
 
virtual void reset (Interface *aPtr, Interface *aManagedPtr)=0
 
virtual void reset (Interface *aPtr, Interface *aManagedPtr, bool aReferenceCounted, bool aAddRef)=0
 
i_ref_ptroperator= (const i_ref_ptr &aOther)
 
template<typename Interface2 >
i_ref_ptroperator= (const i_ref_ptr< Interface2 > &aOther)
 
 operator bool () const noexcept
 
bool operator== (std::nullptr_t) const noexcept
 
bool operator!= (std::nullptr_t) const noexcept
 
template<typename Interface2 >
bool operator== (const i_ref_ptr< Interface2 > &aOther) const noexcept
 
template<typename Interface2 >
bool operator!= (const i_ref_ptr< Interface2 > &aOther) const noexcept
 
template<typename Interface2 >
bool operator< (const i_ref_ptr< Interface2 > &aOther) const noexcept
 

Detailed Description

template<typename Interface>
class neolib::weak_ref_ptr< Interface >

Definition at line 452 of file reference_counted.hpp.

Member Typedef Documentation

◆ abstract_type

template<typename Interface >
typedef i_weak_ref_ptr<abstract_t<Interface> > neolib::weak_ref_ptr< Interface >::abstract_type

Definition at line 456 of file reference_counted.hpp.

◆ bad_release

template<typename Interface >
typedef base_type::bad_release neolib::weak_ref_ptr< Interface >::bad_release

Definition at line 459 of file reference_counted.hpp.

◆ interface_not_found

template<typename Interface >
typedef base_type::interface_not_found neolib::weak_ref_ptr< Interface >::interface_not_found

Definition at line 458 of file reference_counted.hpp.

◆ no_object

template<typename Interface >
typedef base_type::no_object neolib::weak_ref_ptr< Interface >::no_object

Definition at line 457 of file reference_counted.hpp.

◆ wrong_object

template<typename Interface >
typedef base_type::wrong_object neolib::weak_ref_ptr< Interface >::wrong_object

Definition at line 460 of file reference_counted.hpp.

Constructor & Destructor Documentation

◆ weak_ref_ptr() [1/5]

template<typename Interface >
neolib::weak_ref_ptr< Interface >::weak_ref_ptr ( Interface *  aManagedPtr = nullptr)
inlinenoexcept

Definition at line 462 of file reference_counted.hpp.

◆ weak_ref_ptr() [2/5]

template<typename Interface >
neolib::weak_ref_ptr< Interface >::weak_ref_ptr ( Interface &  aManagedPtr)
inlinenoexcept

Definition at line 467 of file reference_counted.hpp.

◆ weak_ref_ptr() [3/5]

template<typename Interface >
neolib::weak_ref_ptr< Interface >::weak_ref_ptr ( const weak_ref_ptr< Interface > &  aOther)
inlinenoexcept

Definition at line 472 of file reference_counted.hpp.

◆ weak_ref_ptr() [4/5]

template<typename Interface >
neolib::weak_ref_ptr< Interface >::weak_ref_ptr ( const i_ref_ptr< abstract_t< Interface > > &  aOther)
inlinenoexcept

Definition at line 477 of file reference_counted.hpp.

◆ weak_ref_ptr() [5/5]

template<typename Interface >
neolib::weak_ref_ptr< Interface >::weak_ref_ptr ( i_discoverable aDiscoverable)
inline

Definition at line 482 of file reference_counted.hpp.

◆ ~weak_ref_ptr()

template<typename Interface >
neolib::weak_ref_ptr< Interface >::~weak_ref_ptr ( )
inline

Definition at line 488 of file reference_counted.hpp.

Member Function Documentation

◆ detach()

template<typename Interface >
Interface * neolib::weak_ref_ptr< Interface >::detach ( )
inlineoverridevirtual

Implements neolib::i_ref_ptr< Interface >.

Definition at line 544 of file reference_counted.hpp.

◆ expired()

template<typename Interface >
bool neolib::weak_ref_ptr< Interface >::expired ( ) const
inlineoverridevirtualnoexcept

◆ managed_ptr()

template<typename Interface >
Interface * neolib::weak_ref_ptr< Interface >::managed_ptr ( ) const
inlineoverridevirtualnoexcept

Implements neolib::i_ref_ptr< Interface >.

Definition at line 566 of file reference_counted.hpp.

◆ managing()

template<typename Interface >
bool neolib::weak_ref_ptr< Interface >::managing ( ) const
inlineoverridevirtualnoexcept

Implements neolib::i_ref_ptr< Interface >.

Definition at line 554 of file reference_counted.hpp.

◆ operator*()

template<typename Interface >
Interface & neolib::weak_ref_ptr< Interface >::operator* ( ) const
inlineoverridevirtual

Implements neolib::i_ref_ptr< Interface >.

Definition at line 576 of file reference_counted.hpp.

◆ operator->()

template<typename Interface >
Interface * neolib::weak_ref_ptr< Interface >::operator-> ( ) const
inlineoverridevirtual

Implements neolib::i_ref_ptr< Interface >.

Definition at line 570 of file reference_counted.hpp.

◆ operator=() [1/3]

template<typename Interface >
weak_ref_ptr & neolib::weak_ref_ptr< Interface >::operator= ( i_ref_ptr< abstract_t< Interface > > const aOther)
inline

Definition at line 498 of file reference_counted.hpp.

◆ operator=() [2/3]

template<typename Interface >
weak_ref_ptr & neolib::weak_ref_ptr< Interface >::operator= ( std::nullptr_t  )
inline

Definition at line 503 of file reference_counted.hpp.

◆ operator=() [3/3]

template<typename Interface >
weak_ref_ptr & neolib::weak_ref_ptr< Interface >::operator= ( weak_ref_ptr< Interface > const aOther)
inline

Definition at line 493 of file reference_counted.hpp.

◆ ptr()

template<typename Interface >
Interface * neolib::weak_ref_ptr< Interface >::ptr ( ) const
inlineoverridevirtualnoexcept

Implements neolib::i_ref_ptr< Interface >.

Definition at line 562 of file reference_counted.hpp.

◆ reference_counted()

template<typename Interface >
bool neolib::weak_ref_ptr< Interface >::reference_counted ( ) const
inlineoverridevirtualnoexcept

Implements neolib::i_ref_ptr< Interface >.

Definition at line 509 of file reference_counted.hpp.

◆ release()

template<typename Interface >
Interface * neolib::weak_ref_ptr< Interface >::release ( )
inlineoverridevirtual

Implements neolib::i_ref_ptr< Interface >.

Definition at line 537 of file reference_counted.hpp.

◆ reset() [1/4]

template<typename Interface >
void neolib::weak_ref_ptr< Interface >::reset ( )
inlineoverridevirtual

Implements neolib::i_ref_ptr< Interface >.

Definition at line 517 of file reference_counted.hpp.

◆ reset() [2/4]

template<typename Interface >
void neolib::weak_ref_ptr< Interface >::reset ( abstract_t< Interface > *  ,
abstract_t< Interface > *  aManagedPtr 
)
inlineoverride

Definition at line 527 of file reference_counted.hpp.

◆ reset() [3/4]

template<typename Interface >
void neolib::weak_ref_ptr< Interface >::reset ( abstract_t< Interface > *  ,
abstract_t< Interface > *  aManagedPtr,
bool  ,
bool   
)
inlineoverride

Definition at line 532 of file reference_counted.hpp.

◆ reset() [4/4]

template<typename Interface >
void neolib::weak_ref_ptr< Interface >::reset ( abstract_t< Interface > *  aPtr)
inlineoverride

Definition at line 522 of file reference_counted.hpp.

◆ use_count()

template<typename Interface >
int32_t neolib::weak_ref_ptr< Interface >::use_count ( ) const
inlineoverridevirtualnoexcept

Implements neolib::i_ref_ptr< Interface >.

Definition at line 513 of file reference_counted.hpp.

◆ valid()

template<typename Interface >
bool neolib::weak_ref_ptr< Interface >::valid ( ) const
inlineoverridevirtualnoexcept

Implements neolib::i_ref_ptr< Interface >.

Definition at line 550 of file reference_counted.hpp.


The documentation for this class was generated from the following file: