cardano-ledger-core-1.18.0.0: Core components of Cardano ledgers from the Shelley release on.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Cardano.Ledger.Block

Synopsis

Documentation

data Block h era Source #

Constructors

Block !h !(TxSeq era) 

Instances

Instances details
(EraSegWits era, DecCBOR (Annotator h), Typeable h) ⇒ DecCBOR (Annotator (Block h era)) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

decCBORDecoder s (Annotator (Block h era)) Source #

dropCBORProxy (Annotator (Block h era)) → Decoder s () Source #

labelProxy (Annotator (Block h era)) → Text Source #

Generic (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Associated Types

type Rep (Block h era) ∷ TypeType #

Methods

fromBlock h era → Rep (Block h era) x #

toRep (Block h era) x → Block h era #

(Era era, Show (TxSeq era), Show h) ⇒ Show (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

showsPrecIntBlock h era → ShowS #

showBlock h era → String #

showList ∷ [Block h era] → ShowS #

(Era era, EncCBORGroup (TxSeq era), EncCBOR h) ⇒ ToCBOR (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

toCBORBlock h era → Encoding Source #

encodedSizeExpr ∷ (∀ t. ToCBOR t ⇒ Proxy t → Size) → Proxy (Block h era) → Size Source #

encodedListSizeExpr ∷ (∀ t. ToCBOR t ⇒ Proxy t → Size) → Proxy [Block h era] → Size Source #

(EraSegWits era, DecCBOR h, DecCBOR (TxSeq era)) ⇒ DecCBOR (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

decCBORDecoder s (Block h era) Source #

dropCBORProxy (Block h era) → Decoder s () Source #

labelProxy (Block h era) → Text Source #

(Era era, EncCBORGroup (TxSeq era), EncCBOR h) ⇒ EncCBOR (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

encCBORBlock h era → Encoding Source #

encodedSizeExpr ∷ (∀ t. EncCBOR t ⇒ Proxy t → Size) → Proxy (Block h era) → Size Source #

encodedListSizeExpr ∷ (∀ t. EncCBOR t ⇒ Proxy t → Size) → Proxy [Block h era] → Size Source #

(Era era, Eq (TxSeq era), Eq h) ⇒ Eq (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

(==)Block h era → Block h era → Bool #

(/=)Block h era → Block h era → Bool #

(Era era, NoThunks (TxSeq era), NoThunks h) ⇒ NoThunks (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

Methods

noThunksContextBlock h era → IO (Maybe ThunkInfo) Source #

wNoThunksContextBlock h era → IO (Maybe ThunkInfo) Source #

showTypeOfProxy (Block h era) → String Source #

type Rep (Block h era) Source # 
Instance details

Defined in Cardano.Ledger.Block

type Rep (Block h era) = D1 ('MetaData "Block" "Cardano.Ledger.Block" "cardano-ledger-core-1.18.0.0-inplace" 'False) (C1 ('MetaCons "Block" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 h) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (TxSeq era))))

bheaderBlock h era → h Source #

bbodyBlock h era → TxSeq era Source #

neededTxInsForBlock ∷ ∀ h era. EraSegWits era ⇒ Block h era → Set TxIn Source #

The validity of any individual block depends only on a subset of the UTxO stored in the ledger state. This function returns the transaction inputs corresponding to the required UTxO for a given Block.

This function will be used by the consensus layer to enable storing the UTxO on disk. In particular, given a block, the consensus layer will use neededTxInsForBlock to retrieve the needed UTxO from disk and present only those to the ledger.