Safe Haskell | None |
---|---|
Language | Haskell2010 |
Ouroboros.Network.MuxMode
Description
Singletons to work with MuxMode
kind.
Synopsis
- data SingMuxMode (mode ∷ MuxMode) where
- data SingHasInitiator (mode ∷ MuxMode) where
- SingHasInitiator ∷ HasInitiator mode ~ True ⇒ SingHasInitiator mode
- SingNoInitiator ∷ HasInitiator mode ~ False ⇒ SingHasInitiator mode
- hasInitiatorMode ∷ SingMuxMode mode → SingHasInitiator mode
- data WithMuxMode (mode ∷ MuxMode) a b where
- WithInitiatorMode ∷ a → WithMuxMode InitiatorMode a b
- WithResponderMode ∷ b → WithMuxMode ResponderMode a b
- WithInitiatorResponderMode ∷ a → b → WithMuxMode InitiatorResponderMode a b
- type WithMuxTuple mode a = WithMuxMode mode a a
- withInitiatorMode ∷ HasInitiator mode ~ True ⇒ WithMuxMode mode a b → a
- withResponderMode ∷ HasResponder mode ~ True ⇒ WithMuxMode mode a b → b
- data InResponderMode (mode ∷ MuxMode) a where
- InResponderMode ∷ HasResponder mode ~ True ⇒ a → InResponderMode mode a
- NotInResponderMode ∷ InResponderMode mode a
Documentation
data SingMuxMode (mode ∷ MuxMode) where Source #
Singletons for matching the MuxMode
at term level.
data SingHasInitiator (mode ∷ MuxMode) where Source #
Singleton for to match the
constraint.HasInitiator
mode ~ True
Constructors
SingHasInitiator ∷ HasInitiator mode ~ True ⇒ SingHasInitiator mode | |
SingNoInitiator ∷ HasInitiator mode ~ False ⇒ SingHasInitiator mode |
hasInitiatorMode ∷ SingMuxMode mode → SingHasInitiator mode Source #
data WithMuxMode (mode ∷ MuxMode) a b where Source #
Constructors
WithInitiatorMode ∷ a → WithMuxMode InitiatorMode a b | |
WithResponderMode ∷ b → WithMuxMode ResponderMode a b | |
WithInitiatorResponderMode ∷ a → b → WithMuxMode InitiatorResponderMode a b |
type WithMuxTuple mode a = WithMuxMode mode a a Source #
withInitiatorMode ∷ HasInitiator mode ~ True ⇒ WithMuxMode mode a b → a Source #
withResponderMode ∷ HasResponder mode ~ True ⇒ WithMuxMode mode a b → b Source #
data InResponderMode (mode ∷ MuxMode) a where Source #
Constructors
InResponderMode ∷ HasResponder mode ~ True ⇒ a → InResponderMode mode a | |
NotInResponderMode ∷ InResponderMode mode a |