26 #if ! defined (octave_ov_class_h)
27 #define octave_ov_class_h 1
29 #include "octave-config.h"
59 parent_list (), obsolete_copies (0)
64 parent_list (), obsolete_copies (0)
68 const std::list<std::string>& plist)
70 parent_list (plist), obsolete_copies (0)
78 parent_list (s.parent_list), obsolete_copies (0) { }
103 const std::list<octave_value_list>& idx)
110 const std::list<octave_value_list>& idx,
114 const std::string&
type);
117 { map.assign (k, rhs); };
120 const std::list<octave_value_list>& idx,
124 const std::list<octave_value_list>& idx,
127 idx_vector index_vector (
bool require_integers =
false)
const;
131 size_t byte_size (
void)
const;
143 size_t nparents (
void)
const {
return parent_list.size (); }
172 {
return parent_list; }
181 bool is_instance_of (
const std::string&)
const;
185 void print (std::ostream& os,
bool pr_as_read_syntax =
false);
187 void print_raw (std::ostream& os,
bool pr_as_read_syntax =
false)
const;
189 bool reconstruct_exemplar (
void);
191 static void clear_exemplar_map (
void);
193 bool reconstruct_parents (
void);
195 bool save_ascii (std::ostream& os);
197 bool load_ascii (std::istream& is);
199 bool save_binary (std::ostream& os,
bool save_as_floats);
201 bool load_binary (std::istream& is,
bool swap,
208 mxArray * as_mxArray (
void)
const;
231 std::string get_current_method_class (
void);
234 const std::string&
type,
235 const std::list<octave_value_list>& idx,
252 : field_names (
x.field_names),
253 parent_class_names (
x.parent_class_names) { }
259 field_names =
x.field_names;
260 parent_class_names =
x.parent_class_names;
267 size_t nparents (
void)
const {
return parent_class_names.size (); }
271 std::list<std::string>
parents (
void)
const {
return parent_class_names; }
284 typedef std::map<std::string, exemplar_info>::iterator
286 typedef std::map<std::string, exemplar_info>::const_iterator
Array< U > map(F fcn) const
Apply function fcn to each element of the Array<T>.
Array< T > reshape(octave_idx_type nr, octave_idx_type nc) const
Size of the specified dimension.
Vector representing the dimensions (size) of an Array.
octave_idx_type numel(int n=0) const
Number of elements that a matrix with this dimensions would have.
virtual octave_value subsref(const std::string &type, const std::list< octave_value_list > &idx)
string_vector field_names
std::list< std::string > parent_class_names
octave_idx_type nfields(void) const
string_vector fields(void) const
exemplar_info(const exemplar_info &x)
size_t nparents(void) const
std::list< std::string > parents(void) const
string_vector parent_class_names(void) const
static std::string static_class_name(void)
std::string type_name(void) const
octave_value subsref(const std::string &type, const std::list< octave_value_list > &idx)
bool isstruct(void) const
std::map< std::string, exemplar_info >::iterator exemplar_iterator
octave_value resize(const dim_vector &dv, bool=false) const
std::list< std::string > parent_class_name_list(void) const
static std::map< std::string, exemplar_info > exemplar_map
octave_idx_type numel(void) const
octave_class(const octave_map &m, const std::string &id, const std::list< std::string > &plist)
std::string class_name(void) const
octave_base_value * clone(void) const
static const std::string t_name
bool is_defined(void) const
octave_map map_value(void) const
~octave_class(void)=default
static int static_type_id(void)
octave_value reshape(const dim_vector &new_dims) const
static std::string static_type_name(void)
size_t nparents(void) const
octave_idx_type nfields(void) const
dim_vector dims(void) const
octave_base_value * empty_clone(void) const
std::map< std::string, exemplar_info >::const_iterator exemplar_const_iterator
bool isobject(void) const
octave_class(const octave_class &s)
void assign(const std::string &k, const octave_value &rhs)
octave_class(const octave_map &m, const std::string &id)
std::list< std::string > parent_list
octave_idx_type length(void) const
F77_RET_T const F77_DBLE * x
bool is_true(const std::string &s)
int register_type(const std::string &t_name, const std::string &c_name, const octave_value &val)
return octave_value(v1.char_array_value() . concat(v2.char_array_value(), ra_idx),((a1.is_sq_string()||a2.is_sq_string()) ? '\'' :'"'))
static bool in_class_method(const octave::cdef_class &cls)
octave_value::octave_value(const Array< char > &chm, char type) return retval