SinricPro Library
Loading...
Searching...
No Matches
LockController< T >

LockController. More...

#include <LockController.h>

Inheritance diagram for LockController< T >:

Public Member Functions

void onLockState (LockStateCallback cb)
 Set callback function for setLockState request.
 
bool sendLockStateEvent (bool state, String cause=FSTR_SINRICPRO_PHYSICAL_INTERACTION)
 Send lockState event to SinricPro Server indicating actual lock state.
 

Detailed Description

template<typename T>
class SINRICPRO_3_0_0::LockController< T >

LockController.

Member Function Documentation

◆ onLockState()

template<typename T >
void onLockState ( LockStateCallback  cb)

Set callback function for setLockState request.

Parameters
cbFunction pointer to a LockStateCallback function
Returns
void
See also
LockStateCallback

◆ sendLockStateEvent()

template<typename T >
bool sendLockStateEvent ( bool  state,
String  cause = FSTR_SINRICPRO_PHYSICAL_INTERACTION 
)

Send lockState event to SinricPro Server indicating actual lock state.

Parameters
statetrue = device is locked
false = device is unlocked
cause(optional) String reason why event is sent (default = "PHYSICAL_INTERACTION")
Returns
the success of sending the even
Return values
trueevent has been sent successfully
falseevent has not been sent, maybe you sent to much events in a short distance of time