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

Ouroboros.Consensus.Mock.Node.Serialisation

Synopsis

Documentation

type MockBlock ext = SimpleBlock SimpleMockCrypto ext Source #

Local shorthand to make the instances more readable

data family NestedCtxt_ blk ∷ (TypeType) → TypeType Source #

Context identifying what kind of block we have

In almost all places we will use NestedCtxt rather than NestedCtxt_.

Instances

Instances details
SameDepIndex (NestedCtxt_ (SimpleBlock c ext) f) Source # 
Instance details

Defined in Ouroboros.Consensus.Mock.Node.Serialisation

Methods

sameDepIndexNestedCtxt_ (SimpleBlock c ext) f a → NestedCtxt_ (SimpleBlock c ext) f b → Maybe (a :~: b) Source #

TrivialDependency (NestedCtxt_ (SimpleBlock c ext) f) Source # 
Instance details

Defined in Ouroboros.Consensus.Mock.Node.Serialisation

Associated Types

type TrivialIndex (NestedCtxt_ (SimpleBlock c ext) f) Source #

Show (NestedCtxt_ (SimpleBlock c ext) f a) Source # 
Instance details

Defined in Ouroboros.Consensus.Mock.Node.Serialisation

Methods

showsPrecIntNestedCtxt_ (SimpleBlock c ext) f a → ShowS #

showNestedCtxt_ (SimpleBlock c ext) f a → String #

showList ∷ [NestedCtxt_ (SimpleBlock c ext) f a] → ShowS #

data NestedCtxt_ (SimpleBlock c ext) f a Source # 
Instance details

Defined in Ouroboros.Consensus.Mock.Node.Serialisation

data NestedCtxt_ (SimpleBlock c ext) f a where
type TrivialIndex (NestedCtxt_ (SimpleBlock c ext) f) Source # 
Instance details

Defined in Ouroboros.Consensus.Mock.Node.Serialisation

type TrivialIndex (NestedCtxt_ (SimpleBlock c ext) f) = f (SimpleBlock c ext)

Orphan instances

Serialise ext ⇒ ReconstructNestedCtxt Header (MockBlock ext) Source # 
Instance details

HasNestedContent f (SimpleBlock c ext) Source # 
Instance details

Methods

unnest ∷ f (SimpleBlock c ext) → DepPair (NestedCtxt f (SimpleBlock c ext)) Source #

nestDepPair (NestedCtxt f (SimpleBlock c ext)) → f (SimpleBlock c ext) Source #

(Serialise ext, Typeable ext) ⇒ SerialiseNodeToClientConstraints (MockBlock ext) Source # 
Instance details

Serialise ext ⇒ SerialiseNodeToNodeConstraints (MockBlock ext) Source # 
Instance details

(Serialise ext, RunMockBlock SimpleMockCrypto ext) ⇒ SerialiseDiskConstraints (MockBlock ext) Source # 
Instance details

(Serialise ext, Typeable ext) ⇒ HasBinaryBlockInfo (MockBlock ext) Source # 
Instance details

SerialiseNodeToClient (MockBlock ext) SlotNo Source # 
Instance details

SerialiseNodeToClient (MockBlock ext) (GenTx (MockBlock ext)) Source # 
Instance details

SerialiseNodeToClient (MockBlock ext) (GenTxId (MockBlock ext)) Source # 
Instance details

SerialiseNodeToClient (MockBlock ext) (MockError (MockBlock ext)) Source # 
Instance details

Serialise ext ⇒ SerialiseNodeToClient (MockBlock ext) (MockBlock ext) Source # 
Instance details

Serialise ext ⇒ SerialiseNodeToNode (MockBlock ext) (Header (MockBlock ext)) Source # 
Instance details

SerialiseNodeToNode (MockBlock ext) (GenTx (MockBlock ext)) Source # 
Instance details

SerialiseNodeToNode (MockBlock ext) (GenTxId (MockBlock ext)) Source # 
Instance details

Serialise ext ⇒ SerialiseNodeToNode (MockBlock ext) (SerialisedHeader (MockBlock ext)) Source # 
Instance details

