github.com/onflow/flow-go@v0.35.7-crescendo-preview.23-atree-inlining/network/subscription.go (about) 1 package network 2 3 import "github.com/onflow/flow-go/network/channels" 4 5 type SubscriptionManager interface { 6 // Register registers an engine on the channel into the subscription manager. 7 Register(channel channels.Channel, engine MessageProcessor) error 8 9 // Unregister removes the engine associated with a channel. 10 Unregister(channel channels.Channel) error 11 12 // GetEngine returns engine associated with a channel. 13 GetEngine(channel channels.Channel) (MessageProcessor, error) 14 15 // Channels returns all the channels registered in this subscription manager. 16 Channels() channels.ChannelList 17 }