CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Protected Attributes
TopProjectorDeltaROverlap< Top, Bottom > Class Template Reference

This checks matching based on delta R. More...

#include <TopProjector.h>

Inheritance diagram for TopProjectorDeltaROverlap< Top, Bottom >:

Public Types

typedef edm::FwdPtr< Bottom > BottomFwdPtr
 
typedef edm::FwdPtr< Top > TopFwdPtr
 

Public Member Functions

bool operator() (TopFwdPtr const &top) const
 
void setBottom (BottomFwdPtr const &bottom)
 
 TopProjectorDeltaROverlap ()
 
 TopProjectorDeltaROverlap (edm::ParameterSet const &config)
 

Protected Attributes

float botEta_
 
float botPhi_
 
BottomFwdPtr const * bottom_
 
const Bottom * bottomCPtr_
 
double deltaR2_
 

Detailed Description

template<class Top, class Bottom>
class TopProjectorDeltaROverlap< Top, Bottom >

This checks matching based on delta R.

Definition at line 104 of file TopProjector.h.

Member Typedef Documentation

template<class Top , class Bottom >
typedef edm::FwdPtr<Bottom> TopProjectorDeltaROverlap< Top, Bottom >::BottomFwdPtr

Definition at line 108 of file TopProjector.h.

template<class Top , class Bottom >
typedef edm::FwdPtr<Top> TopProjectorDeltaROverlap< Top, Bottom >::TopFwdPtr

Definition at line 107 of file TopProjector.h.

Constructor & Destructor Documentation

template<class Top , class Bottom >
TopProjectorDeltaROverlap< Top, Bottom >::TopProjectorDeltaROverlap ( )
inlineexplicit

Definition at line 110 of file TopProjector.h.

References TopProjectorFwdPtrOverlap< Top, Bottom >::bottom_.

110 {bottom_ = 0;}
BottomFwdPtr const * bottom_
Definition: TopProjector.h:131
template<class Top , class Bottom >
TopProjectorDeltaROverlap< Top, Bottom >::TopProjectorDeltaROverlap ( edm::ParameterSet const &  config)
inlineexplicit

Definition at line 111 of file TopProjector.h.

111  :
112  deltaR2_( config.getParameter<double>("deltaR") ),
113  bottom_(0),bottomCPtr_(0),botEta_(-999.f),botPhi_(0.f)
114  {deltaR2_*=deltaR2_;}
const Bottom * bottomCPtr_
Definition: TopProjector.h:132
Definition: config.py:1
double f[11][100]
BottomFwdPtr const * bottom_
Definition: TopProjector.h:131

Member Function Documentation

template<class Top , class Bottom >
bool TopProjectorDeltaROverlap< Top, Bottom >::operator() ( TopFwdPtr const &  top) const
inline

Definition at line 123 of file TopProjector.h.

References reco::deltaR2(), electronMatch_cfi::matched, and TtFullHadDaughter::Top.

123  {
124  const Top& oTop = *top; float topEta = oTop.eta(); float topPhi = oTop.phi();
125  bool matched = reco::deltaR2( topEta, topPhi, botEta_, botPhi_) < deltaR2_;
126  return matched;
127  }
static const std::string Top
T1 deltaR2(T1 eta1, T2 phi1, T3 eta2, T4 phi2)
Definition: deltaR.h:36
template<class Top , class Bottom >
void TopProjectorDeltaROverlap< Top, Bottom >::setBottom ( BottomFwdPtr const &  bottom)
inline

Definition at line 117 of file TopProjector.h.

References TopProjectorFwdPtrOverlap< Top, Bottom >::bottom_.

117  {
118  bottom_ = &bottom; bottomCPtr_=&**bottom_;
119  botEta_ = bottomCPtr_->eta();
120  botPhi_ = bottomCPtr_->phi();
121  }
const Bottom * bottomCPtr_
Definition: TopProjector.h:132
BottomFwdPtr const * bottom_
Definition: TopProjector.h:131

Member Data Documentation

template<class Top , class Bottom >
float TopProjectorDeltaROverlap< Top, Bottom >::botEta_
protected

Definition at line 133 of file TopProjector.h.

template<class Top , class Bottom >
float TopProjectorDeltaROverlap< Top, Bottom >::botPhi_
protected

Definition at line 133 of file TopProjector.h.

template<class Top , class Bottom >
BottomFwdPtr const* TopProjectorDeltaROverlap< Top, Bottom >::bottom_
protected

Definition at line 131 of file TopProjector.h.

template<class Top , class Bottom >
const Bottom* TopProjectorDeltaROverlap< Top, Bottom >::bottomCPtr_
protected

Definition at line 132 of file TopProjector.h.

template<class Top , class Bottom >
double TopProjectorDeltaROverlap< Top, Bottom >::deltaR2_
protected

Definition at line 130 of file TopProjector.h.