#include "cdef-manager.h"
Public Member Functions | |
cdef_manager (const cdef_manager &)=delete | |
cdef_manager (interpreter &interp) | |
~cdef_manager (void)=default | |
cdef_class | find_class (const std::string &name, bool error_if_not_found=true, bool load_if_not_found=true) |
octave_value | find_method (const std::string &class_name, const std::string &name) const |
octave_value | find_method_symbol (const std::string &method_name, const std::string &class_name) |
cdef_package | find_package (const std::string &name, bool error_if_not_found=true, bool load_if_not_found=true) |
octave_value | find_package_symbol (const std::string &pack_name) |
cdef_property | make_attribute (const cdef_class &cls, const std::string &name) |
cdef_class | make_class (const std::string &name, const cdef_class &super) |
cdef_class | make_class (const std::string &name, const std::list< cdef_class > &super_list=std::list< cdef_class >()) |
cdef_class | make_meta_class (const std::string &name, const cdef_class &super) |
cdef_method | make_method (const cdef_class &cls, const std::string &name, const octave_value &fcn, const std::string &m_access="public", bool is_static=false) |
cdef_method | make_method (const cdef_class &cls, const std::string &name, octave_builtin::fcn ff, const std::string &m_access="public", bool is_static=false) |
cdef_method | make_method (const cdef_class &cls, const std::string &name, octave_builtin::meth mm, const std::string &m_access="public", bool is_static=false) |
cdef_package | make_package (const std::string &nm, const std::string &parent="") |
cdef_property | make_property (const cdef_class &cls, const std::string &name, const octave_value &get_method=Matrix(), const std::string &get_access="public", const octave_value &set_method=Matrix(), const std::string &set_access="public") |
const cdef_package & | meta (void) const |
const cdef_class & | meta_class (void) const |
const cdef_class & | meta_method (void) const |
const cdef_class & | meta_package (void) const |
const cdef_class & | meta_property (void) const |
cdef_manager & | operator= (const cdef_manager &)=delete |
void | register_class (const cdef_class &cls) |
void | register_package (const cdef_package &pkg) |
void | unregister_class (const cdef_class &cls) |
void | unregister_package (const cdef_package &pkg) |
Private Attributes | |
std::map< std::string, cdef_class > | m_all_classes |
std::map< std::string, cdef_package > | m_all_packages |
interpreter & | m_interpreter |
cdef_package | m_meta |
cdef_class | m_meta_class |
cdef_class | m_meta_method |
cdef_class | m_meta_package |
cdef_class | m_meta_property |
Definition at line 41 of file cdef-manager.h.
octave::cdef_manager::cdef_manager | ( | interpreter & | interp | ) |
Definition at line 324 of file cdef-manager.cc.
References octave::class_eq(), octave::class_fevalStatic(), octave::class_fromName(), octave::class_ge(), octave::class_get_inferiorclasses(), octave::class_get_methods(), octave::class_get_properties(), octave::class_get_superclasses(), octave::class_getConstant(), octave::class_gt(), octave::class_le(), octave::class_lt(), octave::class_ne(), octave::cdef_class::get_constructor_function(), octave::interpreter::get_symbol_table(), octave::interpreter::get_type_info(), octave::handle_delete(), octave::symbol_table::install_built_in_function(), octave::cdef_package::install_class(), octave::cdef_class::install_method(), octave::cdef_class::install_property(), m_interpreter, m_meta, m_meta_class, m_meta_method, m_meta_package, m_meta_property, make_attribute(), make_class(), octave::make_fcn_handle(), make_meta_class(), make_method(), make_package(), make_property(), octave::package_fromName(), octave::package_get_classes(), octave::package_get_functions(), octave::package_get_packages(), octave::package_getAllPackages(), octave::property_get_defaultvalue(), octave_base_value::register_type(), and octave::cdef_object::set_class().
|
delete |
|
default |
cdef_class octave::cdef_manager::find_class | ( | const std::string & | name, |
bool | error_if_not_found = true , |
||
bool | load_if_not_found = true |
||
) |
Definition at line 634 of file cdef-manager.cc.
References error(), octave::interpreter::find(), octave::cdef_package::find(), find_package(), octave::cdef_class::is_builtin(), octave_value::is_defined(), octave::lookup_class(), m_all_classes, m_interpreter, name, and octave::cdef_object::ok().
Referenced by find_method_symbol(), octave::lookup_class(), and read_mat5_binary_element().
octave_value octave::cdef_manager::find_method | ( | const std::string & | class_name, |
const std::string & | name | ||
) | const |
Definition at line 941 of file cdef-manager.cc.
References octave::cdef_class::get_method(), octave::lookup_class(), and name.
Referenced by octave::tree_evaluator::get_user_code().
octave_value octave::cdef_manager::find_method_symbol | ( | const std::string & | method_name, |
const std::string & | class_name | ||
) |
Definition at line 686 of file cdef-manager.cc.
References find_class(), octave::cdef_class::find_method(), octave_value(), and octave::cdef_object::ok().
Referenced by octave::fcn_info::fcn_info_rep::load_class_method().
cdef_package octave::cdef_manager::find_package | ( | const std::string & | name, |
bool | error_if_not_found = true , |
||
bool | load_if_not_found = true |
||
) |
Definition at line 703 of file cdef-manager.cc.
References error(), octave::load_path::find_package(), octave::interpreter::get_load_path(), m_all_packages, m_interpreter, make_package(), name, and retval.
Referenced by find_class(), find_package_symbol(), octave::lookup_package(), octave::cdef_class::make_meta_class(), make_package(), and octave::package_getAllPackages().
octave_value octave::cdef_manager::find_package_symbol | ( | const std::string & | pack_name | ) |
Definition at line 743 of file cdef-manager.cc.
References find_package(), octave_value(), and octave::cdef_object::ok().
cdef_property octave::cdef_manager::make_attribute | ( | const cdef_class & | cls, |
const std::string & | name | ||
) |
Definition at line 868 of file cdef-manager.cc.
References make_property(), and name.
Referenced by cdef_manager().
cdef_class octave::cdef_manager::make_class | ( | const std::string & | name, |
const cdef_class & | super | ||
) |
Definition at line 811 of file cdef-manager.cc.
References make_class(), and name.
cdef_class octave::cdef_manager::make_class | ( | const std::string & | name, |
const std::list< cdef_class > & | super_list = std::list<cdef_class> () |
||
) |
Definition at line 754 of file cdef-manager.cc.
References error(), octave::cdef_class::mark_as_handle_class(), meta_class(), name, octave::cdef_object::put(), register_class(), and octave::cdef_object::set_class().
Referenced by cdef_manager(), octave::cdef_class::cdef_class_rep::construct_object(), make_class(), make_meta_class(), and octave::cdef_class::make_meta_class().
cdef_class octave::cdef_manager::make_meta_class | ( | const std::string & | name, |
const cdef_class & | super | ||
) |
Definition at line 818 of file cdef-manager.cc.
References make_class(), octave::cdef_class::mark_as_meta_class(), name, and octave::cdef_object::put().
Referenced by cdef_manager().
cdef_method octave::cdef_manager::make_method | ( | const cdef_class & | cls, |
const std::string & | name, | ||
const octave_value & | fcn, | ||
const std::string & | m_access = "public" , |
||
bool | is_static = false |
||
) |
Definition at line 874 of file cdef-manager.cc.
References octave::cdef_class::get_name(), octave_value::is_defined(), octave::is_dummy_method(), octave::make_function_of_class(), octave::cdef_method::mark_as_external(), meta_method(), name, octave::cdef_object::put(), octave::cdef_object::set_class(), octave::cdef_method::set_function(), and octave::to_ov().
Referenced by cdef_manager(), octave::cdef_class::cdef_class_rep::construct_object(), octave::cdef_class::make_meta_class(), and make_method().
cdef_method octave::cdef_manager::make_method | ( | const cdef_class & | cls, |
const std::string & | name, | ||
octave_builtin::fcn | ff, | ||
const std::string & | m_access = "public" , |
||
bool | is_static = false |
||
) |
Definition at line 903 of file cdef-manager.cc.
References make_method(), and name.
cdef_method octave::cdef_manager::make_method | ( | const cdef_class & | cls, |
const std::string & | name, | ||
octave_builtin::meth | mm, | ||
const std::string & | m_access = "public" , |
||
bool | is_static = false |
||
) |
Definition at line 913 of file cdef-manager.cc.
References make_method(), and name.
cdef_package octave::cdef_manager::make_package | ( | const std::string & | nm, |
const std::string & | parent = "" |
||
) |
Definition at line 923 of file cdef-manager.cc.
References find_package(), meta_package(), octave::cdef_object::put(), register_package(), octave::cdef_object::set_class(), and octave::to_ov().
Referenced by cdef_manager(), octave::cdef_class::cdef_class_rep::construct_object(), and find_package().
cdef_property octave::cdef_manager::make_property | ( | const cdef_class & | cls, |
const std::string & | name, | ||
const octave_value & | get_method = Matrix () , |
||
const std::string & | get_access = "public" , |
||
const octave_value & | set_method = Matrix () , |
||
const std::string & | set_access = "public" |
||
) |
Definition at line 830 of file cdef-manager.cc.
References octave::cdef_class::get_name(), octave_value::isempty(), octave::make_function_of_class(), meta_property(), name, octave::cdef_object::put(), octave::cdef_object::set_class(), and octave::to_ov().
Referenced by cdef_manager(), octave::cdef_class::cdef_class_rep::construct_object(), make_attribute(), and octave::cdef_class::make_meta_class().
|
inline |
Definition at line 93 of file cdef-manager.h.
References m_meta.
Referenced by octave::cdef_package::cdef_package_rep::meta_release().
|
inline |
Definition at line 88 of file cdef-manager.h.
References m_meta_class.
Referenced by octave::cdef_class::cdef_class_rep::construct_object(), and make_class().
|
inline |
Definition at line 90 of file cdef-manager.h.
References m_meta_method.
Referenced by octave::cdef_class::cdef_class_rep::construct_object(), and make_method().
|
inline |
Definition at line 91 of file cdef-manager.h.
References m_meta_package.
Referenced by octave::cdef_class::cdef_class_rep::construct_object(), and make_package().
|
inline |
Definition at line 89 of file cdef-manager.h.
References m_meta_property.
Referenced by octave::cdef_class::cdef_class_rep::construct_object(), and make_property().
|
delete |
|
inline |
Definition at line 68 of file cdef-manager.h.
References octave::cdef_class::get_name(), and m_all_classes.
Referenced by make_class().
|
inline |
Definition at line 78 of file cdef-manager.h.
References octave::cdef_package::get_name(), and m_all_packages.
Referenced by make_package().
|
inline |
Definition at line 73 of file cdef-manager.h.
References octave::cdef_class::get_name(), and m_all_classes.
Referenced by octave::cdef_class::cdef_class_rep::meta_release().
|
inline |
Definition at line 83 of file cdef-manager.h.
References octave::cdef_package::get_name(), and m_all_packages.
Referenced by octave::cdef_package::cdef_package_rep::meta_release().
|
private |
Definition at line 142 of file cdef-manager.h.
Referenced by find_class(), register_class(), and unregister_class().
|
private |
Definition at line 145 of file cdef-manager.h.
Referenced by find_package(), register_package(), and unregister_package().
|
private |
Definition at line 139 of file cdef-manager.h.
Referenced by cdef_manager(), find_class(), and find_package().
|
private |
Definition at line 152 of file cdef-manager.h.
Referenced by cdef_manager(), and meta().
|
private |
Definition at line 147 of file cdef-manager.h.
Referenced by cdef_manager(), and meta_class().
|
private |
Definition at line 149 of file cdef-manager.h.
Referenced by cdef_manager(), and meta_method().
|
private |
Definition at line 150 of file cdef-manager.h.
Referenced by cdef_manager(), and meta_package().
|
private |
Definition at line 148 of file cdef-manager.h.
Referenced by cdef_manager(), and meta_property().