gem5  v20.1.0.0
Public Member Functions | Protected Types | Protected Member Functions | List of all members
ProxyPtr< T, Proxy > Class Template Reference

#include <proxy_ptr.hh>

Inheritance diagram for ProxyPtr< T, Proxy >:
ConstProxyPtr< T, Proxy >

Public Member Functions

template<typename ... Args, typename std::enable_if< std::is_constructible< Proxy, Args &&... >::value, int >::type = 0>
 ProxyPtr (Addr _ptr, Args &&... args)
 
template<typename ... Args, typename std::enable_if< std::is_constructible< Proxy, Args &&... >::value, int >::type = 0>
 ProxyPtr (Args &&... args)
 
template<typename O , typename Enabled = typename std::enable_if<std::is_assignable<T *, O *>::value>::type>
 ProxyPtr (const ProxyPtr< O, Proxy > &other)
 
 ProxyPtr (const PP &other)
 
 operator bool () const
 
void flush (bool force=false)
 
template<typename A >
std::enable_if< std::is_integral< A >::value, PP >::type operator+ (A a) const
 
template<typename A >
std::enable_if< std::is_integral< A >::value, PP >::type operator- (A a) const
 
ptrdiff_t operator- (const PP &other) const
 
PPoperator= (const PP &other)
 
PPoperator= (const Addr &a)
 
 operator T* () const
 
T & operator* () const
 
T * operator-> () const
 
- Public Member Functions inherited from ConstProxyPtr< T, Proxy >
template<typename ... Args, typename std::enable_if< std::is_constructible< Proxy, Args &&... >::value, int >::type = 0>
 ConstProxyPtr (Addr _ptr, Args &&... args)
 
template<typename ... Args, typename std::enable_if< std::is_constructible< Proxy, Args &&... >::value, int >::type = 0>
 ConstProxyPtr (Args &&... args)
 
template<typename O , typename Enabled = typename std::enable_if<std::is_assignable<T *, O *>::value>::type>
 ConstProxyPtr (const ConstProxyPtr< O, Proxy > &other)
 
 ConstProxyPtr (const CPP &other)
 
void load ()
 
Addr addr () const
 
 operator bool () const
 
template<typename A >
std::enable_if< std::is_integral< A >::value, CPP >::type operator+ (A a) const
 
template<typename A >
std::enable_if< std::is_integral< A >::value, CPP >::type operator- (A a) const
 
ptrdiff_t operator- (const CPP &other) const
 
CPPoperator= (const CPP &other)
 
CPPoperator= (const Addr &a)
 
 operator const T * () const
 
const T & operator* () const
 
const T * operator-> () const
 

Protected Types

using CPP = ConstProxyPtr< T, Proxy >
 
using PP = ProxyPtr< T, Proxy >
 
- Protected Types inherited from ConstProxyPtr< T, Proxy >
using CPP = ConstProxyPtr< T, Proxy >
 

Protected Member Functions

 ProxyPtr (Addr _ptr, std::shared_ptr< Proxy > _proxy)
 
- Protected Member Functions inherited from ConstProxyPtr< T, Proxy >
void nullCheck () const
 
void setAddr (Addr ptr)
 
 ConstProxyPtr (Addr _ptr, std::shared_ptr< Proxy > _proxy)
 

Additional Inherited Members

- Public Types inherited from ConstProxyPtr< T, Proxy >
using Type = T
 
- Protected Attributes inherited from ConstProxyPtr< T, Proxy >
std::shared_ptr< Proxy > proxy
 
std::shared_ptr< ProxyPtrBuffer< Proxy > > buffer
 

Detailed Description

template<typename T, typename Proxy>
class ProxyPtr< T, Proxy >

Definition at line 236 of file proxy_ptr.hh.

Member Typedef Documentation

◆ CPP

template<typename T , typename Proxy >
using ProxyPtr< T, Proxy >::CPP = ConstProxyPtr<T, Proxy>
protected

Definition at line 239 of file proxy_ptr.hh.

◆ PP

template<typename T , typename Proxy >
using ProxyPtr< T, Proxy >::PP = ProxyPtr<T, Proxy>
protected

