Sets a callback function to be called whenever the state specified in state_key changes.
The return value callbackSwitch is a callback switch. You can activate the listener with callbackSwitch.activate()
and deactive with callbackSwitch.deactivate().
Example Usage:
Sets a callback function to be called whenever the state specified in state_key changes. The return value callbackSwitch is a callback switch. You can activate the listener with callbackSwitch.activate() and deactive with callbackSwitch.deactivate(). Example Usage: