Documentation ¶
Index ¶
- Constants
- Variables
- func AddListenerForEvent(evsw EventSwitch, id, event string, cb func(data TMEventData))
- func EventStringBond() string
- func EventStringCompleteProposal() string
- func EventStringDupeout() string
- func EventStringFork() string
- func EventStringLock() string
- func EventStringNewBlock() string
- func EventStringNewBlockHeader() string
- func EventStringNewRound() string
- func EventStringNewRoundStep() string
- func EventStringPolka() string
- func EventStringRebond() string
- func EventStringRelock() string
- func EventStringTimeoutPropose() string
- func EventStringTimeoutWait() string
- func EventStringUnbond() string
- func EventStringUnlock() string
- func EventStringVote() string
- func FireEventCompleteProposal(fireable events.Fireable, rs EventDataRoundState)
- func FireEventLock(fireable events.Fireable, rs EventDataRoundState)
- func FireEventNewBlock(fireable events.Fireable, block EventDataNewBlock)
- func FireEventNewBlockHeader(fireable events.Fireable, header EventDataNewBlockHeader)
- func FireEventNewRound(fireable events.Fireable, rs EventDataRoundState)
- func FireEventNewRoundStep(fireable events.Fireable, rs EventDataRoundState)
- func FireEventPolka(fireable events.Fireable, rs EventDataRoundState)
- func FireEventRelock(fireable events.Fireable, rs EventDataRoundState)
- func FireEventTimeoutPropose(fireable events.Fireable, rs EventDataRoundState)
- func FireEventTimeoutWait(fireable events.Fireable, rs EventDataRoundState)
- func FireEventUnlock(fireable events.Fireable, rs EventDataRoundState)
- func FireEventVote(fireable events.Fireable, vote EventDataVote)
- type EventCache
- type EventDataNewBlock
- type EventDataNewBlockHeader
- type EventDataRoundState
- type EventDataTx
- type EventDataVote
- type EventSwitch
- type Eventable
- type Fireable
- type TMEventData
- type TMEventDataInner
Constants ¶
Variables ¶
View Source
var ( EventDataNameNewBlock = "new_block" EventDataNameNewBlockHeader = "new_block_header" EventDataNameTx = "tx" EventDataNameRoundState = "round_state" EventDataNameVote = "vote" )
Functions ¶
func AddListenerForEvent ¶
func AddListenerForEvent(evsw EventSwitch, id, event string, cb func(data TMEventData))
func EventStringCompleteProposal ¶
func EventStringCompleteProposal() string
func EventStringDupeout ¶
func EventStringDupeout() string
func EventStringFork ¶
func EventStringFork() string
func EventStringLock ¶
func EventStringLock() string
func EventStringNewBlock ¶
func EventStringNewBlock() string
func EventStringNewBlockHeader ¶
func EventStringNewBlockHeader() string
func EventStringNewRound ¶
func EventStringNewRound() string
func EventStringNewRoundStep ¶
func EventStringNewRoundStep() string
func EventStringPolka ¶
func EventStringPolka() string
func EventStringRebond ¶
func EventStringRebond() string
func EventStringRelock ¶
func EventStringRelock() string
func EventStringTimeoutPropose ¶
func EventStringTimeoutPropose() string
func EventStringTimeoutWait ¶
func EventStringTimeoutWait() string
func EventStringUnbond ¶
func EventStringUnbond() string
func EventStringUnlock ¶
func EventStringUnlock() string
func EventStringVote ¶
func EventStringVote() string
func FireEventCompleteProposal ¶
func FireEventCompleteProposal(fireable events.Fireable, rs EventDataRoundState)
func FireEventLock ¶
func FireEventLock(fireable events.Fireable, rs EventDataRoundState)
func FireEventNewBlock ¶
func FireEventNewBlock(fireable events.Fireable, block EventDataNewBlock)
func FireEventNewBlockHeader ¶
func FireEventNewBlockHeader(fireable events.Fireable, header EventDataNewBlockHeader)
func FireEventNewRound ¶
func FireEventNewRound(fireable events.Fireable, rs EventDataRoundState)
func FireEventNewRoundStep ¶
func FireEventNewRoundStep(fireable events.Fireable, rs EventDataRoundState)
func FireEventPolka ¶
func FireEventPolka(fireable events.Fireable, rs EventDataRoundState)
func FireEventRelock ¶
func FireEventRelock(fireable events.Fireable, rs EventDataRoundState)
func FireEventTimeoutPropose ¶
func FireEventTimeoutPropose(fireable events.Fireable, rs EventDataRoundState)
func FireEventTimeoutWait ¶
func FireEventTimeoutWait(fireable events.Fireable, rs EventDataRoundState)
func FireEventUnlock ¶
func FireEventUnlock(fireable events.Fireable, rs EventDataRoundState)
func FireEventVote ¶
func FireEventVote(fireable events.Fireable, vote EventDataVote)
Types ¶
type EventCache ¶
type EventCache interface { Fireable Flush() }
func NewEventCache ¶
func NewEventCache(evsw EventSwitch) EventCache
type EventDataNewBlock ¶
type EventDataNewBlock struct { }
func (EventDataNewBlock) AssertIsTMEventData ¶
func (_ EventDataNewBlock) AssertIsTMEventData()
type EventDataNewBlockHeader ¶
type EventDataNewBlockHeader struct { }
light weight event for benchmarking
func (EventDataNewBlockHeader) AssertIsTMEventData ¶
func (_ EventDataNewBlockHeader) AssertIsTMEventData()
type EventDataRoundState ¶
type EventDataRoundState struct { Height int `json:"height"` Round int `json:"round"` Step string `json:"step"` // private, not exposed to websockets RoundState interface{} `json:"-"` }
NOTE: This goes into the replay WAL
func (EventDataRoundState) AssertIsTMEventData ¶
func (_ EventDataRoundState) AssertIsTMEventData()
type EventDataTx ¶
type EventDataTx struct { Height int `json:"height"` //Tx Tx `json:"tx"` Data data.Bytes `json:"data"` Log string `json:"log"` Code abci.CodeType `json:"code"` Error string `json:"error"` // this is redundant information for now }
All txs fire EventDataTx
func (EventDataTx) AssertIsTMEventData ¶
func (_ EventDataTx) AssertIsTMEventData()
type EventDataVote ¶
type EventDataVote struct { }
func (EventDataVote) AssertIsTMEventData ¶
func (_ EventDataVote) AssertIsTMEventData()
type EventSwitch ¶
type EventSwitch interface { events.EventSwitch }
func NewEventSwitch ¶
func NewEventSwitch() EventSwitch
type Eventable ¶
type Eventable interface {
SetEventSwitch(EventSwitch)
}
type TMEventData ¶
type TMEventData struct {
TMEventDataInner `json:"unwrap"`
}
func (TMEventData) Empty ¶
func (tmr TMEventData) Empty() bool
func (TMEventData) MarshalJSON ¶
func (tmr TMEventData) MarshalJSON() ([]byte, error)
func (*TMEventData) UnmarshalJSON ¶
func (tmr *TMEventData) UnmarshalJSON(data []byte) (err error)
func (TMEventData) Unwrap ¶
func (tmr TMEventData) Unwrap() TMEventDataInner
type TMEventDataInner ¶
implements events.EventData
Click to show internal directories.
Click to hide internal directories.