Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PubSub ¶
type PubSub struct {
// contains filtered or unexported fields
}
PubSub is pubsub messasing object
func (*PubSub) AddSubsrcibe ¶
func (p *PubSub) AddSubsrcibe(topic string, target Subscriber) Subscriber
AddSubsrcibe adds subscribes into a topic
func (*PubSub) Subscribe ¶
func (p *PubSub) Subscribe(topic string) Subscriber
Subscribe subscribes to a topic
func (*PubSub) UnSubscribe ¶
func (p *PubSub) UnSubscribe(topic string, target Subscriber)
UnSubscribe unsubscribes topic
type Subscriber ¶
type Subscriber interface {
Read() <-chan interface{}
}
Subscriber is interface that wraps the Read methods
Click to show internal directories.
Click to hide internal directories.