Methods
-
<abstract> offMessage(type, id)
-
Unregister the message handler with the specified id previously registered for the specified type.
Parameters:
Name Type Description typeolympe.dc.Message.MessageType idstring -
<abstract> offSourceEvent(id)
-
Unregisters the callback associated to the specified id.
Parameters:
Name Type Description idstring The ID of the registered callback.
-
<abstract> onMessage(type, handler, contentType [, id])
-
Register a handler for the specified type of message incoming from any source registered in the router.
Parameters:
Name Type Argument Description typeolympe.dc.Message.MessageType handlerolympe.dc.Message.MessageHandler.<T> contentTypefunction idstring <optional>
the handler id
Returns:
The final id d used to register the handler
- Type
- string
-
<abstract> onSourceEvent(callback [, id])
-
Registers a callback to be called when an event is raised by a source.
Parameters:
Name Type Argument Description callbackolympe.dr.Source.EventHandler The function to callback.
idstring <optional>
The id of the callback, if omitted one will be generated.
Returns:
The id of the callback.
- Type
- string
-
<abstract> send(message)
-
Send the specified message from the local datacloud to the global datacloud.
Parameters:
Name Type Description messageolympe.dc.Message The message to send.
Olympe SDK