CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
TrackerTopology::SameLayerComparator Class Reference

#include <TrackerTopology.h>

Public Member Functions

bool operator() (DetId i1, DetId i2) const
 
bool operator() (uint32_t i1, uint32_t i2) const
 
 SameLayerComparator (const TrackerTopology *topo)
 

Private Attributes

const TrackerTopologytopo_
 

Detailed Description

Definition at line 114 of file TrackerTopology.h.

Constructor & Destructor Documentation

◆ SameLayerComparator()

TrackerTopology::SameLayerComparator::SameLayerComparator ( const TrackerTopology topo)
inlineexplicit

Definition at line 116 of file TrackerTopology.h.

116 : topo_(topo) {}

Member Function Documentation

◆ operator()() [1/2]

bool TrackerTopology::SameLayerComparator::operator() ( DetId  i1,
DetId  i2 
) const
inline

Definition at line 118 of file TrackerTopology.h.

References testProducerWithPsetDescEmpty_cfi::i1, testProducerWithPsetDescEmpty_cfi::i2, TrackerTopology::layer(), TrackerTopology::side(), and topo_.

118  {
119  if (i1.det() == i2.det() && i1.subdetId() == i2.subdetId() && topo_->side(i1) == topo_->side(i2) &&
120  topo_->layer(i1) == topo_->layer(i2)) {
121  return false;
122  }
123  return i1 < i2;
124  }
unsigned int side(const DetId &id) const
unsigned int layer(const DetId &id) const

◆ operator()() [2/2]

bool TrackerTopology::SameLayerComparator::operator() ( uint32_t  i1,
uint32_t  i2 
) const
inline

Member Data Documentation

◆ topo_

const TrackerTopology* TrackerTopology::SameLayerComparator::topo_
private

Definition at line 129 of file TrackerTopology.h.

Referenced by operator()().