MCPcopy Create free account

hub / github.com/alash3al/go-pubsub / functions

Functions30 in github.com/alash3al/go-pubsub

↓ 5 callersMethodSubscribe
Subscribe subscribes the specified subscriber "s" to the specified list of topic(s)
broker.go:43
↓ 4 callersMethodGetID
GetID return the subscriber id
subscriber.go:41
↓ 4 callersMethodSubscribers
Subscribers Get the subscribers count
broker.go:102
↓ 3 callersMethodAttach
Attach Create a new subscriber and register it into our main broker
broker.go:28
↓ 3 callersMethodGetMessages
GetMessages returns a channel of *Message to listen on
subscriber.go:84
↓ 3 callersMethodGetTopics
GetTopics Returns a slice of topics
broker.go:109
↓ 3 callersFunctionsend
(topic string, broker *pubsub.Broker)
example/example2.go:48
↓ 2 callersMethodBroadcast
Broadcast broadcast the specified payload to all the topic(s) subscribers
broker.go:81
↓ 2 callersFunctionreceive
(id string, ch <-chan *pubsub.Message)
example/example.go:61
↓ 1 callersMethodAddTopic
AddTopic Adds a new topic to the subscriber
subscriber.go:57
↓ 1 callersMethodGetPayload
GetPayload Get the payload of the current message
message.go:16
↓ 1 callersFunctionNewSubscriber
NewSubscriber returns a new subscriber
subscriber.go:24
↓ 1 callersMethodRemoveTopic
RemoveTopic Removes a topic from the subscriber
subscriber.go:64
↓ 1 callersMethodSignal
Signal sends a message to subscriber
subscriber.go:89
↓ 1 callersMethodUnsubscribe
Unsubscribe Unsubscribe the specified subscriber from the specified topic(s)
broker.go:58
↓ 1 callersMethoddestroy
close the underlying channels/resources
subscriber.go:100
↓ 1 callersFunctiongetPrice
()
example/example2.go:44
↓ 1 callersFunctiongetPrice
()
example/example.go:47
↓ 1 callersFunctionreceive
(id string, ch <-chan *pubsub.Message)
example/example2.go:58
↓ 1 callersFunctionsend
(broker *pubsub.Broker)
example/example.go:51
MethodDetach
Detach remove the specified subscriber from the broker
broker.go:72
MethodGetCreatedAt
GetCreatedAt Get the creation time of this message
message.go:21
MethodGetCreatedAt
GetCreatedAt return `time.Time` of the creation time
subscriber.go:49
MethodGetTopic
GetTopic Return the topic of the current message
message.go:11
MethodGetTopics
GetTopics return slice of subscriber topics
subscriber.go:71
FunctionNewBroker
NewBroker Create new broker
broker.go:18
Functioninit
()
example/example2.go:12
Functioninit
()
example/example.go:12
Functionmain
()
example/example2.go:16
Functionmain
()
example/example.go:16