ViennaGrid for Python
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
src
exception_translator.hpp
Go to the documentation of this file.
1
6
#ifndef EXCEPTION_TRANSLATOR_HPP
7
#define EXCEPTION_TRANSLATOR_HPP
8
20
template
<
typename
T>
21
struct
ExceptionTranslator
{
27
PyObject *
m_py_except
;
28
public
:
36
ExceptionTranslator
(PyObject *py_except) :
m_py_except
(py_except) {}
37
55
void
operator()
(
const
T& cxx_except)
const
56
{
57
PyErr_SetString(
m_py_except
, cxx_except.what());
58
}
59
};
60
61
#endif
Generated on Sat Sep 28 2013 10:54:59 for ViennaGrid for Python by
1.8.1.2