Module EDAction :: Class EDAction
[hide private]
[frames] | no frames]

Class EDAction

source code

        object --+        
                 |        
 EDObject.EDObject --+    
                     |    
   EDLogging.EDLogging --+
                         |
        object --+       |
                 |       |
threading._Verbose --+   |
                     |   |
      threading.Thread --+
                         |
                        EDAction
Known Subclasses:

This class is taking care of executing the EDNA plugin and application workflow preProcess - process - postProcess. The detailed workflow looks like this:

preProcess if not failure: slotPreProcess if not failure: process if not failure: slotProcess if not failure: postProcess if not failure: slotPostProcess if not failure: slotSUCCESS if failure: slotFAILURE Always: finally Process

Instance Methods [hide private]
 
__init__(self)
Constructor of the main pure virtual class.
source code
 
executeKernel(self) source code
 
synchronize(self)
Wait for the thread to finish.
source code
 
isTimeOut(self) source code
 
hasTimedOut(self, _bTimeout)
Enforce the timeout state
source code
 
isFailure(self) source code
 
setFailure(self) source code
 
run(self) source code
 
executeAction(self, _edObject=None) source code
 
executeActionSynchronous(self, _edObject=None) source code
 
connectPreProcess(self, _oMethod) source code
 
connectProcess(self, _oMethod) source code
 
connectPostProcess(self, _oMethod) source code
 
connectSUCCESS(self, _oMethod) source code
 
connectFAILURE(self, _oMethod) source code
 
connectFinallyProcess(self, _oMethod) source code
 
isRunning(self) source code
 
isEnded(self) source code
 
isStarted(self) source code
 
setTimeOut(self, _fTimeOut)
Sets the time out
source code
 
getTimeOut(self)
Returns the time out
source code
 
addExtraTime(self, _fExtraTime)
Allows to incread the timeout of a plugin while it is running
source code
 
getDefaultTimeOut(self)
Returns the time out
source code
 
getSlotSUCCESS(self) source code
 
getSlotFAILURE(self) source code
 
preProcess(self, _edObject=None) source code
 
process(self, _edObject=None) source code
 
postProcess(self, _edObject=None) source code
 
abort(self, _edObject=None) source code
 
finallyProcess(self, _edObject=None) source code
 
execute(self, _edObject=None) source code
 
executeSynchronous(self, _edObject=None) source code
 
setLogTiming(self, _bValue)
Force this action to log it's timing to file
source code
 
getLogTiming(self) source code

Inherited from EDLogging.EDLogging: ASSERT, DEBUG, ERROR, WARNING, error, isVerboseDebug, log, screen, setAllLogLevels, setLogFileName, setLogFileOff, setLogLevel, setTestOff, setTestOn, setVerboseDebugOff, setVerboseDebugOn, setVerboseOff, setVerboseOn, unitTest, warning, writeErrorTrace

Inherited from EDObject.EDObject: getClassName, getId, getRunTime, getSemaphoreValue, getTimeEnd, getTimeInit, locked, setTimeEnd, setTimeInit, synchronizeOff, synchronizeOn

Inherited from threading.Thread: __repr__, getName, isAlive, isDaemon, is_alive, join, setDaemon, setName, start

Inherited from threading.Thread (private): _reset_internal_locks, _set_daemon, _set_ident

Inherited from threading._Verbose (private): _note

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]

Inherited from EDLogging.EDLogging (private): _EDObject__iId_class

Properties [hide private]
  logTiming

Inherited from threading.Thread: daemon, ident, name

Inherited from threading.Thread (private): _block

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

source code 

Constructor of the main pure virtual class.
This constructor implements:
- the creation of the semaphore
- definition of timer object (uninitialized as potentially not used)

Overrides: object.__init__
(inherited documentation)

synchronize(self)

source code 

Wait for the thread to finish. Since the time out is used by e.g. EDPluginExecProcessScript we add an extra second in order to allow the subclasses to handle the time out - without this extra second it's the EDAction class who time-outs first.

Note that this does not in any case add time to the execution, because the extra second is only used for time-outs. The method returns immediately once the thread has finished.

hasTimedOut(self, _bTimeout)

source code 

Enforce the timeout state

Parameters:
  • _bTimeout (boolean) - if you think you can force this !

run(self)

source code 
Overrides: threading.Thread.run

addExtraTime(self, _fExtraTime)

source code 

Allows to incread the timeout of a plugin while it is running

Parameters:
  • _fExtraTime (float) - extra time to be added to timeout

Property Details [hide private]

logTiming

Get Method:
getLogTiming(self)
Set Method:
setLogTiming(self, _bValue) - Force this action to log it's timing to file