Mercurial > octave-nkf
diff liboctave/Range.h @ 7458:1032e24f199f
make sort work for ranges
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 07 Feb 2008 22:36:11 -0500 |
parents | a1dbe9d80eee |
children | 2467639bd8c0 |
line wrap: on
line diff
--- a/liboctave/Range.h Thu Feb 07 15:58:37 2008 -0500 +++ b/liboctave/Range.h Thu Feb 07 22:36:11 2008 -0500 @@ -25,7 +25,9 @@ #define octave_Range_h 1 #include <iostream> + #include "dMatrix.h" +#include "oct-sort.h" class OCTAVE_API @@ -60,7 +62,13 @@ double min (void) const; double max (void) const; - void sort (void); + void sort_internal (bool ascending = true); + void sort_internal (Array<octave_idx_type>& sidx, bool ascending = true); + + Range sort (octave_idx_type dim = 0, sortmode mode = UNDEFINED) const; + + Range sort (Array<octave_idx_type>& sidx, octave_idx_type dim = 0, + sortmode mode = UNDEFINED) const; void set_base (double b) {