Struct dialectic::types::Offer[][src]

#[repr(transparent)]pub struct Offer<Choices>(pub Choices);

Passively offer! a choice between any of the protocols in the tuple Choices.

At most 128 choices can be offered in a single Offer type; to supply more options, nest Offers within each other.

Trait Implementations

impl<Choices: 'static> Actionable for Offer<Choices>[src]

type NextAction = Self

The next actual channel action, which must be one of Send, Recv, Offer, Choose, Split, Call, or Done. Read more

impl<Choices: Clone> Clone for Offer<Choices>[src]

impl<Choices: Copy> Copy for Offer<Choices>[src]

impl<Choices: Debug> Debug for Offer<Choices>[src]

impl<Choices: Default> Default for Offer<Choices>[src]

impl<Choices: Eq> Eq for Offer<Choices>[src]

impl<Choices: Any> HasDual for Offer<Choices> where
    Choices: Tuple,
    Choices::AsList: EachHasDual,
    <Choices::AsList as EachHasDual>::Duals: List + EachHasDual
[src]

type DualSession = Choose<<<Choices::AsList as EachHasDual>::Duals as List>::AsTuple>

The dual to this session type, i.e. the session type required of the other end of the channel. Read more

impl<Choices: Hash> Hash for Offer<Choices>[src]

impl<N: Unary, Level: Unary, Choices> Lift<N, Level> for Offer<Choices> where
    Choices: Tuple + 'static,
    Choices::AsList: EachLift<N, Level>,
    <Choices::AsList as EachLift<N, Level>>::Lifted: List
[src]

type Lifted = Offer<<<Choices::AsList as EachLift<N, Level>>::Lifted as List>::AsTuple>

The result of the lifting operation.

impl<Choices: Ord> Ord for Offer<Choices>[src]

impl<Choices: PartialEq> PartialEq<Offer<Choices>> for Offer<Choices>[src]

impl<Choices: PartialOrd> PartialOrd<Offer<Choices>> for Offer<Choices>[src]

impl<N: Unary, Choices: Tuple + 'static> Scoped<N> for Offer<Choices> where
    Choices::AsList: EachScoped<N>, 
[src]

impl<Choices> StructuralEq for Offer<Choices>[src]

impl<Choices> StructuralPartialEq for Offer<Choices>[src]

impl<N: Unary, P, Choices> Subst<P, N> for Offer<Choices> where
    Choices: Tuple + 'static,
    Choices::AsList: EachSubst<P, N>,
    <Choices::AsList as EachSubst<P, N>>::Substituted: List
[src]

type Substituted = Offer<<<Choices::AsList as EachSubst<P, N>>::Substituted as List>::AsTuple>

The result of the substitution.

impl<N: Unary, P, Choices> Then<P, N> for Offer<Choices> where
    Choices: Tuple + 'static,
    Choices::AsList: EachThen<P, N>,
    <Choices::AsList as EachThen<P, N>>::Combined: List
[src]

type Combined = Offer<<<Choices::AsList as EachThen<P, N>>::Combined as List>::AsTuple>

The combined type resulting from substituting P for Done in Self.

Auto Trait Implementations

impl<Choices> RefUnwindSafe for Offer<Choices> where
    Choices: RefUnwindSafe

impl<Choices> Send for Offer<Choices> where
    Choices: Send

impl<Choices> Sync for Offer<Choices> where
    Choices: Sync

impl<Choices> Unpin for Offer<Choices> where
    Choices: Unpin

impl<Choices> UnwindSafe for Offer<Choices> where
    Choices: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<'a, T, S> As<'a, Val, T> for S where
    S: Into<T>, 
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<'a, T> By<'a, Mut> for T where
    T: 'a, 
[src]

type Type = &'a mut T

The type of Self when called by Convention.

impl<'a, T> By<'a, Ref> for T where
    T: 'a, 
[src]

type Type = &'a T

The type of Self when called by Convention.

impl<'a, T> By<'a, Val> for T[src]

type Type = T

The type of Self when called by Convention.

impl<'a, T> Convert<'a, Mut, Mut> for T where
    T: 'a, 
[src]

impl<'a, T> Convert<'a, Mut, Ref> for T where
    T: 'a, 
[src]

impl<'a, T> Convert<'a, Mut, Val> for T where
    T: 'a + Clone
[src]

impl<'a, T> Convert<'a, Ref, Ref> for T where
    T: 'a, 
[src]

impl<'a, T> Convert<'a, Ref, Val> for T where
    T: 'a + Clone
[src]

impl<'a, T> Convert<'a, Val, Val> for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.