Definition at line 240 of file proxy_ptr.hh.

Constructor & Destructor Documentation

◆ ProxyPtr() [1/5]

template<typename T , typename Proxy >
ProxyPtr< T, Proxy >::ProxyPtr ( Addr  _ptr,
std::shared_ptr< Proxy >  _proxy 
)
inlineprotected

Definition at line 242 of file proxy_ptr.hh.

◆ ProxyPtr() [2/5]

template<typename T , typename Proxy >
template<typename ... Args, typename std::enable_if< std::is_constructible< Proxy, Args &&... >::value, int >::type = 0>
ProxyPtr< T, Proxy >::ProxyPtr ( Addr  _ptr,
Args &&...  args 
)
inlineexplicit

Definition at line 248 of file proxy_ptr.hh.

◆ ProxyPtr() [3/5]

template<typename T , typename Proxy >
template<typename ... Args, typename std::enable_if< std::is_constructible< Proxy, Args &&... >::value, int >::type = 0>
ProxyPtr< T, Proxy >::ProxyPtr ( Args &&...  args)
inlineexplicit

Definition at line 252 of file proxy_ptr.hh.

◆ ProxyPtr() [4/5]

template<typename T , typename Proxy >
template<typename O , typename Enabled = typename std::enable_if<std::is_assignable<T *, O *>::value>::type>
ProxyPtr< T, Proxy >::ProxyPtr ( const ProxyPtr< O, Proxy > &  other)
inline

Definition at line 256 of file proxy_ptr.hh.

◆ ProxyPtr() [5/5]

template<typename T , typename Proxy >
ProxyPtr< T, Proxy >::ProxyPtr ( const PP other)
inline

Definition at line 258 of file proxy_ptr.hh.

Member Function Documentation

◆ flush()

template<typename T , typename Proxy >
void ProxyPtr< T, Proxy >::flush ( bool  force = false)
inline

Definition at line 262 of file proxy_ptr.hh.

References ConstProxyPtr< T, Proxy >::buffer, and ConstProxyPtr< T, Proxy >::nullCheck().

Referenced by TEST().

◆ operator bool()

template<typename T , typename Proxy >
ProxyPtr< T, Proxy >::operator bool ( ) const
inline

Definition at line 259 of file proxy_ptr.hh.

References ConstProxyPtr< T, Proxy >::buffer.

◆ operator T*()

template<typename T , typename Proxy >
ProxyPtr< T, Proxy >::operator T* ( ) const
inline

Definition at line 304 of file proxy_ptr.hh.

References ConstProxyPtr< T, Proxy >::buffer.

◆ operator*()

template<typename T , typename Proxy >
T& ProxyPtr< T, Proxy >::operator* ( ) const
inline

◆ operator+()

template<typename T , typename Proxy >
template<typename A >
std::enable_if<std::is_integral<A>::value, PP>::type ProxyPtr< T, Proxy >::operator+ ( a) const
inline

◆ operator-() [1/2]

template<typename T , typename Proxy >
template<typename A >
std::enable_if<std::is_integral<A>::value, PP>::type ProxyPtr< T, Proxy >::operator- ( a) const
inline

◆ operator-() [2/2]

template<typename T , typename Proxy >
ptrdiff_t ProxyPtr< T, Proxy >::operator- ( const PP other) const
inline

Definition at line 283 of file proxy_ptr.hh.

References ConstProxyPtr< T, Proxy >::addr().

◆ operator->()

template<typename T , typename Proxy >
T* ProxyPtr< T, Proxy >::operator-> ( ) const
inline

◆ operator=() [1/2]

template<typename T , typename Proxy >
PP& ProxyPtr< T, Proxy >::operator= ( const Addr a)
inline

Definition at line 297 of file proxy_ptr.hh.

References ConstProxyPtr< T, Proxy >::setAddr().

◆ operator=() [2/2]

template<typename T , typename Proxy >
PP& ProxyPtr< T, Proxy >::operator= ( const PP other)
inline

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

Generated on Wed Sep 30 2020 14:02:29 for gem5 by doxygen 1.8.17