mirror of
https://github.com/tendermint/tendermint.git
synced 2026-01-06 13:26:23 +00:00
types: rename and extend the EventData interface (#7687)
This is the interface shared by types that can be used as event data in, for example, subscriptions via the RPC. To be compatible with the RPC service, data need to support JSON encoding. Require this as part of the interface.
This commit is contained in:
@@ -88,8 +88,10 @@ var (
|
||||
|
||||
// ENCODING / DECODING
|
||||
|
||||
// TMEventData implements events.EventData.
|
||||
type TMEventData interface{}
|
||||
// EventData is satisfied by types that can be published as event data.
|
||||
type EventData interface {
|
||||
jsontypes.Tagged
|
||||
}
|
||||
|
||||
func init() {
|
||||
jsontypes.MustRegister(EventDataBlockSyncStatus{})
|
||||
|
||||
Reference in New Issue
Block a user