CMS 3D CMS Logo

List of all members | Public Member Functions
MedianDeDxEstimator Class Reference

#include <MedianDeDxEstimator.h>

Inheritance diagram for MedianDeDxEstimator:
BaseDeDxEstimator

Public Member Functions

std::pair< float, float > dedx (const reco::DeDxHitCollection &Hits) override
 
 MedianDeDxEstimator (const edm::ParameterSet &iConfig)
 
- Public Member Functions inherited from BaseDeDxEstimator
virtual void beginRun (edm::Run const &run, const edm::EventSetup &iSetup)
 
virtual ~BaseDeDxEstimator ()
 

Detailed Description

Definition at line 8 of file MedianDeDxEstimator.h.

Constructor & Destructor Documentation

MedianDeDxEstimator::MedianDeDxEstimator ( const edm::ParameterSet iConfig)
inline

Definition at line 11 of file MedianDeDxEstimator.h.

11  {
12  }

Member Function Documentation

std::pair<float,float> MedianDeDxEstimator::dedx ( const reco::DeDxHitCollection Hits)
inlineoverridevirtual

Implements BaseDeDxEstimator.

Definition at line 14 of file MedianDeDxEstimator.h.

14  {
15  if(Hits.empty())return std::make_pair(-1,-1);
16  return std::make_pair(Hits[Hits.size()/2].charge(),-1);
17  }