COOLFluiD  Release kernel
COOLFluiD is a Collaborative Simulation Environment (CSE) focused on complex MultiPhysics simulations.
Public Member Functions | List of all members
Map< KEY, DATA >::Compare Class Reference

Public Member Functions

bool operator() (const std::pair< KEY, DATA > &p1, const KEY &key) const
 
bool operator() (const KEY &key, const std::pair< KEY, DATA > &p1) const
 

Detailed Description

template<typename KEY, typename DATA>
class cf3::common::Map< KEY, DATA >::Compare

This class represents a functor object that is used to compare a given key with the key in a std::pair. This functor is passed as an argument in the std::equal_range function in order to find all the pairs containing the specified key.

Author
Andrea Lani

Definition at line 233 of file Map.hpp.

Member Function Documentation

bool operator() ( const std::pair< KEY, DATA > &  p1,
const KEY &  key 
) const
inline

Overloading of the operator() that makes this class acting as a functor

Parameters
p1pair whose key is used as first term of comparison
keygiven key used as second term of comparison
Returns
true if(p1.first < key)
false if(p1.first >= key)
Postcondition
this is the first test to see if p1.first is == key during the search with find()

Definition at line 243 of file Map.hpp.

bool operator() ( const KEY &  key,
const std::pair< KEY, DATA > &  p1 
) const
inline

Overloading of the operator() that makes this class acting as a functor

Parameters
keygiven key used as first term of comparison
p1pair whose key is used as second term of comparison
Returns
true if(p1.first > key)
false if(p1.first <= key)
Postcondition
this is the second test to see if p1.first is == key during the search with find()

Definition at line 255 of file Map.hpp.


The documentation for this class was generated from the following file:
Send comments to:
COOLFluiD Web Admin