23 #if !defined (octave_ov_typeinfo_h)
24 #define octave_ov_typeinfo_h 1
60 (octave_base_value&,
const octave_value_list&,
const octave_value&);
62 static bool instance_ok (
void);
64 static int register_type (
const std::string&,
const std::string&,
73 non_const_unary_op_fcn);
87 static bool register_cat_op (
int,
int, cat_op_fcn);
95 static bool register_pref_assign_conv (
int,
int,
int);
106 return instance->do_lookup_type (nm);
109 static unary_class_op_fcn
112 return instance->do_lookup_unary_class_op (op);
118 return instance->do_lookup_unary_op (op, t);
121 static non_const_unary_op_fcn
124 return instance->do_lookup_non_const_unary_op (op, t);
127 static binary_class_op_fcn
130 return instance->do_lookup_binary_class_op (op);
136 return instance->do_lookup_binary_op (op, t1, t2);
139 static binary_class_op_fcn
142 return instance->do_lookup_binary_class_op (op);
148 return instance->do_lookup_binary_op (op, t1, t2);
154 return instance->do_lookup_cat_op (t1, t2);
160 return instance->do_lookup_assign_op (op, t_lhs, t_rhs);
163 static assignany_op_fcn
166 return instance->do_lookup_assignany_op (op, t_lhs);
172 return instance->do_lookup_pref_assign_conv (t_lhs, t_rhs);
178 return instance->do_lookup_type_conv_op (t, t_result);
184 return instance->do_lookup_widening_op (t, t_result);
189 return instance->do_installed_type_names ();
195 : num_types (0), types (
dim_vector (init_tab_sz, 1),
std::string ()),
204 cat_ops (
dim_vector (init_tab_sz, init_tab_sz), 0),
207 pref_assign_conv (
dim_vector (init_tab_sz, init_tab_sz), -1),
208 type_conv_ops (
dim_vector (init_tab_sz, init_tab_sz), 0),
209 widening_ops (
dim_vector (init_tab_sz, init_tab_sz), 0) { }
253 int do_register_type (
const std::string&,
const std::string&,
261 non_const_unary_op_fcn);
264 binary_class_op_fcn);
270 binary_class_op_fcn);
275 bool do_register_cat_op (
int,
int, cat_op_fcn);
283 bool do_register_pref_assign_conv (
int,
int,
int);
295 non_const_unary_op_fcn do_lookup_non_const_unary_op
307 cat_op_fcn do_lookup_cat_op (
int,
int);
313 int do_lookup_pref_assign_conv (
int,
int);
static const int init_tab_sz
Array< void * > binary_ops
const octave_base_value const Array< octave_idx_type > & ra_idx
static void cleanup_instance(void)
static string_vector installed_type_names(void)
static non_const_unary_op_fcn lookup_non_const_unary_op(octave_value::unary_op op, int t)
Array< int > pref_assign_conv
Array< octave_value > vals
Array< void * > binary_class_ops
static binary_op_fcn lookup_binary_op(octave_value::binary_op op, int t1, int t2)
static int lookup_pref_assign_conv(int t_lhs, int t_rhs)
static octave_value_typeinfo * instance
static unary_class_op_fcn lookup_unary_class_op(octave_value::unary_op op)
static octave_value lookup_type(const std::string &nm)
static assignany_op_fcn lookup_assignany_op(octave_value::assign_op op, int t_lhs)
static octave_base_value::type_conv_fcn lookup_type_conv_op(int t, int t_result)
Array< void * > non_const_unary_ops
Array< void * > assignany_ops
Array< void * > unary_class_ops
string_vector & operator=(const string_vector &s)
static binary_class_op_fcn lookup_binary_class_op(octave_value::binary_op op)
~octave_value_typeinfo(void)
Array< void * > type_conv_ops
static cat_op_fcn lookup_cat_op(int t1, int t2)
octave_base_value *(* type_conv_fcn)(const octave_base_value &)
static binary_class_op_fcn lookup_binary_class_op(octave_value::compound_binary_op op)
Array< void * > unary_ops
Array< void * > assign_ops
Array< void * > widening_ops
octave_value_typeinfo(void)
static assign_op_fcn lookup_assign_op(octave_value::assign_op op, int t_lhs, int t_rhs)
Array< void * > compound_binary_ops
Array< std::string > types
return octave_value(v1.char_array_value().concat(v2.char_array_value(), ra_idx),((a1.is_sq_string()||a2.is_sq_string())? '\'': '"'))
static unary_op_fcn lookup_unary_op(octave_value::unary_op op, int t)
Array< void * > compound_binary_class_ops
static octave_base_value::type_conv_fcn lookup_widening_op(int t, int t_result)
static binary_op_fcn lookup_binary_op(octave_value::compound_binary_op op, int t1, int t2)