Go to the source code of this file.
Functions | |
template<class Range > | |
bool | rangesIntersect (const Range &a, const Range &b) |
template<class Range , class Less > | |
bool | rangesIntersect (const Range &a, const Range &b, const Less &less) |
Utility for checking efficiently if two one-dimantional intervals intersect. Precondition: the intervals are not empty, i.e. for i in a,b i.first <= i.second. The Range template argument is expected to have the std::pair interface, i.e. for Range instance r r.first is the beginning of the interval and r.second is the end of the interval.
Definition at line 14 of file rangesIntersect.h.
Referenced by LayerCollector::allLayers(), OuterDetCompatibility::checkPhi(), OuterDetCompatibility::checkR(), OuterDetCompatibility::checkZ(), PixelRecoRange< float >::hasIntersection(), barrelUtil::overlap(), tkDetUtil::overlapInPhi(), and StartingLayerFinder::startingLayers().