SpECTRE  v2025.08.19
Parallel::FifoCache< T >::Cached Struct Reference

Wrapper type used as the result from find to ensure correct thread safety. More...

#include <FifoCache.hpp>

Public Member Functions

 Cached (const stored_type *t)
 
 Cached (const std::nullopt_t)
 NOLINTNEXTLINE(google-explicit-constructor)
 
 Cached (const Cached &rhs)
 
Cachedoperator= (const Cached &rhs)
 
 Cached (Cached &&rhs) noexcept(true)
 
Cachedoperator= (Cached &&rhs) noexcept(true)
 
auto value () const -> const T &
 Returns a reference to the held object. More...
 
bool has_value () const
 Returns true if a value is stored, otherwise returns false.
 

Detailed Description

template<class T>
struct Parallel::FifoCache< T >::Cached

Wrapper type used as the result from find to ensure correct thread safety.

Use .value() to get the stored value.

Use .has_value() to check if a value is stored.

Member Function Documentation

◆ value()

template<class T >
auto Parallel::FifoCache< T >::Cached::value

Returns a reference to the held object.

Throws: std::runtime_error if no value


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