Eclipse SUMO - Simulation of Urban MObility
|
Abstract dialog for tools. More...
#include <GNERunPythonTool.h>
Public Member Functions | |
void | abortTool () |
abort tool running | |
bool | errorOccurred () const |
check if during execution an error was Occurred | |
GNERunPythonTool (GNERunPythonToolDialog *runToolDialog, MFXSynchQue< GUIEvent * > &eq, FXEX::MFXThreadEvent &ev) | |
Constructor. | |
bool | isRunning () const |
check if tool is running | |
void | runTool (const GNEPythonTool *tool) |
run tool | |
~GNERunPythonTool () | |
destructor | |
Protected Types | |
enum | { ID_THREAD_EVENT } |
FOX declaration. More... | |
Protected Member Functions | |
long | onThreadEvent (FXObject *, FXSelector, void *) |
long | onThreadSignal (FXObject *, FXSelector, void *) |
void | signal () |
void | signal (FXuint seltype) |
Static Protected Member Functions | |
static void | sleep (long ms) |
Protected Attributes | |
FXApp * | myApp = nullptr |
pointer to APP | |
MFXInterThreadEventClient * | myClient = nullptr |
thread client | |
Private Member Functions | |
GNERunPythonTool (const GNERunPythonTool &)=delete | |
Invalidated copy constructor. | |
GNERunPythonTool & | operator= (const GNERunPythonTool &)=delete |
Invalidated assignment operator. | |
FXint | run () |
starts the thread. The thread ends after the tool is finished | |
Private Attributes | |
FXEX::MFXThreadEventHandle | event |
event | |
bool | myErrorOccurred = false |
flag for check if during execution an error was Occurred | |
MFXSynchQue< GUIEvent * > & | myEventQueue |
event Queue | |
FXEX::MFXThreadEvent & | myEventThrow |
event throw | |
FILE * | myPipe = nullptr |
pipe file | |
const GNEPythonTool * | myPythonTool = nullptr |
tool | |
bool | myRunning = false |
flag for check if tool is running | |
Abstract dialog for tools.
Definition at line 39 of file GNERunPythonTool.h.
|
inherited |
GNERunPythonTool::GNERunPythonTool | ( | GNERunPythonToolDialog * | runToolDialog, |
MFXSynchQue< GUIEvent * > & | eq, | ||
FXEX::MFXThreadEvent & | ev | ||
) |
Constructor.
Definition at line 33 of file GNERunPythonTool.cpp.
GNERunPythonTool::~GNERunPythonTool | ( | ) |
destructor
Definition at line 40 of file GNERunPythonTool.cpp.
|
privatedelete |
Invalidated copy constructor.
void GNERunPythonTool::abortTool | ( | ) |
abort tool running
Definition at line 54 of file GNERunPythonTool.cpp.
References ERROR_OCCURRED, myErrorOccurred, myEventQueue, myEventThrow, myRunning, MFXSynchQue< T, Container >::push_back(), FXEX::MFXThreadEvent::signal(), and TL.
Referenced by GNERunPythonToolDialog::onCmdAbort(), and GNERunPythonToolDialog::onCmdClose().
bool GNERunPythonTool::errorOccurred | ( | ) | const |
check if during execution an error was Occurred
Definition at line 75 of file GNERunPythonTool.cpp.
References myErrorOccurred.
bool GNERunPythonTool::isRunning | ( | ) | const |
check if tool is running
Definition at line 69 of file GNERunPythonTool.cpp.
References myRunning.
Referenced by GNERunPythonToolDialog::updateDialog().
|
inherited |
Definition at line 128 of file MFXSingleEventThread.cpp.
References MFXInterThreadEventClient::eventOccurred(), and MFXSingleEventThread::myClient.
Referenced by FXDEFMAP().
|
inherited |
Definition at line 113 of file MFXSingleEventThread.cpp.
References MFXSingleEventThread::event, PIPE_READ, FXEX::SEL_THREAD, and UNUSED_PARAMETER.
Referenced by FXDEFMAP().
|
privatedelete |
Invalidated assignment operator.
|
privatevirtual |
starts the thread. The thread ends after the tool is finished
Reimplemented from MFXSingleEventThread.
Definition at line 81 of file GNERunPythonTool.cpp.
References ERROR_OCCURRED, GNEPythonTool::getCommand(), MESSAGE_OCCURRED, myErrorOccurred, myEventQueue, myEventThrow, myPipe, myPythonTool, myRunning, OUTPUT_OCCURRED, MFXSynchQue< T, Container >::push_back(), FXEX::MFXThreadEvent::signal(), TL, TOOL_ENDED, and StringUtils::transcodeToLocal().
void GNERunPythonTool::runTool | ( | const GNEPythonTool * | tool | ) |
run tool
Definition at line 44 of file GNERunPythonTool.cpp.
References myErrorOccurred, myPythonTool, and myRunning.
Referenced by GNERunPythonToolDialog::onCmdRerun(), and GNERunPythonToolDialog::runTool().
|
inherited |
Definition at line 89 of file MFXSingleEventThread.cpp.
References MFXSingleEventThread::event, PIPE_WRITE, FXEX::SEL_THREAD, and UNUSED_PARAMETER.
|
inherited |
Definition at line 101 of file MFXSingleEventThread.cpp.
References MFXSingleEventThread::event, PIPE_WRITE, and UNUSED_PARAMETER.
|
staticinherited |
Definition at line 142 of file MFXSingleEventThread.cpp.
Referenced by GUIRunThread::deleteSim(), GUIApplicationWindow::loadOnStartup(), GUISUMOAbstractView::makeSnapshot(), and GUIRunThread::tryStep().
|
privateinherited |
event
Definition at line 72 of file MFXSingleEventThread.h.
Referenced by MFXSingleEventThread::onThreadSignal(), MFXSingleEventThread::signal(), MFXSingleEventThread::signal(), and MFXSingleEventThread::~MFXSingleEventThread().
|
protectedinherited |
pointer to APP
Definition at line 65 of file MFXSingleEventThread.h.
Referenced by GUIRunThread::run(), and MFXSingleEventThread::~MFXSingleEventThread().
|
protectedinherited |
thread client
Definition at line 68 of file MFXSingleEventThread.h.
Referenced by MFXSingleEventThread::onThreadEvent().
|
private |
flag for check if during execution an error was Occurred
Definition at line 68 of file GNERunPythonTool.h.
Referenced by abortTool(), errorOccurred(), run(), and runTool().
|
private |
|
private |
|
private |
|
private |
|
private |
flag for check if tool is running
Definition at line 65 of file GNERunPythonTool.h.
Referenced by abortTool(), isRunning(), run(), and runTool().