diff src/ov-str-mat.h @ 5533:667ad2becb63

[project @ 2005-11-10 21:40:48 by jwe]
author jwe
date Thu, 10 Nov 2005 21:40:49 +0000
parents c7e3cf2fce3e
children 6286c96121c2
line wrap: on
line diff
--- a/src/ov-str-mat.h
+++ b/src/ov-str-mat.h
@@ -93,6 +93,16 @@
   octave_value reshape (const dim_vector& new_dims) const
     { return octave_value (charNDArray (matrix.reshape (new_dims)), true); }
 
+  octave_value permute (const Array<int>& vec, bool inv = false) const
+    { return octave_value (charNDArray (matrix.permute (vec, inv)), true); }
+
+  octave_value resize (const dim_vector& dv) const
+    {
+      charNDArray retval (matrix);
+      retval.resize (dv);
+      return octave_value (retval, true);
+    }
+
   bool is_string (void) const { return true; }
 
   bool is_real_type (void) const { return false; }
@@ -195,6 +205,19 @@
   octave_value *clone (void) const { return new octave_char_matrix_sq_str (*this); }
   octave_value *empty_clone (void) const { return new octave_char_matrix_sq_str (); }
 
+  octave_value reshape (const dim_vector& new_dims) const
+    { return octave_value (charNDArray (matrix.reshape (new_dims)), true, '\''); }
+
+  octave_value permute (const Array<int>& vec, bool inv = false) const
+    { return octave_value (charNDArray (matrix.permute (vec, inv)), true, '\''); }
+
+  octave_value resize (const dim_vector& dv) const
+    {
+      charNDArray retval (matrix);
+      retval.resize (dv);
+      return octave_value (retval, true, '\'');
+    }
+
   bool is_sq_string (void) const { return true; }
 
   octave_value do_index_op (const octave_value_list& idx, int resize_ok)