thepeg is hosted by Hepforge, IPPP Durham
ThePEG  2.2.1
algorithm.h File Reference

This file implements a number of interfaces to std:: algorithms, modified to take a whole container as argument rather than a range of iterators, Also defines IteratorRange to encapsulate a range of iterators and corresponding algorithms. More...

#include "ThePEG/Config/ThePEG.h"
#include <algorithm>

Go to the source code of this file.

Classes

struct  ThePEG::IteratorRange< Iterator >
 A pair of iterators to be used in specialized algorithms instead of the standard first, last construction. More...
 

Namespaces

 ThePEG
 This is the main namespace within which all identifiers in ThePEG are declared.
 

Functions

template<typename Container >
IteratorRange< typename Container::iterator > ThePEG::range (Container &c)
 Return an IteratorRange corresponding to the whole container. More...
 
template<typename Container >
IteratorRange< typename Container::const_iterator > ThePEG::range (const Container &c)
 Return an IteratorRange of const iterators corresponding to the whole container. More...
 
template<typename Container >
IteratorRange< typename Container::reverse_iterator > ThePEG::rrange (Container &c)
 Return an IteratorRange of reverse iterators corresponding to the whole container. More...
 
template<typename Container >
IteratorRange< typename Container::const_reverse_iterator > ThePEG::rrange (const Container &c)
 Return an IteratorRange of reverse const iterators corresponding to the whole container. More...
 
template<typename Iterator , typename FNC >
FNC ThePEG::for_each (IteratorRange< Iterator > r, FNC f)
 The std::for_each function taking an IteratorRange as argument. More...
 
template<typename Iterator , typename T >
Iterator ThePEG::find (IteratorRange< Iterator > r, const T &t)
 The std::find function taking an IteratorRange as argument. More...
 
template<typename Iterator , typename Pred >
Iterator ThePEG::find_if (IteratorRange< Iterator > r, Pred p)
 The std::find_if function taking an IteratorRange as argument. More...
 
template<typename Iterator , typename T >
void ThePEG::replace (IteratorRange< Iterator > r, const T &oval, const T &nval)
 The std::replace function taking an IteratorRange as argument. More...
 
template<typename Cont , typename FNC >
FNC ThePEG::for_each (Cont &c, FNC f)
 The std::for_each function taking a whole container as argument. More...
 
template<typename Cont , typename FNC >
FNC ThePEG::for_each (const Cont &c, FNC f)
 The std::for_each function taking a whole const container as argument. More...
 
template<typename Cont , typename Type >
Cont::iterator ThePEG::find (Cont &c, const Type &t)
 The std::find function taking a whole container as argument. More...
 
template<typename Cont , typename Type >
Cont::const_iterator ThePEG::find (const Cont &c, const Type &t)
 The std::find function taking a whole const container as argument. More...
 
template<typename Cont , typename Pred >
Cont::iterator ThePEG::find_if (Cont &c, const Pred &p)
 The std::find_if function taking a whole container as argument. More...
 
template<typename Cont , typename Pred >
Cont::const_iterator ThePEG::find_if (const Cont &c, const Pred &p)
 The std::find_if function taking a whole const container as argument. More...
 
template<typename Cont , typename T >
void ThePEG::replace (Cont &c, const T &oval, const T &nval)
 The std::replace function taking a whole container as argument. More...
 

Detailed Description

This file implements a number of interfaces to std:: algorithms, modified to take a whole container as argument rather than a range of iterators, Also defines IteratorRange to encapsulate a range of iterators and corresponding algorithms.

Definition in file algorithm.h.