latest version v1.9 - last update 10 Apr 2010 |
The parameters for the class sort. More...
#include <ltiSort.h>
Public Types | |
enum | eOrder { Ascending, Descending } |
Public Member Functions | |
parameters () | |
parameters (const parameters &other) | |
~parameters () | |
const char * | getTypeName () const |
parameters & | copy (const parameters &other) |
virtual functor::parameters * | clone () const |
virtual bool | read (ioHandler &handler, const bool complete=true) |
virtual bool | write (ioHandler &handler, const bool complete=true) const |
Public Attributes | |
int | thresholdForBubble |
eOrder | order |
The parameters for the class sort.
enum lti::sort::parameters::eOrder |
lti::sort< T >::parameters::parameters | ( | void | ) | [inline] |
Default constructor.
Reimplemented from lti::functor::parameters.
Reimplemented in lti::sort2< T, U >::parameters.
References _LTI_PERFORMANCE_SORT_STOP_QUICKSORT, lti::sort< T >::parameters::Ascending, lti::sort< T >::parameters::order, and lti::sort< T >::parameters::thresholdForBubble.
Referenced by lti::sort< T >::parameters::clone().
lti::sort< T >::parameters::parameters | ( | const parameters & | other | ) | [inline] |
Copy constructor.
other | the parameters object to be copied |
Reimplemented in lti::sort2< T, U >::parameters.
References lti::sort< T >::parameters::copy().
lti::sort< T >::parameters::~parameters | ( | ) | [inline, virtual] |
Destructor.
Reimplemented from lti::functor::parameters.
Reimplemented in lti::sort2< T, U >::parameters.
virtual functor::parameters* lti::sort< T >::parameters::clone | ( | ) | const [inline, virtual] |
Returns a pointer to a clone of the parameters.
Implements lti::functor::parameters.
Reimplemented in lti::sort2< T, U >::parameters.
References lti::sort< T >::parameters::parameters().
parameters& lti::sort< T >::parameters::copy | ( | const parameters & | other | ) | [inline] |
Copy the contents of a parameters object.
other | the parameters object to be copied |
Reimplemented in lti::sort2< T, U >::parameters.
References lti::functor::parameters::copy(), lti::sort< T >::parameters::order, and lti::sort< T >::parameters::thresholdForBubble.
Referenced by lti::sort< T >::parameters::parameters().
const char* lti::sort< T >::parameters::getTypeName | ( | void | ) | const [inline, virtual] |
Returns name of this type.
Reimplemented from lti::functor::parameters.
Reimplemented in lti::sort2< T, U >::parameters.
virtual bool lti::sort< T >::parameters::read | ( | ioHandler & | handler, | |
const bool | complete = true | |||
) | [inline, virtual] |
Read the parameters from the given ioHandler.
handler | the ioHandler to be used | |
complete | if true (the default) the enclosing begin/end will be also read, otherwise only the data block will be read. |
Reimplemented from lti::functor::parameters.
Reimplemented in lti::sort2< T, U >::parameters.
References lti::sort< T >::parameters::Ascending, lti::sort< T >::parameters::Descending, lti::sort< T >::parameters::order, lti::ioHandler::readBegin(), lti::ioHandler::readEnd(), and lti::sort< T >::parameters::thresholdForBubble.
virtual bool lti::sort< T >::parameters::write | ( | ioHandler & | handler, | |
const bool | complete = true | |||
) | const [inline, virtual] |
Write the parameters in the given ioHandler.
handler | the ioHandler to be used | |
complete | if true (the default) the enclosing begin/end will be also written, otherwise only the data block will be written. |
Reimplemented from lti::functor::parameters.
Reimplemented in lti::sort2< T, U >::parameters.
References lti::sort< T >::parameters::Ascending, lti::sort< T >::parameters::order, lti::sort< T >::parameters::thresholdForBubble, lti::ioHandler::writeBegin(), and lti::ioHandler::writeEnd().
eOrder lti::sort< T >::parameters::order |
Order of the sorting the default value is ascending order.
Referenced by lti::sort< T >::parameters::copy(), lti::sort< T >::parameters::parameters(), lti::sort< T >::parameters::read(), and lti::sort< T >::parameters::write().
int lti::sort< T >::parameters::thresholdForBubble |
For vector/matrices with size smaller than this value, a bubble sort will be used (this way is faster)!
The default value is usually 10, but if you configured your system for performance this value could change.
The best value can be found in the ltiPerformanceConfig.h file, under _LTI_PERFORMANCE_SORT_STOP_QUICKSORT.
Default value: 10 or better.
Referenced by lti::sort< T >::parameters::copy(), lti::sort< T >::parameters::parameters(), lti::sort< T >::parameters::read(), and lti::sort< T >::parameters::write().