Navigation

Operators and Keywords

Function List:

C++ API

octave_sort< T > Class Template Reference

#include <oct-sort.h>

Collaboration diagram for octave_sort< T >:

List of all members.


Classes

struct  MergeState
struct  s_slice

Public Types

typedef bool(* compare_fcn_type )(typename ref_param< T >::type, typename ref_param< T >::type)

Public Member Functions

 octave_sort (void)
 octave_sort (compare_fcn_type)
 ~octave_sort (void)
void set_compare (compare_fcn_type comp)
void set_compare (sortmode mode)
void sort (T *data, octave_idx_type nel)
void sort (T *data, octave_idx_type *idx, octave_idx_type nel)
bool is_sorted (const T *data, octave_idx_type nel)
void sort_rows (const T *data, octave_idx_type *idx, octave_idx_type rows, octave_idx_type cols)
bool is_sorted_rows (const T *data, octave_idx_type rows, octave_idx_type cols)
octave_idx_type lookup (const T *data, octave_idx_type nel, const T &value)
void lookup (const T *data, octave_idx_type nel, const T *values, octave_idx_type nvalues, octave_idx_type *idx, octave_idx_type offset=0)
void lookupm (const T *data, octave_idx_type nel, const T *values, octave_idx_type nvalues, octave_idx_type *idx)
void lookupb (const T *data, octave_idx_type nel, const T *values, octave_idx_type nvalues, bool *match)
void nth_element (T *data, octave_idx_type nel, octave_idx_type lo, octave_idx_type up=-1)

Static Public Member Functions

static bool ascending_compare (typename ref_param< T >::type, typename ref_param< T >::type)
static bool descending_compare (typename ref_param< T >::type, typename ref_param< T >::type)

template<class T>
class octave_sort< T >


Member Typedef Documentation

template<class T >
typedef bool(* octave_sort< T >::compare_fcn_type)(typename ref_param< T >::type, typename ref_param< T >::type)


Constructor & Destructor Documentation

template<class T >
octave_sort< T >::octave_sort ( void   )  [inline]

template<class T >
octave_sort< T >::octave_sort ( compare_fcn_type  comp  )  [inline]

template<class T >
octave_sort< T >::~octave_sort ( void   )  [inline]


Member Function Documentation

template<class T >
bool octave_sort< T >::ascending_compare ( typename ref_param< T >::type  x,
typename ref_param< T >::type  y 
) [inline, static]

template<class T >
bool octave_sort< T >::descending_compare ( typename ref_param< T >::type  x,
typename ref_param< T >::type  y 
) [inline, static]

template<class T >
bool octave_sort< T >::is_sorted ( const T data,
octave_idx_type  nel 
) [inline]

template<class T >
bool octave_sort< T >::is_sorted_rows ( const T data,
octave_idx_type  rows,
octave_idx_type  cols 
) [inline]

template<class T >
void octave_sort< T >::lookup ( const T data,
octave_idx_type  nel,
const T values,
octave_idx_type  nvalues,
octave_idx_type idx,
octave_idx_type  offset = 0 
) [inline]

template<class T >
octave_idx_type octave_sort< T >::lookup ( const T data,
octave_idx_type  nel,
const T value 
) [inline]

template<class T >
void octave_sort< T >::lookupb ( const T data,
octave_idx_type  nel,
const T values,
octave_idx_type  nvalues,
bool match 
) [inline]

template<class T >
void octave_sort< T >::lookupm ( const T data,
octave_idx_type  nel,
const T values,
octave_idx_type  nvalues,
octave_idx_type idx 
) [inline]

template<class T >
void octave_sort< T >::nth_element ( T data,
octave_idx_type  nel,
octave_idx_type  lo,
octave_idx_type  up = -1 
) [inline]

template<class T >
void octave_sort< T >::set_compare ( sortmode  mode  )  [inline]

template<class T >
void octave_sort< T >::set_compare ( compare_fcn_type  comp  )  [inline]

template<class T >
void octave_sort< T >::sort ( T data,
octave_idx_type idx,
octave_idx_type  nel 
) [inline]

template<class T >
void octave_sort< T >::sort ( T data,
octave_idx_type  nel 
) [inline]

template<class T >
void octave_sort< T >::sort_rows ( const T data,
octave_idx_type idx,
octave_idx_type  rows,
octave_idx_type  cols 
) [inline]


The documentation for this class was generated from the following files: