Skip to content
Paul Weng edited this page May 2, 2013 · 2 revisions

This page shows the API for Subscriber

Subscriber.Subscriber(SubscriberServiceIPV4, SubscriberServicePort)

  • Initialise the subscriber with the subscriber server's IPV4 and Port
  • Attributes: SubscriberServiceIPV4 (String), SubscriberServicePort (int)

Subscriber.subscribeTo(Topic, FunctionBindTo)

  • Register the subscriber with the topic to listen to and a function to execute whenever there is data available
  • Attributes: Topic (String), FunctionBindTo (Function)

Subscriber.unSubscribe()

  • Unsubscribe to the current topic

Subscriber.getTopic()

  • Get the current topic subscribed to.
  • Return type: String

Clone this wiki locally