![]() |
LeechCraft 0.6.70-17335-ge406ffdcaf
Modular cross-platform feature rich live environment.
|
#include "either.h"
Public Types | |
using | L_t = L |
using | R_t = R |
Public Member Functions | |
Either ()=delete | |
Either (const L &l) | |
Either (R &&r) | |
Either (const R &r) | |
Either (const Either &)=default | |
Either (Either &&)=default | |
Either & | operator= (const Either &)=default |
Either & | operator= (Either &&)=default |
bool | IsLeft () const |
bool | IsRight () const |
const L & | GetLeft () const |
const R & | GetRight () const |
std::optional< L > | MaybeLeft () const |
std::optional< R > | MaybeRight () const |
std::variant< L, R > | AsVariant () const & |
std::variant< L, R > | AsVariant () && |
template<typename F> | |
R | ToRight (F &&f) const |
template<typename F> | |
auto | MapLeft (F &&f) const |
template<typename F> | |
auto | MapRight (F &&f) const |
Static Public Member Functions | |
template<typename LL = L> | |
static Either | Left (const LL &l) |
static Either | Right (R &&r) |
static Either | Right (const R &r) |
template<typename RNew> requires (!std::is_convertible_v<RNew, R>) | |
static auto | Right (const RNew &r) |
static auto | EmbeddingLeft () |
Friends | |
bool | operator== (const Either &e1, const Either &e2) |
bool | operator!= (const Either &e1, const Either &e2) |
using LC::Util::Either< L, R >::L_t = L |
using LC::Util::Either< L, R >::R_t = R |
|
delete |
|
inlineexplicit |
|
inlineexplicit |
|
inlineexplicit |
|
default |
|
default |
|
inline |
|
inline |
Definition at line 93 of file either.h.
Referenced by LC::Util::Visit().
|
inlinestatic |
|
inline |
Definition at line 65 of file either.h.
Referenced by LC::Util::InstanceFunctor< Either< L, R > >::Apply(), LC::Util::InstanceMonad< Either< L, R > >::Bind(), and LC::Util::Either< Error, Success >::MaybeLeft().
|
inline |
Definition at line 72 of file either.h.
Referenced by LC::Util::InstanceFunctor< Either< L, R > >::Apply(), LC::Util::InstanceMonad< Either< L, R > >::Bind(), LC::Util::Either< Error, Success >::MaybeRight(), LC::Util::RightOr(), LC::Util::RightOr(), and LC::Util::Either< Error, Success >::ToRight().
|
inline |
Definition at line 55 of file either.h.
Referenced by LC::Util::InstanceFunctor< Either< L, R > >::Apply(), and LC::Util::InstanceMonad< Either< L, R > >::Bind().
|
inline |
Definition at line 60 of file either.h.
Referenced by LC::Util::Either< Error, Success >::MapLeft(), LC::Util::Either< Error, Success >::MapRight(), LC::Util::RightOr(), LC::Util::RightOr(), and LC::Util::Either< Error, Success >::ToRight().
|
inlinestatic |
Definition at line 126 of file either.h.
Referenced by LC::Util::Either< Error, Success >::EmbeddingLeft(), and LC::Util::ToJson().
|
inline |
|
inline |
|
inline |
|
inline |
|
default |
|
default |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
Definition at line 134 of file either.h.
Referenced by LC::Util::Either< Error, Success >::EmbeddingLeft(), LC::Util::InstanceApplicative< Either< L, R > >::Pure(), LC::Util::Either< Error, Success >::Right(), and LC::Util::ToJson().
|
inline |