hydra-node-0.22.0: The Hydra node
Safe HaskellSafe-Inferred
LanguageGHC2021

Hydra.HeadLogic.StateEvent

Synopsis

State change events as used by Hydra.Node

data StateEvent tx Source #

A state change event with an event id that is the common entity to be loaded from an EventSource and sent to EventSinks.

Constructors

StateEvent 

Instances

Instances details
(ArbitraryIsTx tx, IsChainState tx) => Arbitrary (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

Methods

arbitrary :: Gen (StateEvent tx)

shrink :: StateEvent tx -> [StateEvent tx]

IsChainState tx => FromJSON (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

Methods

parseJSON :: Value -> Parser (StateEvent tx)

parseJSONList :: Value -> Parser [StateEvent tx]

omittedField :: Maybe (StateEvent tx)

IsChainState tx => ToJSON (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

Methods

toJSON :: StateEvent tx -> Value

toEncoding :: StateEvent tx -> Encoding

toJSONList :: [StateEvent tx] -> Value

toEncodingList :: [StateEvent tx] -> Encoding

omitField :: StateEvent tx -> Bool

Generic (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

Associated Types

type Rep (StateEvent tx) :: Type -> Type Source #

Methods

from :: StateEvent tx -> Rep (StateEvent tx) x Source #

to :: Rep (StateEvent tx) x -> StateEvent tx Source #

IsChainState tx => Show (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

IsChainState tx => Eq (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

Methods

(==) :: StateEvent tx -> StateEvent tx -> Bool Source #

(/=) :: StateEvent tx -> StateEvent tx -> Bool Source #

HasEventId (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

type Rep (StateEvent tx) Source # 
Instance details

Defined in Hydra.HeadLogic.StateEvent

type Rep (StateEvent tx) = D1 ('MetaData "StateEvent" "Hydra.HeadLogic.StateEvent" "hydra-node-0.22.0-3RX9tiIC3LXIH8z0ykSV06" 'False) (C1 ('MetaCons "StateEvent" 'PrefixI 'True) (S1 ('MetaSel ('Just "eventId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 EventId) :*: (S1 ('MetaSel ('Just "stateChanged") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (StateChanged tx)) :*: S1 ('MetaSel ('Just "time") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UTCTime))))