#include <SPythonInterpreter.hxx>
Public Member Functions |
| | SPythonInterpreter (PyObject *globals, PyObject *locals) |
| void | initialize () |
| bool | run (const char *str, bool &isSPython) |
| bool | finishSession () |
Static Public Member Functions |
| static std::string | strip (const std::string &s) |
| static bool | isSpythonManipulationNeeded (const std::string &s, std::string &pythonLines) |
| static bool | isCandidateParenthesis (const std::string &s, std::size_t p1, std::size_t &n) |
Static Public Attributes |
| static const int | NB_OF_INDENT = 7 |
| static const char * | INDENT_TOKEN [] = {"def","class","for","if","while","try","except"} |
| static const char | NUMBERS [] = "0123456789" |
Private Member Functions |
| bool | checkIndentCoherency (const std::string &s, std::size_t p) |
| void | checkPythonInterp (PyObject *r) |
| bool | isIndenter (const std::string &s, std::size_t p) |
| bool | isSPythonExpression (const std::string &s) |
| bool | isSPythonExpressionLev1 (const std::string &s, std::string &result) |
Private Attributes |
| std::string | _cmd |
| std::set< int > | _indent_pos |
| bool | _indent_must_change |
| PyObject * | _glob |
| PyObject * | _loc |
Constructor & Destructor Documentation
| SPythonInterpreter::SPythonInterpreter |
( |
PyObject * |
globals, |
|
|
PyObject * |
locals |
|
) |
| |
Member Function Documentation
| void SPythonInterpreter::initialize |
( |
| ) |
|
| bool SPythonInterpreter::run |
( |
const char * |
str, |
|
|
bool & |
isSPython |
|
) |
| |
| bool SPythonInterpreter::finishSession |
( |
| ) |
|
| bool SPythonInterpreter::checkIndentCoherency |
( |
const std::string & |
s, |
|
|
std::size_t |
p |
|
) |
| [private] |
| void SPythonInterpreter::checkPythonInterp |
( |
PyObject * |
r | ) |
[private] |
| bool SPythonInterpreter::isIndenter |
( |
const std::string & |
s, |
|
|
std::size_t |
p |
|
) |
| [private] |
| bool SPythonInterpreter::isSPythonExpression |
( |
const std::string & |
s | ) |
[private] |
| bool SPythonInterpreter::isSPythonExpressionLev1 |
( |
const std::string & |
s, |
|
|
std::string & |
result |
|
) |
| [private] |
| std::string SPythonInterpreter::strip |
( |
const std::string & |
s | ) |
[static] |
| static bool ParaMEDMEM.SPythonInterpreter.isSpythonManipulationNeeded |
( |
const std::string & |
s, |
|
|
std::string & |
pythonLines |
|
) |
| [static] |
| bool SPythonInterpreter::isCandidateParenthesis |
( |
const std::string & |
s, |
|
|
std::size_t |
p1, |
|
|
std::size_t & |
n |
|
) |
| [static] |
Field Documentation