SimGrid  3.21
Versatile Simulation of Distributed Systems
simgrid::xbt::HeapComparator< Pair > Class Template Reference

Detailed Description

template<class Pair>
class simgrid::xbt::HeapComparator< Pair >

Comparator class for using with std::priority_queue or boost::heap.

Compare two std::pair by their first element (of type double), and return true when the first is greater than the second. Useful to have priority queues with the smallest element on top.

#include <utility.hpp>

Public Member Functions

bool operator() (const Pair &a, const Pair &b) const
 

Member Function Documentation

◆ operator()()

template<class Pair >
bool simgrid::xbt::HeapComparator< Pair >::operator() ( const Pair &  a,
const Pair &  b 
) const
inline

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