Struct mpstthree::meshedchannels::MeshedChannels [−][src]
pub struct MeshedChannels<S1, S2, R, N> where
S1: Session,
S2: Session,
R: Role,
N: Role, {
pub session1: S1,
pub session2: S2,
pub stack: R,
pub name: N,
}
Expand description
The structure which encapsulates two binary session types, a stack and a name.
Example
use mpstthree::binary::struct_trait::{End, Recv, Send, Session}; use mpstthree::meshedchannels::MeshedChannels; use mpstthree::role::a::RoleA; use mpstthree::role::b::RoleB; use mpstthree::role::c::RoleC; use mpstthree::role::end::RoleEnd; // Creating the binary sessions type AtoB<N> = Send<N, End>; type AtoC<N> = Recv<N, End>; // Stacks type StackA = RoleB<RoleC<RoleEnd>>; // Creating the MP sessions type EndpointA<N> = MeshedChannels<AtoB<N>, AtoC<N>, StackA, RoleA<RoleEnd>>;
Fields
session1: S1
session2: S2
stack: R
name: N
Implementations
impl<S0: Session, S1: Session, S2: Session, S3: Session, S4: Session, S5: Session, R0: Role, R1: Role, R2: Role, R3: Role, R4: Role, R5: Role> MeshedChannels<Send<Either<MeshedChannels<S2, <S0 as Session>::Dual, R0, RoleB<RoleEnd>>, MeshedChannels<S4, <S1 as Session>::Dual, R1, RoleB<RoleEnd>>>, End>, Send<Either<MeshedChannels<S3, S0, R2, RoleC<RoleEnd>>, MeshedChannels<S5, S1, R3, RoleC<RoleEnd>>>, End>, RoleAtoAll<R4, R5>, RoleA<RoleEnd>>
impl<S0: Session, S1: Session, S2: Session, S3: Session, S4: Session, S5: Session, R0: Role, R1: Role, R2: Role, R3: Role, R4: Role, R5: Role> MeshedChannels<Send<Either<MeshedChannels<S2, <S0 as Session>::Dual, R0, RoleB<RoleEnd>>, MeshedChannels<S4, <S1 as Session>::Dual, R1, RoleB<RoleEnd>>>, End>, Send<Either<MeshedChannels<S3, S0, R2, RoleC<RoleEnd>>, MeshedChannels<S5, S1, R3, RoleC<RoleEnd>>>, End>, RoleAtoAll<R4, R5>, RoleA<RoleEnd>>
pub fn choose_left(
self
) -> MeshedChannels<<S2 as Session>::Dual, <S3 as Session>::Dual, R4, RoleA<RoleEnd>>
pub fn choose_right(
self
) -> MeshedChannels<<S4 as Session>::Dual, <S5 as Session>::Dual, R5, RoleA<RoleEnd>>
impl<S0: Session, S1: Session, S2: Session, S3: Session, S4: Session, S5: Session, R0: Role, R1: Role, R2: Role, R3: Role, R4: Role, R5: Role> MeshedChannels<Send<Either<MeshedChannels<S2, <S0 as Session>::Dual, R0, RoleA<RoleEnd>>, MeshedChannels<S4, <S1 as Session>::Dual, R1, RoleA<RoleEnd>>>, End>, Send<Either<MeshedChannels<S0, S3, R2, RoleC<RoleEnd>>, MeshedChannels<S1, S5, R3, RoleC<RoleEnd>>>, End>, RoleBtoAll<R4, R5>, RoleB<RoleEnd>>
impl<S0: Session, S1: Session, S2: Session, S3: Session, S4: Session, S5: Session, R0: Role, R1: Role, R2: Role, R3: Role, R4: Role, R5: Role> MeshedChannels<Send<Either<MeshedChannels<S2, <S0 as Session>::Dual, R0, RoleA<RoleEnd>>, MeshedChannels<S4, <S1 as Session>::Dual, R1, RoleA<RoleEnd>>>, End>, Send<Either<MeshedChannels<S0, S3, R2, RoleC<RoleEnd>>, MeshedChannels<S1, S5, R3, RoleC<RoleEnd>>>, End>, RoleBtoAll<R4, R5>, RoleB<RoleEnd>>
pub fn choose_left(
self
) -> MeshedChannels<<S2 as Session>::Dual, <S3 as Session>::Dual, R4, RoleB<RoleEnd>>
pub fn choose_right(
self
) -> MeshedChannels<<S4 as Session>::Dual, <S5 as Session>::Dual, R5, RoleB<RoleEnd>>
impl<S0: Session, S1: Session, S2: Session, S3: Session, S4: Session, S5: Session, R0: Role, R1: Role, R2: Role, R3: Role, R4: Role, R5: Role> MeshedChannels<Send<Either<MeshedChannels<<S0 as Session>::Dual, S2, R0, RoleA<RoleEnd>>, MeshedChannels<<S1 as Session>::Dual, S4, R1, RoleA<RoleEnd>>>, End>, Send<Either<MeshedChannels<S0, S3, R2, RoleB<RoleEnd>>, MeshedChannels<S1, S5, R3, RoleB<RoleEnd>>>, End>, RoleCtoAll<R4, R5>, RoleC<RoleEnd>>
impl<S0: Session, S1: Session, S2: Session, S3: Session, S4: Session, S5: Session, R0: Role, R1: Role, R2: Role, R3: Role, R4: Role, R5: Role> MeshedChannels<Send<Either<MeshedChannels<<S0 as Session>::Dual, S2, R0, RoleA<RoleEnd>>, MeshedChannels<<S1 as Session>::Dual, S4, R1, RoleA<RoleEnd>>>, End>, Send<Either<MeshedChannels<S0, S3, R2, RoleB<RoleEnd>>, MeshedChannels<S1, S5, R3, RoleB<RoleEnd>>>, End>, RoleCtoAll<R4, R5>, RoleC<RoleEnd>>
pub fn choose_left(
self
) -> MeshedChannels<<S2 as Session>::Dual, <S3 as Session>::Dual, R4, RoleC<RoleEnd>>
pub fn choose_right(
self
) -> MeshedChannels<<S4 as Session>::Dual, <S5 as Session>::Dual, R5, RoleC<RoleEnd>>
Trait Implementations
Auto Trait Implementations
impl<S1, S2, R, N> RefUnwindSafe for MeshedChannels<S1, S2, R, N> where
N: RefUnwindSafe,
R: RefUnwindSafe,
S1: RefUnwindSafe,
S2: RefUnwindSafe,
impl<S1, S2, R, N> Send for MeshedChannels<S1, S2, R, N>
impl<S1, S2, R, N> Sync for MeshedChannels<S1, S2, R, N> where
N: Sync,
R: Sync,
S1: Sync,
S2: Sync,
impl<S1, S2, R, N> Unpin for MeshedChannels<S1, S2, R, N> where
N: Unpin,
R: Unpin,
S1: Unpin,
S2: Unpin,
impl<S1, S2, R, N> UnwindSafe for MeshedChannels<S1, S2, R, N> where
N: UnwindSafe,
R: UnwindSafe,
S1: UnwindSafe,
S2: UnwindSafe,