BALL
1.4.79
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
include
BALL
PYTHON
pyInterpreter.h
Go to the documentation of this file.
1
// -*- Mode: C++; tab-width: 2; -*-
2
// vi: set ts=2:
3
//
4
// $Id: pyInterpreter.h,v 1.15.18.1 2007/03/25 21:25:21 oliver Exp $
5
//
6
7
#ifndef BALL_PYTHON_PYINTERPRETER_H
8
#define BALL_PYTHON_PYINTERPRETER_H
9
10
#ifndef BALL_COMMON_H
11
# include <
BALL/common.h
>
12
#endif
13
14
#ifndef BALL_DATAYPE_STRING_H
15
# include <
BALL/DATATYPE/string.h
>
16
#endif
17
18
#ifndef BALL_SYSTEM_PATH_H
19
# include <
BALL/SYSTEM/path.h
>
20
#endif
21
22
#include <vector>
23
24
#include <QtCore/QList>
25
#include <QtCore/QPair>
26
#include <QtCore/QString>
27
28
namespace
BALL
29
{
36
class
BALL_EXPORT
PyInterpreter
37
{
38
private
:
39
// We don't want anybody to instantiate this!
40
PyInterpreter
();
41
~
PyInterpreter
() {}
42
43
public
:
46
typedef
std::vector<String>
PathStrings
;
49
52
61
static
void
initialize();
62
67
static
void
finalize();
68
72
static
bool
isInitialized();
73
75
static
void
setSysPath(
const
PathStrings
& path_strings);
76
78
static
const
PathStrings
& getSysPath();
79
81
static
bool
isValid
() {
return
valid_;}
82
84
static
String
getStartupLog
() {
return
start_log_;}
85
87
88
96
static
String
run(
const
String
& s,
bool
& result);
97
101
static
String
runFile(
const
String
& filename)
102
throw
(
Exception::FileNotFound
);
103
110
static
bool
importModule(
const
String
& module_name);
112
113
static
bool
execute(
const
QString& module,
const
QString& func,
const
QList<QPair<QString, QString> >& params);
114
115
protected
:
116
static
PathStrings
sys_path_
;
117
static
bool
valid_
;
118
static
String
start_log_
;
119
};
120
121
}
// namespace BALL
122
123
#endif // BALL_PYTHON_PYINTERPRETER_H
BALL::PyInterpreter::sys_path_
static PathStrings sys_path_
Definition:
pyInterpreter.h:116
BALL::String
Definition:
string.h:61
BALL::PyInterpreter::start_log_
static String start_log_
Definition:
pyInterpreter.h:118
BALL::PyInterpreter::valid_
static bool valid_
Definition:
pyInterpreter.h:117
string.h
BALL::Exception::FileNotFound
Definition:
COMMON/exception.h:359
BALL::PyInterpreter::getStartupLog
static String getStartupLog()
Definition:
pyInterpreter.h:84
path.h
BALL::PyInterpreter::PathStrings
std::vector< String > PathStrings
Used to encode the individual paths appended to sys.path for dynamic loading of modules.
Definition:
pyInterpreter.h:47
common.h
BALL::PyInterpreter::isValid
static bool isValid()
Definition:
pyInterpreter.h:81
BALL::PyInterpreter
Definition:
pyInterpreter.h:36
BALL_EXPORT
#define BALL_EXPORT
Definition:
COMMON/global.h:50
Generated by
1.8.7