Serialise ext ⇒ SerialiseNodeToNode (MockBlock ext) (MockBlock ext) Source # 
Instance details

SerialiseResult (MockBlock ext) (BlockQuery (MockBlock ext)) Source # 
Instance details

Methods

encodeResultCodecConfig (MockBlock ext) → BlockNodeToClientVersion (MockBlock ext) → BlockQuery (MockBlock ext) result → result → Encoding Source #

decodeResultCodecConfig (MockBlock ext) → BlockNodeToClientVersion (MockBlock ext) → BlockQuery (MockBlock ext) result → ∀ s. Decoder s result Source #

DecodeDisk (MockBlock ext) (AnnTip (MockBlock ext)) Source # 
Instance details

Methods

decodeDiskCodecConfig (MockBlock ext) → ∀ s. Decoder s (AnnTip (MockBlock ext)) Source #

DecodeDisk (MockBlock ext) (LedgerState (MockBlock ext)) Source # 
Instance details

Methods

decodeDiskCodecConfig (MockBlock ext) → ∀ s. Decoder s (LedgerState (MockBlock ext)) Source #

Serialise ext ⇒ DecodeDiskDep (NestedCtxt Header) (MockBlock ext) Source # 
Instance details

Methods

decodeDiskDepCodecConfig (MockBlock ext) → NestedCtxt Header (MockBlock ext) a → ∀ s. Decoder s (ByteString → a) Source #

Serialise ext ⇒ DecodeDiskDepIx (NestedCtxt Header) (MockBlock ext) Source # 
Instance details

Serialise ext ⇒ EncodeDisk (MockBlock ext) (Header (MockBlock ext)) Source # 
Instance details

EncodeDisk (MockBlock ext) (AnnTip (MockBlock ext)) Source # 
Instance details

EncodeDisk (MockBlock ext) (LedgerState (MockBlock ext)) Source # 
Instance details

Serialise ext ⇒ EncodeDisk (MockBlock ext) (MockBlock ext) Source # 
Instance details

Serialise ext ⇒ EncodeDiskDep (NestedCtxt Header) (MockBlock ext) Source # 
Instance details

Serialise ext ⇒ EncodeDiskDepIx (NestedCtxt Header) (MockBlock ext) Source # 
Instance details

SerialiseNodeToClient (MockBlock ext) (Serialised (MockBlock ext)) Source # 
Instance details

SerialiseNodeToNode (MockBlock ext) (Serialised (MockBlock ext)) Source # 
Instance details

Serialise ext ⇒ DecodeDisk (MockBlock ext) (ByteStringHeader (MockBlock ext)) Source # 
Instance details

Methods

decodeDiskCodecConfig (MockBlock ext) → ∀ s. Decoder s (ByteStringHeader (MockBlock ext)) Source #

Serialise ext ⇒ DecodeDisk (MockBlock ext) (ByteStringMockBlock ext) Source # 
Instance details

Methods

decodeDiskCodecConfig (MockBlock ext) → ∀ s. Decoder s (ByteStringMockBlock ext) Source #

SerialiseNodeToClient (MockBlock ext) (SomeSecond BlockQuery (MockBlock ext)) Source # 
Instance details

SameDepIndex (NestedCtxt_ (SimpleBlock c ext) f) Source # 
Instance details

Methods

sameDepIndexNestedCtxt_ (SimpleBlock c ext) f a → NestedCtxt_ (SimpleBlock c ext) f b → Maybe (a :~: b) Source #

TrivialDependency (NestedCtxt_ (SimpleBlock c ext) f) Source # 
Instance details

Associated Types

type TrivialIndex (NestedCtxt_ (SimpleBlock c ext) f) Source #

Show (NestedCtxt_ (SimpleBlock c ext) f a) Source # 
Instance details

Methods

showsPrecIntNestedCtxt_ (SimpleBlock c ext) f a → ShowS #

showNestedCtxt_ (SimpleBlock c ext) f a → String #

showList ∷ [NestedCtxt_ (SimpleBlock c ext) f a] → ShowS #