Unless stated otherwise, the following C++ functions behave the same as their Python counterparts. More...
Functions | |
| void | delattr (handle obj, const char *name) |
| void | delattr (handle obj, handle name) |
| object | getattr (handle obj, const char *name) |
| object | getattr (handle obj, const char *name, handle default_) |
| object | getattr (handle obj, handle name) |
| object | getattr (handle obj, handle name, handle default_) |
| dict | globals () |
| bool | hasattr (handle obj, const char *name) |
| bool | hasattr (handle obj, handle name) |
| ssize_t | hash (handle obj) |
| template<typename T , detail::enable_if_t< std::is_base_of< object, T >::value, int > = 0> | |
| bool | isinstance (handle obj) |
| bool | isinstance (handle obj, handle type) |
| iterator | iter (handle obj) |
| size_t | len (handle h) |
| Get the length of a Python object. More... | |
| size_t | len_hint (handle h) |
| str | repr (handle h) |
| void | setattr (handle obj, const char *name, handle value) |
| void | setattr (handle obj, handle name, handle value) |
Unless stated otherwise, the following C++ functions behave the same as their Python counterparts.
|
inline |
Return a dictionary representing the global variables in the current execution frame, or __main__.__dict__ if there is no frame (usually when the interpreter is embedded).
Definition at line 1323 of file pybind11.h.
| bool isinstance | ( | handle | obj | ) |