Elm  1.0
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
elm::AssocComparator< K, T, C > Class Template Reference

#include <elm/compare.h>

Public Types

typedef Pair< K, T > pair_t
 

Static Public Member Functions

static int compare (const pair_t &v1, const pair_t &v2)
 

Detailed Description

template<class K, class T, class C = Comparator<K>>
class elm::AssocComparator< K, T, C >

An associative comparator may be used to transform an ordered data structure into a map. If the items of ordered data structure are represented as pair of (key, values), this comparator provides comparison of items based on the key member.

This class is also the default comparator of pairs.

Parameters
KKey type.
TValue type.
CComparator for the key.

Member Typedef Documentation

template<class K, class T, class C = Comparator<K>>
typedef Pair<K, T> elm::AssocComparator< K, T, C >::pair_t

Member Function Documentation

template<class K, class T, class C = Comparator<K>>
static int elm::AssocComparator< K, T, C >::compare ( const pair_t v1,
const pair_t v2 
)
static

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