Customization point object type for accessing the state
of a particle.
More...
#include <primitives.hpp>
Public Member Functions | |
template<class T , std::enable_if_t< std::conjunction_v< has_member_variable_state< T >, std::negation< has_member_state< T >>, std::negation< has_non_member_state< T >>>, int > = 0> | |
constexpr decltype(auto) | operator() (T &&t) const noexcept |
Overload for when the particle type defines a member variable. More... | |
template<class T , std::enable_if_t< std::conjunction_v< std::negation< has_member_variable_state< T >>, std::negation< has_member_state< T >>, has_non_member_state< T >>, int > = 0> | |
constexpr decltype(auto) | operator() (T &&t) const noexcept(noexcept(state(std::forward< T >(t)))) |
Overload for when there is an external function that takes this particle type. More... | |
template<class T , std::enable_if_t< std::conjunction_v< std::negation< has_member_variable_state< T >>, has_member_state< T >, std::negation< has_non_member_state< T >>>, int > = 0> | |
constexpr decltype(auto) | operator() (T &&t) const noexcept(noexcept(std::forward< T >(t).state())) |
Overload for when the particle type defines a member method. More... | |
template<class T , std::enable_if_t< std::conjunction_v< std::negation< has_member_variable_state< T >>, std::negation< has_member_state< T >>, std::negation< has_non_member_state< T >>, is_tuple_like< T >>, int > = 0, std::enable_if_t<(std::tuple_size_v< std::decay_t< T >> > 1), int > = 0> | |
constexpr decltype(auto) | operator() (T &&t) const noexcept(noexcept(std::get< 0 >(std::forward< T >(t)))) |
Overload for tuple-like types. More... | |
Customization point object type for accessing the state
of a particle.
See https://en.cppreference.com/w/cpp/ranges/cpo.
Definition at line 98 of file primitives.hpp.
|
inlineconstexprnoexcept |
Overload for when the particle type defines a member variable.
Definition at line 108 of file primitives.hpp.
|
inlineconstexprnoexcept |
Overload for when there is an external function that takes this particle type.
The non-member function must be in T's namespace so it can be found by ADL.
Definition at line 137 of file primitives.hpp.
|
inlineconstexprnoexcept |
Overload for when the particle type defines a member method.
Definition at line 121 of file primitives.hpp.
|
inlineconstexprnoexcept |
Overload for tuple-like types.
Assumes that the first element is the state.
Definition at line 155 of file primitives.hpp.