Undocumented
Method | __init__ |
Undocumented |
Method | add |
Listener for process events. MUST be called before ProcessMonitor is running.See ProcessListener class. @param l: listener instance @type l: L{ProcessListener} |
Method | do |
Execute tasks that need to be run in the main thread. Must be called from main thread. |
Method | get |
@return [str]: list of active process names |
Method | get |
@return: process registered under \x07 name, or None @rtype: L{Process} |
Method | get |
@return: Two lists, where first list of active process names along with the number of times that process has been spawned. Second list contains dead process names and their spawn count. @rtype: [[(str, int),], [(str,int),]]... |
Method | has |
@return: True if ProcessMonitor has tasks that need to be run in the main thread @rtype: bool |
Method | has |
@return: True if process is still be monitored. If False, process has died or was never registered with process @rtype: bool |
Method | kill |
Kill process that matches name. NOTE: a killed process will continue to show up as active until the process monitor thread has caught that it has died. @param name: Process name @type name: str @return: True if a process named name was removed from process monitor... |
Method | mainthread |
run() occurs in a separate thread and cannot do certain signal-related work. The main thread of the application must call mainthread_spin() or mainthread_spin_once() in order to perform these jobs. mainthread_spin() blocks until the process monitor is complete. |
Method | mainthread |
run() occurs in a separate thread and cannot do certain signal-related work. The main thread of the application must call mainthread_spin() or mainthread_spin_once() in order to perform these jobs. |
Method | register |
Register process with L{ProcessMonitor} @param p: Process @type p: L{Process} @raise RLException: if process with same name is already registered |
Method | register |
Register core process with ProcessMonitor. Coreprocesses have special shutdown semantics. They are killed after all other processes, in reverse order in which they are added. @param p Process @type p: L{Process} @raise RLException: if process with same name is already registered... |
Method | registrations |
Inform the process monitor that registrations are complete. After the registrations_complete flag is set, process monitor will exit if there are no processes left to monitor. |
Method | run |
thread routine of the process monitor. NOTE: you must still call mainthread_spin or mainthread_spin_once() from the main thread in order to pick up main thread work from the process monitor. |
Method | shutdown |
Shutdown the process monitor thread |
Method | unregister |
Undocumented |
Instance Variable | core |
Undocumented |
Instance Variable | daemon |
Undocumented |
Instance Variable | dead |
Undocumented |
Instance Variable | done |
Undocumented |
Instance Variable | is |
Undocumented |
Instance Variable | listeners |
Undocumented |
Instance Variable | plock |
Undocumented |
Instance Variable | procs |
Undocumented |
Instance Variable | reacquire |
Undocumented |
Method | _post |
Undocumented |
Method | _run |
Internal run loop of ProcessMonitor |
Instance Variable | _registrations |
Undocumented |
Listener for process events. MUST be called before ProcessMonitor is running.See ProcessListener class. @param l: listener instance @type l: L{ProcessListener}
@return: Two lists, where first list of active process names along with the number of times that process has been spawned. Second list contains dead process names and their spawn count. @rtype: [[(str, int),], [(str,int),]]
@return: True if process is still be monitored. If False, process has died or was never registered with process @rtype: bool
Kill process that matches name. NOTE: a killed process will continue to show up as active until the process monitor thread has caught that it has died. @param name: Process name @type name: str @return: True if a process named name was removed from process monitor. A process is considered killed if its stop() method was called. @rtype: bool
run() occurs in a separate thread and cannot do certain signal-related work. The main thread of the application must call mainthread_spin() or mainthread_spin_once() in order to perform these jobs. mainthread_spin() blocks until the process monitor is complete.
run() occurs in a separate thread and cannot do certain signal-related work. The main thread of the application must call mainthread_spin() or mainthread_spin_once() in order to perform these jobs.
Register process with L{ProcessMonitor} @param p: Process @type p: L{Process} @raise RLException: if process with same name is already registered
Register core process with ProcessMonitor. Coreprocesses have special shutdown semantics. They are killed after all other processes, in reverse order in which they are added. @param p Process @type p: L{Process} @raise RLException: if process with same name is already registered
Inform the process monitor that registrations are complete. After the registrations_complete flag is set, process monitor will exit if there are no processes left to monitor.