1 // Copyright (C) 2007-2024 CEA, EDF, OPEN CASCADE
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 // File : PyConsole_Request.h
20 // Author : Vadim SANDLER (OPEN CASCADE), Adrien Bruneton (CEA/DEN)
22 #ifndef PYCONSOLE_REQUEST_H
23 #define PYCONSOLE_REQUEST_H
25 #include "PyInterp_Request.h"
28 #include <QStringList>
31 class PyInterp_Interp;
33 class PyConsole_ExecCommand : public PyInterp_LockRequest
36 PyConsole_ExecCommand( PyInterp_Interp*, const QString&, QObject*, bool = false );
39 virtual void execute();
40 virtual QEvent* createEvent();
43 QString myCommand; //!< Python command
44 int myState; //!< Python command execution status
47 class PyConsole_CompletionCommand : public PyInterp_LockRequest
50 PyConsole_CompletionCommand( PyInterp_Interp*, const QString&, const QString&, QObject*, bool = false );
53 virtual void execute();
54 virtual QEvent* createEvent();
57 QString myDirArg; //!< String to be passed to the dir() comman
58 QString myStartMatch; //!< Beginning of the command (as typed by the user)
59 bool myStatus; //!< Status of completion command execution
60 QStringList myMatches; //!< Matches
61 QString myDoc; //!< Docstring of single match
64 #endif // PYCONSOLE_REQUEST_H