Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
duckdb::weak_ptr< T, SAFE > Class Template Reference

Public Types

using original = std::weak_ptr< T >
 
using element_type = typename original::element_type
 

Public Member Functions

template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
 weak_ptr (shared_ptr< U, SAFE > const &ptr) noexcept
 
 weak_ptr (weak_ptr const &other) noexcept
 
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
 weak_ptr (weak_ptr< U > const &ptr) noexcept
 
 weak_ptr (weak_ptr &&ptr) noexcept
 
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
 weak_ptr (weak_ptr< U > &&ptr) noexcept
 
weak_ptroperator= (const weak_ptr &other)
 
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
weak_ptroperator= (const shared_ptr< U, SAFE > &ptr)
 
void reset ()
 
long use_count () const
 
bool expired () const
 
shared_ptr< T, SAFElock () const
 
template<typename U >
bool operator== (const weak_ptr< U > &other) const noexcept
 
template<typename U >
bool operator!= (const weak_ptr< U > &other) const noexcept
 
template<typename U >
bool operator< (const weak_ptr< U > &other) const noexcept
 
template<typename U >
bool operator<= (const weak_ptr< U > &other) const noexcept
 
template<typename U >
bool operator> (const weak_ptr< U > &other) const noexcept
 
template<typename U >
bool operator>= (const weak_ptr< U > &other) const noexcept
 

Private Attributes

original internal
 

Friends

template<class U , bool SAFE_P>
class shared_ptr
 

Constructor & Destructor Documentation

◆ weak_ptr() [1/6]

template<typename T , bool SAFE>
duckdb::weak_ptr< T, SAFE >::weak_ptr ( )
inline
1800 : internal() {
1801 }

◆ weak_ptr() [2/6]

template<typename T , bool SAFE>
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
duckdb::weak_ptr< T, SAFE >::weak_ptr ( shared_ptr< U, SAFE > const ptr)
inlinenoexcept
1805 : internal(ptr.internal) {
1806 }

◆ weak_ptr() [3/6]

template<typename T , bool SAFE>
duckdb::weak_ptr< T, SAFE >::weak_ptr ( weak_ptr< T, SAFE > const other)
inlinenoexcept
1807 : internal(other.internal) {
1808 }

◆ weak_ptr() [4/6]

template<typename T , bool SAFE>
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
duckdb::weak_ptr< T, SAFE >::weak_ptr ( weak_ptr< U > const ptr)
inlinenoexcept
1810 : internal(ptr.internal) {
1811 }

◆ weak_ptr() [5/6]

template<typename T , bool SAFE>
duckdb::weak_ptr< T, SAFE >::weak_ptr ( weak_ptr< T, SAFE > &&  ptr)
inlinenoexcept
1816 : internal(std::move(ptr.internal)) {
1817 }

◆ weak_ptr() [6/6]

template<typename T , bool SAFE>
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
duckdb::weak_ptr< T, SAFE >::weak_ptr ( weak_ptr< U > &&  ptr)
inlinenoexcept
1823 : internal(std::move(ptr.internal)) {
1824 }

Member Function Documentation

◆ operator=() [1/2]

template<typename T , bool SAFE>
weak_ptr & duckdb::weak_ptr< T, SAFE >::operator= ( const weak_ptr< T, SAFE > &  other)
inline
1830 {
1831 if (this == &other) {
1832 return *this;
1833 }
1834 internal = other.internal;
1835 return *this;
1836 }

◆ operator=() [2/2]

template<typename T , bool SAFE>
template<class U , typename std::enable_if< compatible_with_t< U, T >::value, int >::type = 0>
weak_ptr & duckdb::weak_ptr< T, SAFE >::operator= ( const shared_ptr< U, SAFE > &  ptr)
inline
1839 {
1840 internal = ptr.internal;
1841 return *this;
1842 }

◆ reset()

template<typename T , bool SAFE>
void duckdb::weak_ptr< T, SAFE >::reset ( )
inline
1850 { // NOLINT: invalid case style
1851 internal.reset();
1852 }

◆ use_count()

template<typename T , bool SAFE>
long duckdb::weak_ptr< T, SAFE >::use_count ( ) const
inline
1855 { // NOLINT: invalid case style
1856 return internal.use_count();
1857 }

◆ expired()

template<typename T , bool SAFE>
bool duckdb::weak_ptr< T, SAFE >::expired ( ) const
inline
1859 { // NOLINT: invalid case style
1860 return internal.expired();
1861 }

◆ lock()

template<typename T , bool SAFE>
shared_ptr< T, SAFE > duckdb::weak_ptr< T, SAFE >::lock ( ) const
inline
1863 { // NOLINT: invalid case style
1864 return shared_ptr<T, SAFE>(internal.lock());
1865 }

◆ operator==()

template<typename T , bool SAFE>
template<typename U >
bool duckdb::weak_ptr< T, SAFE >::operator== ( const weak_ptr< U > &  other) const
inlinenoexcept
1869 {
1870 return internal == other.internal;
1871 }

◆ operator!=()

template<typename T , bool SAFE>
template<typename U >
bool duckdb::weak_ptr< T, SAFE >::operator!= ( const weak_ptr< U > &  other) const
inlinenoexcept
1874 {
1875 return internal != other.internal;
1876 }

◆ operator<()

template<typename T , bool SAFE>
template<typename U >
bool duckdb::weak_ptr< T, SAFE >::operator< ( const weak_ptr< U > &  other) const
inlinenoexcept
1879 {
1880 return internal < other.internal;
1881 }

◆ operator<=()

template<typename T , bool SAFE>
template<typename U >
bool duckdb::weak_ptr< T, SAFE >::operator<= ( const weak_ptr< U > &  other) const
inlinenoexcept
1884 {
1885 return internal <= other.internal;
1886 }

◆ operator>()

template<typename T , bool SAFE>
template<typename U >
bool duckdb::weak_ptr< T, SAFE >::operator> ( const weak_ptr< U > &  other) const
inlinenoexcept
1889 {
1890 return internal > other.internal;
1891 }

◆ operator>=()

template<typename T , bool SAFE>
template<typename U >
bool duckdb::weak_ptr< T, SAFE >::operator>= ( const weak_ptr< U > &  other) const
inlinenoexcept
1894 {
1895 return internal >= other.internal;
1896 }

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