Terarea  2
The automation project
Loading...
Searching...
No Matches
src.lib.components.background_tasks Namespace Reference

Data Structures

class  BackgroundTasks
 

Functions

None test_current_date (*Any args)
 
None hello_world ()
 
None pending_world ()
 
None goodbye_world ()
 

Variables

int SUCCES = 0
 
int ERROR = 84
 
bool DEBUG = True
 
bool KIND_KILL = True
 
int NB_REPEATS = 2
 
str TRIGGER = "interval"
 
int SECONDS = 2
 
int NB_FUNCTIONS = 5
 
 MAIN_THREAD_DELAY = int((SECONDS*NB_FUNCTIONS)*NB_REPEATS)
 
 BTI
 
 status
 

Function Documentation

◆ goodbye_world()

None src.lib.components.background_tasks.goodbye_world ( )
_summary_
    This is a test function that will print "Goodbye, World!"

Definition at line 361 of file background_tasks.py.

◆ hello_world()

None src.lib.components.background_tasks.hello_world ( )
_summary_
    This is a test function that will print "Hello, World!"

Definition at line 349 of file background_tasks.py.

◆ pending_world()

None src.lib.components.background_tasks.pending_world ( )
_summary_
    This is a test function that will print "Pending, World!"

Definition at line 355 of file background_tasks.py.

◆ test_current_date()

None src.lib.components.background_tasks.test_current_date ( *Any args)
_summary_
    This is a test function that will print the current date.
Args:
    date (datetime): _description_

Definition at line 334 of file background_tasks.py.

Variable Documentation

◆ BTI

src.lib.components.background_tasks.BTI
Initial value:
1= BackgroundTasks(
2 success=SUCCES,
3 error=ERROR,
4 debug=DEBUG
5 )

Definition at line 394 of file background_tasks.py.

◆ DEBUG

bool src.lib.components.background_tasks.DEBUG = True

Definition at line 376 of file background_tasks.py.

◆ ERROR

int src.lib.components.background_tasks.ERROR = 84

Definition at line 375 of file background_tasks.py.

◆ KIND_KILL

bool src.lib.components.background_tasks.KIND_KILL = True

Definition at line 377 of file background_tasks.py.

◆ MAIN_THREAD_DELAY

src.lib.components.background_tasks.MAIN_THREAD_DELAY = int((SECONDS*NB_FUNCTIONS)*NB_REPEATS)

Definition at line 382 of file background_tasks.py.

◆ NB_FUNCTIONS

int src.lib.components.background_tasks.NB_FUNCTIONS = 5

Definition at line 381 of file background_tasks.py.

◆ NB_REPEATS

int src.lib.components.background_tasks.NB_REPEATS = 2

Definition at line 378 of file background_tasks.py.

◆ SECONDS

int src.lib.components.background_tasks.SECONDS = 2

Definition at line 380 of file background_tasks.py.

◆ status

src.lib.components.background_tasks.status
Initial value:
1= BTI.safe_add_task(
2 func=test_current_date,
3 args=(datetime.now,),
4 kwargs=None,
5 trigger=TRIGGER,
6 seconds=SECONDS
7 )

Definition at line 402 of file background_tasks.py.

◆ SUCCES

int src.lib.components.background_tasks.SUCCES = 0

Definition at line 374 of file background_tasks.py.

◆ TRIGGER

str src.lib.components.background_tasks.TRIGGER = "interval"

Definition at line 379 of file background_tasks.py.