26 #if ! defined (octave_ov_lazy_idx_h)
27 #define octave_ov_lazy_idx_h 1
29 #include "octave-config.h"
57 type_conv_info numeric_conversion_function (
void)
const;
75 bool isreal (
void)
const {
return true; }
79 bool isfloat (
void)
const {
return true; }
87 const std::list<octave_value_list>& idx)
91 const std::list<octave_value_list>& idx,
int)
92 {
return subsref (
type, idx); }
95 bool resize_ok =
false)
96 {
return make_value ().
do_index_op (idx, resize_ok); }
109 {
return make_value ().
resize (dv, fill); }
138 {
return make_value ().is_true (); }
141 {
return make_value ().print_as_scalar (); }
143 void print (std::ostream& os,
bool pr_as_read_syntax =
false)
144 { make_value ().print (os, pr_as_read_syntax); }
146 void print_info (std::ostream& os,
const std::string& prefix)
const
147 { make_value ().print_info (os, prefix); }
149 #define FORWARD_VALUE_QUERY(TYPE, NAME) \
150 TYPE NAME (void) const \
152 return make_value ().NAME (); \
164 #define FORWARD_VALUE_QUERY1(TYPE, NAME) \
165 TYPE NAME (bool flag = false) const \
167 return make_value ().NAME (flag); \
195 return make_value ().
diag (k);
216 void print_raw (std::ostream& os,
bool pr_as_read_syntax =
false)
const
218 return make_value ().print_raw (os, pr_as_read_syntax);
221 bool save_ascii (std::ostream& os);
223 bool load_ascii (std::istream& is);
225 bool save_binary (std::ostream& os,
bool save_as_floats);
227 bool load_binary (std::istream& is,
bool swap,
234 return make_value ().write (os, block_size, output_type, skip, flt_fmt);
241 return make_value ().mex_get_data ();
246 return make_value ().as_mxArray ();
251 return make_value ().
map (umap);
258 if (value.is_undefined ())
266 if (value.is_undefined ())
Vector representing the dimensions (size) of an Array.
virtual octave_value subsref(const std::string &type, const std::list< octave_value_list > &idx)
bool print_as_scalar(void) const
octave_value full_value(void) const
void * mex_get_data(void) const
octave_idx_type nnz(void) const
bool isnumeric(void) const
octave_value resize(const dim_vector &dv, bool fill=false) const
bool is_real_matrix(void) const
bool is_defined(void) const
static octave_base_value * numeric_conversion_function(const octave_base_value &)
octave_value do_index_op(const octave_value_list &idx, bool resize_ok=false)
bool is_double_type(void) const
const octave_value & make_value(void) const
octave_base_value * empty_clone(void) const
dim_vector dims(void) const
builtin_type_t builtin_type(void) const
octave_value & make_value(void)
octave_base_value * clone(void) const
void print(std::ostream &os, bool pr_as_read_syntax=false)
octave_value convert_to_str_internal(bool pad, bool force, char type) const
bool is_matrix_type(void) const
idx_vector index_vector(bool=false) const
octave_value all(int dim=0) const
octave_value_list subsref(const std::string &type, const std::list< octave_value_list > &idx, int)
octave_lazy_index(const octave_lazy_index &i)
octave_idx_type numel(void) const
mxArray * as_mxArray(void) const
MatrixType matrix_type(void) const
octave_value subsref(const std::string &type, const std::list< octave_value_list > &idx)
void print_raw(std::ostream &os, bool pr_as_read_syntax=false) const
bool is_constant(void) const
octave_value map(unary_mapper_t umap) const
MatrixType matrix_type(const MatrixType &_typ) const
octave_value any(int dim=0) const
octave_lazy_index(const idx_vector &idx)
size_t byte_size(void) const
void print_info(std::ostream &os, const std::string &prefix) const
~octave_lazy_index(void)=default
int write(octave::stream &os, int block_size, oct_data_conv::data_type output_type, int skip, octave::mach_info::float_format flt_fmt) const
octave_value convert_to_str_internal(bool pad, bool force, char type) const
octave_value subsref(const std::string &type, const std::list< octave_value_list > &idx)
octave_value do_index_op(const octave_value_list &idx, bool resize_ok=false)
octave_value any(int dim=0) const
octave_value map(octave_base_value::unary_mapper_t umap) const
octave_value all(int dim=0) const
octave_value resize(const dim_vector &dv, bool fill=false) const
octave_value diag(octave_idx_type k=0) const
std::complex< double > Complex
std::complex< float > FloatComplex
T::size_type numel(const T &str)
static double as_double(time_t sec, long usec)
return octave_value(v1.char_array_value() . concat(v2.char_array_value(), ra_idx),((a1.is_sq_string()||a2.is_sq_string()) ? '\'' :'"'))
#define DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA
#define FORWARD_VALUE_QUERY(TYPE, NAME)
#define FORWARD_VALUE_QUERY1(TYPE, NAME)