These classes are internal to the library, they may change at any time.
More...
These classes are internal to the library, they may change at any time.
You should not use these classes in your code.
◆ OBSERVABLE_DEFINE_UNARY_OP
#define OBSERVABLE_DEFINE_UNARY_OP |
( |
|
OP | ) |
|
Value:template <typename ... T> \
inline auto operator OP (value<T ...> & arg) \
noexcept(noexcept(OP arg.get())) \
-> expression_node<std::decay_t<decltype(OP arg.get())>> \
{ \
} \
\
template <typename T> \
inline auto operator OP (expression_node<T> && arg) \
noexcept(noexcept(OP arg.get())) \
-> expression_node<std::decay_t<decltype(OP arg.get())>> \
{ \
std::move(arg)); \
}
auto make_node(T &&val)
Create a node from a regular type.
Definition: utility.hpp:104
Create a unary operator.
◆ OBSERVABLE_DEFINE_BINARY_OP
#define OBSERVABLE_DEFINE_BINARY_OP |
( |
|
OP | ) |
|
Create a binary operator.
◆ is_compatible_with_observer
template<typename CallableType , typename ObserverType >
Check if a callable type is compatible with an observer type.
A callable is compatible with an observer type if the callable can be stored inside a std::function<ObserverType>
.
- Template Parameters
-
CallableType | The type to check if it is compatible with the ObserverType. |
ObserverType | The type of the observer to check against. |
The static member value
will be true, if the CallableType is compatible with the ObserverType.
◆ is_compatible_with_subject
template<typename CallableType , typename SubjectType >
Check if a callable type can be used to subscribe to a subject.
A callable can be used to subscribe to a subject if the callable is compatible with the subject's observer_type
type.
- Template Parameters
-
CallableType | The type to check if it can be used to subscribe to the provided subject. |
SubjectType | The subject to check against. |
The static member value
will be true if, the CallableType can be used with the SubjectType.
◆ val_type_t
Convenience typedef for extracting the value type from an expression_node or observable value<ValueType, EqualityComparator>.
- See also
- val_type
◆ result_node_t
template<typename Op , typename ... Args>
Type of the expression_node created for an expression with callable Op
and corresponding arguments.
◆ make_node() [1/4]
template<typename T >
auto observable::expr::expr_detail::make_node |
( |
T && |
val | ) |
|
|
inline |
Create a node from a regular type.
◆ make_node() [2/4]
template<typename T , typename ... R>
auto observable::expr::expr_detail::make_node |
( |
value< T, R ... > & |
val | ) |
|
|
inline |
Create a node from an observable value reference.
◆ make_node() [3/4]
template<typename T >
auto observable::expr::expr_detail::make_node |
( |
expression_node< T > && |
node | ) |
|
|
inline |
◆ make_node() [4/4]
template<typename Op , typename ... Args>
auto observable::expr::expr_detail::make_node |
( |
Op && |
op, |
|
|
Args &&... |
args |
|
) |
| |
|
inline |
Create a node from an operator and an arbitrary number of arguments.