CMS 3D CMS Logo

List of all members | Public Member Functions
CastorDbASCIIIO::DetIdLess Class Reference

Public Member Functions

bool operator() (DetId fFirst, DetId fSecond) const
 

Detailed Description

Definition at line 17 of file CastorDbASCIIIO.cc.

Member Function Documentation

bool CastorDbASCIIIO::DetIdLess::operator() ( DetId  fFirst,
DetId  fSecond 
) const
inline

Definition at line 19 of file CastorDbASCIIIO.cc.

References HcalDetId::depth(), connectstrParser::f1, plotBeamSpotDB::first, HcalGenericDetId::genericSubdet(), HcalDetId::ietaAbs(), HcalDetId::iphi(), HcalGenericDetId::isHcalDetId(), DetId::rawId(), edm::second(), and HcalDetId::zside().

19  {
20  HcalGenericDetId first(fFirst);
21  HcalGenericDetId second(fSecond);
22  if (first.genericSubdet() != second.genericSubdet())
23  return first.genericSubdet() < second.genericSubdet();
24  if (first.isHcalDetId()) {
26  HcalDetId s1(second);
27  return f1.zside() != s1.zside()
28  ? f1.zside() < s1.zside()
29  : f1.iphi() != s1.iphi()
30  ? f1.iphi() < s1.iphi()
31  : f1.ietaAbs() != s1.ietaAbs() ? f1.ietaAbs() < s1.ietaAbs() : f1.depth() < s1.depth();
32  } else {
33  return first.rawId() < second.rawId();
34  }
35  }
U second(std::pair< T, U > const &p)