exports

exports

new exports(callbacks)

Create TopicFnd.
Source:
Parameters:
Name Type Description
callbacks TopicFnd.Callbacks Callbacks to receive various events.

exports

new exports(fn, imageUrl, imageMimeType, note)

Create a new contact card.
Source:
Parameters:
Name Type Description
fn string Full name.
imageUrl string Avatar URL or data URL.
imageMimeType string MIME type of the avatar image.
note string Notes or comments about the contact.

exports

new exports(name, callbacksopt)

Create topic.
Source:
Parameters:
Name Type Attributes Description
name string Name of the topic to create.
callbacks Object <optional>
Object with various event callbacks.
Name Type Description
onData onData Callback which receives a {data} message.
onMeta function Callback which receives a {meta} message.
onPres function Callback which receives a {pres} message.
onInfo function Callback which receives an {info} message.
onMetaDesc function Callback which receives changes to topic description desc.
onMetaSub function Called for a single subscription record change.
onSubsUpdated function Called after a batch of subscription changes have been received and cached.
onDeleteTopic function Called after the topic is deleted.
onAllMessagesReceived function Called when all requested {data} messages have been received.