setCallbackReceivedMessage method

void setCallbackReceivedMessage(
  1. String callbackName,
  2. dynamic callbackReceivedMessage(
    1. Device
    )
)

Sets callbackReceivedMessage callback that executes every time a message is received.

Implementation

void setCallbackReceivedMessage(
    String callbackName, Function(Device) callbackReceivedMessage) {
  this.callbackReceivedMessage[callbackName] = callbackReceivedMessage;
}