impl Namespace Reference
[Python]
exports a pair of get and set accessors as an read/write attribute in Python by using free functions
More...
|
Data Structures |
struct | IntPow |
struct | IntDiv |
struct | IntMod |
Functions |
template<typename C > |
C | numMin4 (const C &k1, const C &k2, const C &k3, const C &k4) |
template<typename C > |
C | numMax4 (const C &k1, const C &k2, const C &k3, const C &k4) |
template<typename C > |
__inline void | numMinMax (const C &k1, const C &k2, C &amin, C &amax) |
template<typename C > |
__inline void | numMin (const C &k1, const C &k2, C &amin) |
template<typename C > |
void | numMax (const C &k1, const C &k2, C &amax) |
template<typename TClass , typename IArg > |
IArg | secondArgGet (void(*)(TClass *, IArg), PyObject *iArgs, int &r) |
Detailed Description
exports a pair of get and set accessors as an read/write attribute in Python by using free functions
- Parameters:
-
| t_cppClass | the C++ class you want to add the static method to. |
| s_memberName | the name of the attribute in python (zero terminated C string) |
| a_freeCppGetter | the free method in C++ used to get the attribute |
| a_freeCppSetter | the free method in C++ used to set the attribute |
| s_doc | documentation of member as shown in Python (zero terminated C string) |
- Deprecated:
class Foo
{
PY_HEADER(python::PyObjectPlus)
public:
int bar;
};
int getBar(const Foo const* iThis)
{
return iThis->bar;
}
void setBar(Foo* iThis, int iBar)
{
iBar->bar = abar;
}
PY_DECLARE_CLASS(Foo)
PY_CLASS_FREE_MEMBER_RW_EX(Foo, getBar, setBar, "bar", "regular get and setter")
Function Documentation
template<typename C >
C impl::numMin4 |
( |
const C & |
k1, |
|
|
const C & |
k2, |
|
|
const C & |
k3, |
|
|
const C & |
k4 | |
|
) |
| | [inline] |
template<typename C >
C impl::numMax4 |
( |
const C & |
k1, |
|
|
const C & |
k2, |
|
|
const C & |
k3, |
|
|
const C & |
k4 | |
|
) |
| | [inline] |
template<typename C >
__inline void impl::numMinMax |
( |
const C & |
k1, |
|
|
const C & |
k2, |
|
|
C & |
amin, |
|
|
C & |
amax | |
|
) |
| | [inline] |
template<typename C >
__inline void impl::numMin |
( |
const C & |
k1, |
|
|
const C & |
k2, |
|
|
C & |
amin | |
|
) |
| | [inline] |
template<typename C >
void impl::numMax |
( |
const C & |
k1, |
|
|
const C & |
k2, |
|
|
C & |
amax | |
|
) |
| | [inline] |
template<typename TClass , typename IArg >
IArg impl::secondArgGet |
( |
void(*)(TClass *, IArg) |
, |
|
|
PyObject * |
iArgs, |
|
|
int & |
r | |
|
) |
| | [inline] |