SinricPro Library
|
Public Types | |
using | MuteCallback = std::function< bool(const String &, bool &)> |
Callback definition for onMute function. More... | |
Public Member Functions | |
void | onMute (MuteCallback cb) |
Set callback function for setMute request. More... | |
bool | sendMuteEvent (bool mute, String cause="PHYSICAL_INTERACTION") |
Send setMute event to SinricPro Server indicating actual mute state. More... | |
using MuteCallback = std::function<bool(const String &, bool &)> |
Callback definition for onMute function.
Gets called when device receive a setMute
request
[in] | deviceId | String which contains the ID of device |
[in] | mute | true mute device false unmute device |
[out] | mute | true device is muted false device is unmuted |
true | request handled properly |
false | request was not handled properly because of some error |
void onMute | ( | MuteCallback | cb | ) |
Set callback function for setMute
request.
cb | Function pointer to a MuteCallback function |
bool sendMuteEvent | ( | bool | mute, |
String | cause = "PHYSICAL_INTERACTION" |
||
) |
Send setMute
event to SinricPro Server indicating actual mute state.
mute | true = device is muted on false = device is unmuted |
cause | (optional) String reason why event is sent (default = "PHYSICAL_INTERACTION" ) |
true | event has been sent successfully |
false | event has not been sent, maybe you sent to much events in a short distance of time |