userver: utils::WithResourceScopes< Wrapped > Class Template Reference
Loading...
Searching...
No Matches
utils::WithResourceScopes< Wrapped > Class Template Referencefinal

#include <userver/utils/resource_scopes.hpp>

Detailed Description

template<typename Wrapped>
class utils::WithResourceScopes< Wrapped >

A wrapper that provides utils::ResourceScopeStorage for the wrapped object.

The wrapped object is passed utils::ResourceScopeStorage& as the first argument to the constructor.

Definition at line 130 of file resource_scopes.hpp.

Public Member Functions

template<typename... Args>
 WithResourceScopes (std::in_place_t, Args &&... args)
 Constructs the wrapped object and passes the embedded utils::ResourceScopeStorage to it as the first argument.
 
 WithResourceScopes (WithResourceScopes &&other) noexcept=default
 
WithResourceScopesoperator= (WithResourceScopes &&other) noexcept=default
 
Wrapped & operator* () &noexcept
 Returns the wrapped object.
 
const Wrapped & operator* () const &noexcept
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
Wrapped * operator-> () noexcept
 Returns the wrapped object.
 
const Wrapped * operator-> () const noexcept
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 

Constructor & Destructor Documentation

◆ WithResourceScopes()

template<typename Wrapped>
template<typename... Args>
utils::WithResourceScopes< Wrapped >::WithResourceScopes ( std::in_place_t ,
Args &&... args )
inlineexplicit

Constructs the wrapped object and passes the embedded utils::ResourceScopeStorage to it as the first argument.

Definition at line 135 of file resource_scopes.hpp.

◆ ~WithResourceScopes()

template<typename Wrapped>
utils::WithResourceScopes< Wrapped >::~WithResourceScopes ( )
inline

Definition at line 144 of file resource_scopes.hpp.

Member Function Documentation

◆ operator*() [1/2]

template<typename Wrapped>
Wrapped & utils::WithResourceScopes< Wrapped >::operator* ( ) &
inlinenoexcept

Returns the wrapped object.

Definition at line 147 of file resource_scopes.hpp.

◆ operator*() [2/2]

template<typename Wrapped>
const Wrapped & utils::WithResourceScopes< Wrapped >::operator* ( ) const &
inlinenoexcept

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 149 of file resource_scopes.hpp.

◆ operator->() [1/2]

template<typename Wrapped>
const Wrapped * utils::WithResourceScopes< Wrapped >::operator-> ( ) const
inlinenoexcept

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 154 of file resource_scopes.hpp.

◆ operator->() [2/2]

template<typename Wrapped>
Wrapped * utils::WithResourceScopes< Wrapped >::operator-> ( )
inlinenoexcept

Returns the wrapped object.

Definition at line 152 of file resource_scopes.hpp.


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