Function Decorators¶
@setHook¶
- @setHook(hook)¶
This decorator should precede the definition of any function to be triggered by a “hooked” event in the SNAP environment, such as when a node reboots or when a pin changes state.
- Parameters
hook – Value of one of the SNAP Hooks
See also
User Guide on Event-Driven Programming
List of SNAP Hooks