LexicographicalCompare

template<typename T>
struct LexicographicalCompare

Defined in order.hpp.

A stateless struct with binary call operator using std::lexicographical_compare.

This only exists to be used as a template parameter, and has no advantages over using std::lexicographical_compare otherwise.

See

std::lexicographical_compare.

Template Parameters
  • T: the type of the objects to be compared.

Public Functions

bool operator()(T const &x, T const &y)

Call operator that compares x and y using std::lexicographical_compare.

Return

A bool.

Exceptions

See std::lexicographical_compare.

Complexity

See std::lexicographical_compare.

Parameters
  • x: const reference to the first object for comparison

  • y: const reference to the second object for comparison