cardano-slotting-0.1.0.0: Key slotting types for cardano libraries
Safe HaskellNone
LanguageHaskell2010

Cardano.Slotting.EpochInfo.API

Contents

Synopsis

Documentation

data EpochInfo m Source #

Information about epochs

Epochs may have different sizes at different times during the lifetime of the blockchain. This information is encapsulated by EpochInfo; it is parameterized over a monad m because the information about how long each epoch is may depend on information derived from the blockchain itself, and hence requires access to state.

The other functions provide some derived information from epoch sizes. In the default implementation all of these functions query and update an internal cache maintaining cumulative epoch sizes; for that reason, all of these functions live in a monad m.

Constructors

EpochInfo 

Fields

Instances

Instances details
Show (EpochInfo Identity) Source #

Show instance only for non-stateful instances

Instance details

Defined in Cardano.Slotting.EpochInfo.API

NoThunks (EpochInfo m) Source # 
Instance details

Defined in Cardano.Slotting.EpochInfo.API

Utility

hoistEpochInfo :: (forall a. m a -> n a) -> EpochInfo m -> EpochInfo n Source #