Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
python
exportToPython.cxx
Go to the documentation of this file.
1
12
#ifdef HAVE_CONFIG_H
13
//for have qt app
14
#include "config.h"
15
#endif
16
17
#ifdef _MSC_VER
18
# pragma warning(disable:4231) // nonstandard extension used 'extern'
19
// before...
20
# pragma warning(disable:4251) // needs to have dll-interface used by client
21
# pragma warning(disable:4275) // non dll-interface struct
22
# pragma warning(disable:4800) // 'int' : forcing value to bool
23
// 'true' or 'false' (performance
24
// warning)
25
#endif
26
27
#include "
exportToPython.h
"
28
29
// include first to avoid _POSIX_C_SOURCE redefined warnings
30
#include "
pyconversions.h
"
31
32
#include "
QtCut.h
"
33
#include "
PyDataRep.h
"
34
#include "
PyDataSource.h
"
35
36
37
using
std::vector;
38
using namespace
hippodraw::Python;
39
using namespace
boost::python;
40
41
namespace
hippodraw {
42
namespace
Python {
43
44
#if __GNUC__ < 3
45
52
void
53
translate
(
const
std::exception & e )
54
{
55
PyErr_SetString ( PyExc_RuntimeError, e.what() );
56
}
57
#endif
58
59
void
60
exportToPython
()
61
{
62
#if __GNUC__ < 3
63
register_exception_translator < std::exception > ( &
translate
);
64
#endif
65
66
/* The following is neede for PyGILState_Ensure / _Release to
67
work. */
68
PyEval_InitThreads();
69
70
// The order is important. Base class before derived classes
71
72
#ifdef HAVE_QT_APP
73
export_CanvasWindow
();
74
#endif
75
export_DataSource
();
76
export_DataArray
();
77
export_ListTuple
();
// derived from DataSource
78
#ifdef HAVE_NUMARRAY
79
export_NumArrayTuple
();
// derived from DataSource
80
#endif
81
#ifdef HAVE_ROOT
82
export_RootNTuple
();
// derived from DataSource
83
export_RootController
();
84
#endif
85
export_CutController
();
86
#ifdef HAVE_CFITSIO
87
export_FitsController
();
88
export_FitsNTuple
();
// derived from DataSource
89
#endif
90
export_NTuple
();
// derived from DataSource
91
export_PyNTuple
();
// derived from NTuple
92
export_CircularBuffer
();
// derived from NTuple
93
export_NTupleController
();
94
export_Observer
();
95
export_QtDisplay
();
96
export_QtCut
();
// derived from QtDisplay
97
export_Function
();
98
#ifdef HAVE_QT_APP
99
export_Canvas
();
100
#endif
101
export_HDApp
();
102
export_DataRep
();
103
export_RepBase
();
104
export_Factory_PointRep
();
105
export_PointRepFactory
();
106
export_Fitter
();
107
export_FitterFactory
();
108
// order is important, base class first
109
export_FCNBase
();
110
export_StatedFCN
();
111
export_NTupleFCN
();
112
#ifndef BOOST_DEFECT
113
export_FunctionBase
();
114
#endif
115
export_FunctionFactory
();
116
export_SymbolType
();
117
export_LineStyle
();
118
export_Color
();
119
120
std_vector_to_tuple < double >
();
121
std_vector_to_tuple < int >
();
122
std_vector_to_tuple < std::string >
();
123
std_vector_to_tuple < QtDisplay * >
();
124
std_vector_to_tuple < PyDataRep * >
();
125
126
from_python_sequence < std::vector < std::string >
,
127
variable_capacity_policy
> ();
128
129
from_python_sequence < std::vector < double >
,
130
variable_capacity_policy
> ();
131
132
from_python_sequence < std::vector < int >
,
133
variable_capacity_policy
> ();
134
135
from_python_sequence < std::vector < QtDisplay * >
,
136
variable_capacity_policy
> ();
137
138
from_python_sequence < std::vector < QtCut * >
,
139
variable_capacity_policy
> ();
140
141
from_python_sequence < std::vector < std::vector < double >
>,
142
variable_capacity_policy
> ();
143
144
}
145
146
}
// end namespace Python
147
}
// end namespace hippodraw
Generated for HippoDraw Class Library by