Rosetta
Classes | Namespaces | Functions | Variables
class.cpp File Reference
#include <class.hpp>
#include <enum.hpp>
#include <function.hpp>
#include <options.hpp>
#include <type.hpp>
#include <util.hpp>
#include <fmt/format.h>
#include <clang/AST/DeclTemplate.h>

Classes

struct  binder::ConstructorBindingInfo
 

Namespaces

 binder
 

Functions

string binder::template_specialization (clang::CXXRecordDecl const *C)
 
string binder::class_name (CXXRecordDecl const *C)
 
string binder::python_class_name (CXXRecordDecl const *C)
 
string binder::class_qualified_name (CXXRecordDecl const *C)
 
vector< QualType > binder::get_type_dependencies (CXXRecordDecl const *C)
 
bool binder::is_inherited_from_enable_shared_from_this (CXXRecordDecl const *C)
 
bool binder::is_field_assignable (FieldDecl const *f)
 
bool binder::is_bindable (FieldDecl *f)
 check if generator can create binding More...
 
string binder::bind_data_member (FieldDecl const *d, string const &class_qualified_name_)
 
bool binder::is_const_overload (CXXMethodDecl *mc)
 
bool binder::is_std_function_bindable (CXXRecordDecl const *C)
 
bool binder::is_bindable_raw (clang::CXXRecordDecl const *C)
 check if generator can create binding More...
 
bool binder::is_bindable (clang::CXXRecordDecl const *C)
 check if generator can create binding More...
 
bool binder::is_binding_requested (clang::CXXRecordDecl const *C, Config const &config)
 check if user requested binding for the given declaration More...
 
bool binder::is_skipping_requested (clang::CXXRecordDecl const *C, Config const &config)
 check if user requested skipping for the given declaration More...
 
void binder::add_relevant_includes (clang::CXXRecordDecl const *C, IncludeSet &includes, int level)
 
void binder::add_includes_to_set (std::vector< std::string > const &from, IncludeSet &to)
 
void binder::add_relevant_includes_cached (clang::CXXRecordDecl const *C, IncludeSet &includes)
 
bool binder::base_default_default_constructor_available (CXXRecordDecl const *C)
 DEPRECATED Check if all bases have public default constructors. More...
 
string binder::generate_opaque_declaration_if_needed (string const &qualified_name, string const &qualified_name_without_template)
 
string binder::binding_public_data_members (CXXRecordDecl const *C)
 
string binder::callback_structure_name (CXXRecordDecl const *C)
 
bool binder::is_callback_structure_needed (CXXRecordDecl const *C)
 
bool binder::is_callback_structure_constructible (CXXRecordDecl const *C)
 
string binder::bind_member_functions_for_call_back (CXXRecordDecl const *C, string const &class_name, set< string > &binded, int &ret_id, std::vector< clang::FunctionDecl const * > &prefix_includes_)
 
string binder::binding_public_member_functions (CXXRecordDecl const *C, bool callback_structure, bool callback_structure_constructible, Context &context)
 
string binder::binding_template_bases (CXXRecordDecl const *C, bool callback_structure, bool callback_structure_constructible, Context &context)
 
string binder::bind_forward_declaration (CXXRecordDecl const *C, Context &context)
 Create forward-binding for given class which consist of only class type without any member, function or constructors. More...
 
string binder::bind_constructor (ConstructorBindingInfo const &CBI, uint args_to_bind, bool request_bindings_f)
 
string binder::bind_default_constructor (ConstructorBindingInfo const &CBI)
 Generate code for binding default constructor. More...
 
string binder::bind_copy_constructor (ConstructorBindingInfo const &CBI)
 
string binder::bind_constructor (ConstructorBindingInfo const &CBI)
 

Variables

const char * binder::call_back_function_body_template
 
char const * binder::constructor_template = "\tcl.def( pybind11::init( []({0}){{ return new {2}({1}); }} ), \"doc\");"
 
char const * binder::constructor_template_with_py_arg = "\tcl.def( pybind11::init( []({0}){{ return new {2}({1}); }} ), \"doc\" {3});"
 
char const * binder::constructor_with_trampoline_template = "\tcl.def( pybind11::init( []({0}){{ return new {2}({1}); }}, []({0}){{ return new {3}({1}); }} ), \"doc\");"