iota  1.0.0
Flexible, pipeline-based input handling.
Static Public Attributes | List of all members
iota.Events Class Reference

Define high-level events for polling. More...

Inheritance diagram for iota.Events:

Static Public Attributes

int ALWAYS = 0
 ALWAYS run the pipeline, no matter what. More...
 
int CHANGED = 1
 Only run the pipeline when the input has CHANGED. More...
 
int PRESSED = 2
 Run the pipeline when a PRESSED action has been detected. More...
 
int RELEASED = 3
 The counterpart event to the PRESSED action. More...
 
int TAPPED = 4
 When the button/range input has been tapped, but not held sufficiently long enough to be considered a PRESSED event. More...
 

Detailed Description

Define high-level events for polling.

This enum defines 5, higher-level event patterns that the poller can recognize. This includes ALWAYS, CHANGED, PRESSED, RELEASED, and TAPPED. Passing anything other than these values in the second parameter of the Poller.on() function will result in an error.

Definition at line 213 of file iota.py.

Member Data Documentation

◆ ALWAYS

int iota.Events.ALWAYS = 0
static

ALWAYS run the pipeline, no matter what.

This is not very efficient.

Definition at line 217 of file iota.py.

◆ CHANGED

int iota.Events.CHANGED = 1
static

Only run the pipeline when the input has CHANGED.

When in doubt, use this.

Definition at line 221 of file iota.py.

◆ PRESSED

int iota.Events.PRESSED = 2
static

Run the pipeline when a PRESSED action has been detected.

This descriptor only applies to boolean and range values. You can use custom classes, you just have to be able to make it work with the built-in float() function.

Definition at line 227 of file iota.py.

◆ RELEASED

int iota.Events.RELEASED = 3
static

The counterpart event to the PRESSED action.

With every press comes a release.

Definition at line 231 of file iota.py.

◆ TAPPED

int iota.Events.TAPPED = 4
static

When the button/range input has been tapped, but not held sufficiently long enough to be considered a PRESSED event.

Definition at line 235 of file iota.py.


The documentation for this class was generated from the following file: