Type alias OnMessageCallback

OnMessageCallback: ((topic, payload, dup, qos, retain) => void)

Type declaration

    • (topic, payload, dup, qos, retain): void
    • Function called upon receipt of a Publish message on a subscribed topic.

      Parameters

      • topic: string

        The topic to which the message was published.

      • payload: ArrayBuffer

        The payload data.

      • dup: boolean

        DUP flag. If true, this might be re-delivery of an earlier attempt to send the message.

      • qos: QoS

        Quality of Service used to deliver the message.

      • retain: boolean

        Retain flag. If true, the message was sent as a result of a new subscription being made by the client. *

      Returns void

Generated using TypeDoc