26#ifndef MYSQLSHDK_SCRIPTING_POLYGLOT_POLYGLOT_WRAPPERS_TYPES_POLYGLOT_H_
27#define MYSQLSHDK_SCRIPTING_POLYGLOT_POLYGLOT_WRAPPERS_TYPES_POLYGLOT_H_
43class Polyglot_language;
53 poly_context context, poly_value
object,
72 bool has_member(
const std::string &prop)
const;
80 Value call(
const std::string &name,
const std::vector<Value> &args);
104 poly_value
function);
Definition: utils_json.h:49
Utility class to allow wrapping a Polyglot function to be used from C++.
Definition: types_polyglot.h:99
std::weak_ptr< Polyglot_language > m_language
Definition: types_polyglot.h:119
~Polyglot_function()
Definition: types_polyglot.cc:170
const std::string & name() const
Definition: types_polyglot.h:114
Polyglot_function operator=(const Polyglot_function &)=delete
Polyglot_function(const Polyglot_function &)=delete
std::string m_name
Definition: types_polyglot.h:121
Polyglot_function operator=(Polyglot_function &&)=delete
Polyglot_function(Polyglot_function &&)=delete
Polyglot_function()=delete
poly_reference m_function
Definition: types_polyglot.h:120
Value invoke(const std::vector< Value > &args)
Definition: types_polyglot.cc:177
Utility class to allow wrapping a Polyglot object to be used from the C++.
Definition: types_polyglot.h:48
std::string m_class_name
Definition: types_polyglot.h:93
Value get_property(const std::string &prop) const
poly_value get() const
Definition: types_polyglot.h:82
Polyglot_object(Polyglot_object &&)=delete
Value get_member(const std::string &prop) const
Definition: types_polyglot.cc:73
virtual ~Polyglot_object()=default
void throw_exception() const
Definition: types_polyglot.cc:148
void set_poly_member(const std::string &prop, poly_value value)
Definition: types_polyglot.cc:97
Store m_object
Definition: types_polyglot.h:92
Polyglot_object(const Polyglot_object &)=delete
std::vector< std::string > get_members() const
Definition: types_polyglot.cc:53
poly_thread m_thread
Definition: types_polyglot.h:90
const Polyglot_type_bridger * m_types
Definition: types_polyglot.h:89
Polyglot_object & operator=(Polyglot_object &&)=delete
poly_context m_context
Definition: types_polyglot.h:91
poly_value get_poly_member(const std::string &prop) const
Definition: types_polyglot.cc:77
Polyglot_object & operator=(const Polyglot_object &)=delete
bool is_exception() const
Definition: types_polyglot.cc:140
void set_property(const std::string &prop, Value value)
void set_member(const std::string &prop, Value value)
Definition: types_polyglot.cc:93
void append_json(JSON_dumper &dumper) const
Definition: types_polyglot.cc:47
std::string class_name() const
Definition: types_polyglot.cc:45
bool remove_member(const std::string &name)
Definition: types_polyglot.cc:131
bool has_member(const std::string &prop) const
Definition: types_polyglot.cc:85
Value call(const std::string &name, const std::vector< Value > &args)
Definition: types_polyglot.cc:103
Helper class to handle polyglot values made permanent.
Definition: polyglot_store.h:47
poly_reference get() const noexcept
Definition: polyglot_store.h:70
ValueType value(const std::optional< ValueType > &v)
Definition: gtid.h:83
Definition: file_system_exceptions.h:34
Pointer to a function that may be implemented in any language.
Definition: jit_executor_value.h:130
Definition: jit_executor_type_conversion.h:37