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

DoorController - only used for GarageDoor device and cannot used as capability for a custom device! More...

#include <DoorController.h>

Inheritance diagram for DoorController< T >:

Public Member Functions

void onDoorState (DoorCallback cb)
 Set callback function for onDoorState request.
 
bool sendDoorStateEvent (bool state, String cause=FSTR_SINRICPRO_PHYSICAL_INTERACTION)
 Send DoorState event to update actual door state on SinricPro Server.
 

Detailed Description

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

DoorController - only used for GarageDoor device and cannot used as capability for a custom device!

Member Function Documentation

◆ onDoorState()

template<typename T >
void onDoorState ( DoorCallback  cb)

Set callback function for onDoorState request.

Parameters
cbFunction pointer to a onDoorState function
Returns
void
See also
DoorStateCallback

◆ sendDoorStateEvent()

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

Send DoorState event to update actual door state on SinricPro Server.

Parameters
statebool true = close
false = open
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