Mercurial > octave-nkf
comparison src/ov-str-mat.h @ 10313:f3b65e1ae355
untabify src header files
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 11 Feb 2010 12:16:43 -0500 |
parents | fc879f361bda |
children | 5150ceb4dbb4 |
comparison
equal
deleted
inserted
replaced
10312:cbc402e64d83 | 10313:f3b65e1ae355 |
---|---|
86 octave_base_value *empty_clone (void) const { return new octave_char_matrix_str (); } | 86 octave_base_value *empty_clone (void) const { return new octave_char_matrix_str (); } |
87 | 87 |
88 type_conv_info numeric_conversion_function (void) const; | 88 type_conv_info numeric_conversion_function (void) const; |
89 | 89 |
90 octave_value do_index_op (const octave_value_list& idx, | 90 octave_value do_index_op (const octave_value_list& idx, |
91 bool resize_ok = false) | 91 bool resize_ok = false) |
92 { return do_index_op_internal (idx, resize_ok); } | 92 { return do_index_op_internal (idx, resize_ok); } |
93 | 93 |
94 octave_value squeeze (void) const | 94 octave_value squeeze (void) const |
95 { return octave_value (charNDArray (matrix.squeeze ())); } | 95 { return octave_value (charNDArray (matrix.squeeze ())); } |
96 | 96 |
127 | 127 |
128 octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const | 128 octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const |
129 { return octave_value (matrix.sort (dim, mode)); } | 129 { return octave_value (matrix.sort (dim, mode)); } |
130 | 130 |
131 octave_value sort (Array<octave_idx_type> &sidx, octave_idx_type dim = 0, | 131 octave_value sort (Array<octave_idx_type> &sidx, octave_idx_type dim = 0, |
132 sortmode mode = ASCENDING) const | 132 sortmode mode = ASCENDING) const |
133 { return octave_value (matrix.sort (sidx, dim, mode)); } | 133 { return octave_value (matrix.sort (sidx, dim, mode)); } |
134 | 134 |
135 bool print_as_scalar (void) const { return (rows () <= 1); } | 135 bool print_as_scalar (void) const { return (rows () <= 1); } |
136 | 136 |
137 void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; | 137 void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; |
141 bool load_ascii (std::istream& is); | 141 bool load_ascii (std::istream& is); |
142 | 142 |
143 bool save_binary (std::ostream& os, bool& save_as_floats); | 143 bool save_binary (std::ostream& os, bool& save_as_floats); |
144 | 144 |
145 bool load_binary (std::istream& is, bool swap, | 145 bool load_binary (std::istream& is, bool swap, |
146 oct_mach_info::float_format fmt); | 146 oct_mach_info::float_format fmt); |
147 | 147 |
148 #if defined (HAVE_HDF5) | 148 #if defined (HAVE_HDF5) |
149 bool save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats); | 149 bool save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats); |
150 | 150 |
151 bool load_hdf5 (hid_t loc_id, const char *name); | 151 bool load_hdf5 (hid_t loc_id, const char *name); |
152 #endif | 152 #endif |
153 | 153 |
154 int write (octave_stream& os, int block_size, | 154 int write (octave_stream& os, int block_size, |
155 oct_data_conv::data_type output_type, int skip, | 155 oct_data_conv::data_type output_type, int skip, |
156 oct_mach_info::float_format flt_fmt) const | 156 oct_mach_info::float_format flt_fmt) const |
157 { return os.write (matrix, block_size, output_type, skip, flt_fmt); } | 157 { return os.write (matrix, block_size, output_type, skip, flt_fmt); } |
158 | 158 |
159 protected: | 159 protected: |
160 | 160 |
161 octave_value do_index_op_internal (const octave_value_list& idx, | 161 octave_value do_index_op_internal (const octave_value_list& idx, |
162 bool resize_ok, char type = '"'); | 162 bool resize_ok, char type = '"'); |
163 | 163 |
164 private: | 164 private: |
165 | 165 |
166 DECLARE_OCTAVE_ALLOCATOR | 166 DECLARE_OCTAVE_ALLOCATOR |
167 | 167 |
227 { return octave_value (matrix.diag (k), '\''); } | 227 { return octave_value (matrix.diag (k), '\''); } |
228 | 228 |
229 bool is_sq_string (void) const { return true; } | 229 bool is_sq_string (void) const { return true; } |
230 | 230 |
231 octave_value do_index_op (const octave_value_list& idx, | 231 octave_value do_index_op (const octave_value_list& idx, |
232 bool resize_ok = false) | 232 bool resize_ok = false) |
233 { return do_index_op_internal (idx, resize_ok, '\''); } | 233 { return do_index_op_internal (idx, resize_ok, '\''); } |
234 | 234 |
235 | 235 |
236 octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const | 236 octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const |
237 { return octave_value (matrix.sort (dim, mode), '\''); } | 237 { return octave_value (matrix.sort (dim, mode), '\''); } |
238 | 238 |
239 octave_value sort (Array<octave_idx_type> &sidx, octave_idx_type dim = 0, | 239 octave_value sort (Array<octave_idx_type> &sidx, octave_idx_type dim = 0, |
240 sortmode mode = ASCENDING) const | 240 sortmode mode = ASCENDING) const |
241 { return octave_value (matrix.sort (sidx, dim, mode), '\''); } | 241 { return octave_value (matrix.sort (sidx, dim, mode), '\''); } |
242 | 242 |
243 private: | 243 private: |
244 | 244 |
245 DECLARE_OCTAVE_ALLOCATOR | 245 DECLARE_OCTAVE_ALLOCATOR |