Specialize for the common std::shared_ptr, so users don't need to.
More...
#include <cast.h>
|
using | base = type_caster_base< T > |
|
using | cast_op_type = detail::cast_op_type< T > |
|
|
bool | load (handle src, bool convert) |
|
| operator T * () |
|
| operator T & () |
|
| operator std::shared_ptr< T > * () |
|
| operator std::shared_ptr< T > & () |
|
| operator itype * () |
|
| operator itype & () |
|
PYBIND11_NOINLINE bool | try_load_foreign_module_local (handle src) |
|
template<typename ThisT > |
PYBIND11_NOINLINE bool | load_impl (handle src, bool convert) |
|
|
static handle | cast (const std::shared_ptr< T > &src, return_value_policy, handle) |
|
static handle | cast (const itype &src, return_value_policy policy, handle parent) |
|
static handle | cast (itype &&src, return_value_policy, handle parent) |
|
static handle | cast (const itype *src, return_value_policy policy, handle parent) |
|
static PYBIND11_NOINLINE handle | cast (const void *_src, return_value_policy policy, handle parent, const detail::type_info *tinfo, void *(*copy_constructor)(const void *), void *(*move_constructor)(const void *), const void *existing_holder=nullptr) |
|
static std::pair< const void
*, const type_info * > | src_and_type (const itype *src) |
|
static PYBIND11_NOINLINE
std::pair< const void *, const
type_info * > | src_and_type (const void *src, const std::type_info &cast_type, const std::type_info *rtti_type=nullptr) |
|
static handle | cast_holder (const itype *src, const void *holder) |
|
static PYBIND11_NOINLINE void * | local_load (PyObject *src, const type_info *ti) |
|
|
const type_info * | typeinfo = nullptr |
|
const std::type_info * | cpptype = nullptr |
|
void * | value = nullptr |
|
|
static constexpr auto | name |
|
|
using | Constructor = void *(*)(const void *) |
|
|
void | check_holder_compat () |
|
bool | load_value (value_and_holder &&v_h) |
|
bool | try_implicit_casts (handle, bool) |
|
bool | try_implicit_casts (handle src, bool convert) |
|
|
static bool | try_direct_conversions (handle) |
|
static auto | make_copy_constructor (const T *x) -> decltype(new T(*x), Constructor |
|
static Constructor | make_copy_constructor (...) |
|
static auto | make_move_constructor (const T *x) -> decltype(new T(std::move(*const_cast< T * >(x))), Constructor |
|
static Constructor | make_move_constructor (...) |
|
|
std::shared_ptr< T > | holder |
|
template<typename T>
class type_caster< std::shared_ptr< T > >
Specialize for the common std::shared_ptr, so users don't need to.
Definition at line 1568 of file cast.h.
PYBIND11_NOINLINE bool try_load_foreign_module_local |
( |
handle |
src | ) |
|
|
inlineinherited |
Try to load with foreign typeinfo, if available. Used when there is no native typeinfo, or when the native one wasn't able to produce a value.
Definition at line 637 of file cast.h.
References type::handle_of(), and handle::ptr().
The documentation for this class was generated from the following file: