Eidolon
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
DelayThread Class Reference

Inherits Thread.

Collaboration diagram for DelayThread:
Collaboration graph

Public Member Functions

def __init__ (self, delay, target)
 
def stop (self)
 
def callTargetDelayed (self, args, kwargs)
 
def getCurrentDelay (self)
 
def decCurrentDelay (self)
 
def run (self)
 

Static Public Member Functions

def callGlobalTarget (delay, target, args, kwargs)
 
def removeGlobalTarget (target)
 

Public Attributes

 target
 
 args
 
 kwargs
 
 delay
 
 decDelayVal
 
 currentDelay
 
 evt
 
 daemon
 

Static Public Attributes

 globalDelayMap
 

Detailed Description

Calls a target callable with the given args after a delay time has elapsed, which is reset to the full time if
subsequent call request come before the call occurs. This ensures that a single call to the target happens even
if multiple requests come in during the delay period, allowing for example update tasks to be scheduled when UI
elements are manipulated and then deferred if further operations are performed soon after.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  delay,
  target 
)

Member Function Documentation

◆ callGlobalTarget()

def callGlobalTarget (   delay,
  target,
  args,
  kwargs 
)
static
Here is the call graph for this function:

◆ callTargetDelayed()

def callTargetDelayed (   self,
  args,
  kwargs 
)
Here is the caller graph for this function:

◆ decCurrentDelay()

def decCurrentDelay (   self)
Here is the caller graph for this function:

◆ getCurrentDelay()

def getCurrentDelay (   self)
Here is the caller graph for this function:

◆ removeGlobalTarget()

def removeGlobalTarget (   target)
static

◆ run()

def run (   self)
Here is the call graph for this function:

◆ stop()

def stop (   self)

Member Data Documentation

◆ args

args

◆ currentDelay

currentDelay

◆ daemon

daemon

◆ decDelayVal

decDelayVal

◆ delay

delay

◆ evt

evt

◆ globalDelayMap

globalDelayMap
static

◆ kwargs

kwargs

◆ target

target

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