ChimeraTK-ApplicationCore
04.06.00
Loading...
Searching...
No Matches
PyTransferElement.cc
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Deutsches Elektronen-Synchrotron DESY, MSK, ChimeraTK Project <chimeratk-support@desy.de>
2
// SPDX-License-Identifier: LGPL-3.0-or-later
3
4
#include "
PyTransferElement.h
"
5
6
namespace
py
=
pybind11
;
7
8
namespace
ChimeraTK
{
9
10
/********************************************************************************************************************/
11
12
void
PyTransferElementBase::bind
(
py::module
& mod) {
13
py::class_<PyTransferElementBase>(mod,
"PyTransferElementBase"
);
14
}
15
16
/********************************************************************************************************************/
17
18
const
std::set<std::string>
PyTransferElementBase::specialFunctionsToEmulateNumeric
{
"__eq__"
,
"__ne__"
,
"__lt__"
,
19
"__le__"
,
"__gt__"
,
"__ge__"
,
"__add__"
,
"__sub__"
,
"__mul__"
,
"__matmul__"
,
"__truediv__"
,
"__floordiv__"
,
20
"__mod__"
,
"__divmod__"
,
"__pow__"
,
"__lshift__"
,
"__rshift__"
,
"__and__"
,
"__xor__"
,
"__or__"
,
"__radd__"
,
21
"__rsub__"
,
"__rmul__"
,
"__rmatmul__"
,
"__rtruediv__"
,
"__rfloordiv__"
,
"__rmod__"
,
"__rdivmod__"
,
"__rpow__"
,
22
"__rlshift__"
,
"__rrshift__"
,
"__rand__"
,
"__rxor__"
,
"__ror__"
,
"__round__"
};
23
24
/********************************************************************************************************************/
25
26
const
std::set<std::string>
PyTransferElementBase::specialUnaryFunctionsToEmulateNumeric
{
"__neg__"
,
"__pos__"
,
27
"__abs__"
,
"__invert__"
,
"__int__"
,
"__float__"
,
"__round__"
,
"__trunc__"
,
"__floor__"
,
"__ceil__"
,
"__str__"
,
28
"__bool__"
};
29
30
/********************************************************************************************************************/
31
32
}
// namespace ChimeraTK
PyTransferElement.h
ChimeraTK::PyTransferElementBase::specialUnaryFunctionsToEmulateNumeric
static const std::set< std::string > specialUnaryFunctionsToEmulateNumeric
Definition
PyTransferElement.h:27
ChimeraTK::PyTransferElementBase::bind
static void bind(py::module &mod)
Definition
PyTransferElement.cc:12
ChimeraTK::PyTransferElementBase::specialFunctionsToEmulateNumeric
static const std::set< std::string > specialFunctionsToEmulateNumeric
Definition
PyTransferElement.h:25
ChimeraTK
InvalidityTracer application module.
Definition
spec_dataValidityPropagation.dox:2
pybind11
Definition
PyModuleGroup.h:10
pybind11::module
module_ module
Definition
PyModuleGroup.h:12
sources
ChimeraTK-ApplicationCore
Python
bindings
src
PyTransferElement.cc
Generated by
1.9.8