Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data HardForkCompatQuery blk ∷ Type → Type where
- CompatIfCurrent ∷ BlockQuery blk result → HardForkCompatQuery blk result
- CompatAnytime ∷ QueryAnytime result → EraIndex (HardForkIndices blk) → HardForkCompatQuery blk result
- CompatHardFork ∷ QueryHardFork (HardForkIndices blk) result → HardForkCompatQuery blk result
- compatGetEraStart ∷ EraIndex (HardForkIndices blk) → HardForkCompatQuery blk (Maybe Bound)
- compatGetInterpreter ∷ HardForkCompatQuery blk (Interpreter (HardForkIndices blk))
- compatIfCurrent ∷ BlockQuery blk result → HardForkCompatQuery blk result
- forwardCompatQuery ∷ ∀ m x xs. IsNonEmpty xs ⇒ (∀ result. BlockQuery (HardForkBlock (x ': xs)) result → m result) → ∀ result. HardForkCompatQuery (HardForkBlock (x ': xs)) result → m result
- singleEraCompatQuery ∷ ∀ m blk era. (Monad m, HardForkIndices blk ~ '[era]) ⇒ EpochSize → SlotLength → GenesisWindow → (∀ result. BlockQuery blk result → m result) → ∀ result. HardForkCompatQuery blk result → m result
Documentation
data HardForkCompatQuery blk ∷ Type → Type where Source #
Version of Query (HardForkBlock xs)
without the restriction to have
at least two eras
CompatIfCurrent ∷ BlockQuery blk result → HardForkCompatQuery blk result | |
CompatAnytime ∷ QueryAnytime result → EraIndex (HardForkIndices blk) → HardForkCompatQuery blk result | |
CompatHardFork ∷ QueryHardFork (HardForkIndices blk) result → HardForkCompatQuery blk result |
Convenience constructors
compatGetEraStart ∷ EraIndex (HardForkIndices blk) → HardForkCompatQuery blk (Maybe Bound) Source #
Get the start of the specified era, if known
compatGetInterpreter ∷ HardForkCompatQuery blk (Interpreter (HardForkIndices blk)) Source #
Get an interpreter for history queries
I.e., this can be used for slotepochtime conversions.
compatIfCurrent ∷ BlockQuery blk result → HardForkCompatQuery blk result Source #
Submit query to underlying ledger
Wrappers
∷ ∀ m x xs. IsNonEmpty xs | |
⇒ (∀ result. BlockQuery (HardForkBlock (x ': xs)) result → m result) | Submit a query through the LocalStateQuery protocol. |
→ ∀ result. HardForkCompatQuery (HardForkBlock (x ': xs)) result → m result |
Wrapper used when connecting to a server that's running the HFC with at least two eras
∷ ∀ m blk era. (Monad m, HardForkIndices blk ~ '[era]) | |
⇒ EpochSize | |
→ SlotLength | |
→ GenesisWindow | |
→ (∀ result. BlockQuery blk result → m result) | Submit a query through the LocalStateQuery protocol. |
→ ∀ result. HardForkCompatQuery blk result → m result |
Wrapper used when connecting to a server that's not using the HFC, or is using the HFC but with a single era only.