Public Types | Public Member Functions | Private Attributes | List of all members
enum_< Type > Class Template Reference

Binds C++ enumerations and enumeration classes to Python. More...

#include <pybind11.h>

Inheritance diagram for enum_< Type >:
Inheritance graph
[legend]

Public Types

using Base = class_< Type >
 
using Scalar = typename std::underlying_type< Type >::type
 
- Public Types inherited from class_< Type >
using holder_type = detail::exactly_one_t< is_holder, std::unique_ptr< type >, options... >
 
using type = Type
 
using type_alias = detail::exactly_one_t< is_subtype, void, options... >
 

Public Member Functions

template<typename... Extra>
 enum_ (const handle &scope, const char *name, const Extra &...extra)
 
enum_export_values ()
 Export enumeration entries into the parent scope. More...
 
enum_value (char const *name, Type value, const char *doc=nullptr)
 Add an enumeration entry. More...
 
- Public Member Functions inherited from class_< Type >
 class_ (handle scope, const char *name, const Extra &...extra)
 
class_def (const char *name_, Func &&f, const Extra &...extra)
 
class_def (const detail::op_< id, ot, L, R > &op, const Extra &...extra)
 
class_def (const detail::initimpl::constructor< Args... > &init, const Extra &...extra)
 
class_def (const detail::initimpl::alias_constructor< Args... > &init, const Extra &...extra)
 
class_def (detail::initimpl::factory< Args... > &&init, const Extra &...extra)
 
class_def (detail::initimpl::pickle_factory< Args... > &&pf, const Extra &...extra)
 
class_def_buffer (Func &&func)
 
class_def_buffer (Return(Class::*func)(Args...))
 
class_def_buffer (Return(Class::*func)(Args...) const)
 
class_def_cast (const detail::op_< id, ot, L, R > &op, const Extra &...extra)
 
class_def_property (const char *name, const Getter &fget, const Setter &fset, const Extra &...extra)
 Uses return_value_policy::reference_internal by default. More...
 
class_def_property (const char *name, const Getter &fget, const cpp_function &fset, const Extra &...extra)
 
class_def_property (const char *name, const cpp_function &fget, const cpp_function &fset, const Extra &...extra)
 Uses cpp_function's return_value_policy by default. More...
 
class_def_property_readonly (const char *name, const Getter &fget, const Extra &...extra)
 Uses return_value_policy::reference_internal by default. More...
 
class_def_property_readonly (const char *name, const cpp_function &fget, const Extra &...extra)
 Uses cpp_function's return_value_policy by default. More...
 
class_def_property_readonly_static (const char *name, const Getter &fget, const Extra &...extra)
 Uses return_value_policy::reference by default. More...
 
class_def_property_readonly_static (const char *name, const cpp_function &fget, const Extra &...extra)
 Uses cpp_function's return_value_policy by default. More...
 
class_def_property_static (const char *name, const Getter &fget, const cpp_function &fset, const Extra &...extra)
 Uses return_value_policy::reference by default. More...
 
class_def_property_static (const char *name, const cpp_function &fget, const cpp_function &fset, const Extra &...extra)
 Uses cpp_function's return_value_policy by default. More...
 
class_def_readonly (const char *name, const D C::*pm, const Extra &...extra)
 
class_def_readonly_static (const char *name, const D *pm, const Extra &...extra)
 
class_def_readwrite (const char *name, D C::*pm, const Extra &...extra)
 
class_def_readwrite_static (const char *name, D *pm, const Extra &...extra)
 
class_def_static (const char *name_, Func &&f, const Extra &...extra)
 

Private Attributes

detail::enum_base m_base
 

Additional Inherited Members

- Static Public Member Functions inherited from class_< Type >
static void add_base (detail::type_record &rec)
 
static void add_base (detail::type_record &)
 
- Static Public Attributes inherited from class_< Type >
static constexpr bool has_alias
 

Detailed Description

template<typename Type>
class enum_< Type >

Binds C++ enumerations and enumeration classes to Python.

Definition at line 1637 of file pybind11.h.

Member Typedef Documentation

template<typename Type >
using enum_< Type >::Base = class_<Type>

Definition at line 1639 of file pybind11.h.

template<typename Type >
using enum_< Type >::Scalar = typename std::underlying_type<Type>::type

Definition at line 1644 of file pybind11.h.

Constructor & Destructor Documentation

template<typename Type >
template<typename... Extra>
enum_< Type >::enum_ ( const handle scope,
const char *  name,
const Extra &...  extra 
)
inline

Definition at line 1647 of file pybind11.h.

Member Function Documentation

template<typename Type >
enum_& enum_< Type >::export_values ( )
inline

Export enumeration entries into the parent scope.

Definition at line 1671 of file pybind11.h.

template<typename Type >
enum_& enum_< Type >::value ( char const *  name,
Type  value,
const char *  doc = nullptr 
)
inline

Add an enumeration entry.

Definition at line 1677 of file pybind11.h.

Member Data Documentation

template<typename Type >
detail::enum_base enum_< Type >::m_base
private

Definition at line 1683 of file pybind11.h.


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


gtsam
Author(s):
autogenerated on Sat May 8 2021 02:51:47