ouroboros-consensus-0.21.0.0: Consensus layer for the Ouroboros blockchain protocol
Safe HaskellSafe-Inferred
LanguageHaskell2010

Test.Util.RefEnv

Synopsis

Documentation

data RefEnv k a r Source #

Instances

Instances details
Foldable (RefEnv k a ∷ (TypeType) → Type) Source # 
Instance details

Defined in Test.Util.RefEnv

Methods

foldMapMonoid m ⇒ (∀ (x ∷ k0). p x → m) → RefEnv k a p → m Source #

Functor (RefEnv k a ∷ (TypeType) → Type) Source # 
Instance details

Defined in Test.Util.RefEnv

Methods

fmap ∷ (∀ (x ∷ k0). p x → q x) → RefEnv k a p → RefEnv k a q Source #

Traversable (RefEnv k a ∷ (TypeType) → Type) Source # 
Instance details

Defined in Test.Util.RefEnv

Methods

traverseApplicative f ⇒ (∀ (a0 ∷ k0). p a0 → f (q a0)) → RefEnv k a p → f (RefEnv k a q) Source #

Generic (RefEnv k a r) Source # 
Instance details

Defined in Test.Util.RefEnv

Associated Types

type Rep (RefEnv k a r) ∷ TypeType #

Methods

fromRefEnv k a r → Rep (RefEnv k a r) x #

toRep (RefEnv k a r) x → RefEnv k a r #

(Show1 r, Show k, Show a) ⇒ Show (RefEnv k a r) Source # 
Instance details

Defined in Test.Util.RefEnv

Methods

showsPrecIntRefEnv k a r → ShowS #

showRefEnv k a r → String #

showList ∷ [RefEnv k a r] → ShowS #

(ToExpr a, ToExpr (r k)) ⇒ ToExpr (RefEnv k a r) Source # 
Instance details

Defined in Test.Util.RefEnv

Methods

toExprRefEnv k a r → Expr Source #

listToExpr ∷ [RefEnv k a r] → Expr Source #

type Rep (RefEnv k a r) Source # 
Instance details

Defined in Test.Util.RefEnv

type Rep (RefEnv k a r) = D1 ('MetaData "RefEnv" "Test.Util.RefEnv" "ouroboros-consensus-0.21.0.0-inplace-unstable-consensus-testlib" 'False) (C1 ('MetaCons "RefEnv" 'PrefixI 'True) (S1 ('MetaSel ('Just "toList") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [(Reference k r, a)])))

elemsRefEnv k a r → [a] Source #

emptyRefEnv k a r Source #

Empty environment

In most context mempty can be used, but the Monoid instance requires equality, which empty does not.

filter ∷ (a → Bool) → RefEnv k a r → RefEnv k a r Source #

fromList ∷ (Eq k, Show k, Eq a, Show a, Eq1 r, Show1 r, HasCallStack) ⇒ [(Reference k r, a)] → RefEnv k a r Source #

keysRefEnv k a r → [Reference k r] Source #

lookup ∷ (Eq k, Eq1 r) ⇒ Reference k r → RefEnv k a r → Maybe a Source #

nullRefEnv k a r → Bool Source #

reverseLookup ∷ (a → Bool) → RefEnv k a r → [Reference k r] Source #

singletonReference k r → a → RefEnv k a r Source #

toListRefEnv k a r → [(Reference k r, a)] Source #

union ∷ (Eq k, Show k, Eq a, Show a, Eq1 r, Show1 r, HasCallStack) ⇒ RefEnv k a r → RefEnv k a r → RefEnv k a r Source #

(!) ∷ (Eq k, Eq1 r) ⇒ RefEnv k a r → Reference k r → a Source #