Library of Assembled Shared Sources
lass::python::PyExportTraitsEnum< EnumType, IntegerType > Struct Template Reference

Helper to specialise PyExportTraits for enumerations. More...

#include <pyobject_plus.h>

Detailed Description

template<typename EnumType, typename IntegerType = std::underlying_type_t<EnumType>>
struct lass::python::PyExportTraitsEnum< EnumType, IntegerType >

Helper to specialise PyExportTraits for enumerations.

When you want to export enumeration types, you need to specialize PyExportTraits for it. This structure will help you

enum MyEnumeration { meFoo, meBar, meFuz };
namespace lass
{
namespace python
{
template <> struct PyExportTraits<MyEnumeration>: public PyExportTraitsEnum<MyEnumeration> {};
}
}
Comprehensive C++ to Python binding library.
Library for Assembled Shared Sources.
Definition config.h:53
Helper to specialise PyExportTraits for enumerations.
by copy, general case assumes shadow type or PyObjectPlus based type.

Definition at line 126 of file pyobject_plus.h.


The documentation for this struct was generated from the following file: