CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions
TauConeIsolationAlgo< T, C, M > Class Template Reference

#include <TauConeIsolationAlgo.h>

Public Member Functions

const edm::RefVector< C > operator() (const T &coneAxis, double coneSize, const edm::RefVector< C > &elements, const M &metric) const
 
 TauConeIsolationAlgo ()
 
 ~TauConeIsolationAlgo ()
 

Detailed Description

template<typename T, typename C, typename M>
class TauConeIsolationAlgo< T, C, M >

Definition at line 9 of file TauConeIsolationAlgo.h.

Constructor & Destructor Documentation

template<typename T , typename C , typename M >
TauConeIsolationAlgo< T, C, M >::TauConeIsolationAlgo ( )
inline

Definition at line 11 of file TauConeIsolationAlgo.h.

11 {}
template<typename T , typename C , typename M >
TauConeIsolationAlgo< T, C, M >::~TauConeIsolationAlgo ( )
inline

Definition at line 12 of file TauConeIsolationAlgo.h.

12 {}

Member Function Documentation

template<typename T , typename C , typename M >
const edm::RefVector< C > TauConeIsolationAlgo< T, C, M >::operator() ( const T coneAxis,
double  coneSize,
const edm::RefVector< C > &  elements,
const M &  metric 
) const

Definition at line 18 of file TauConeIsolationAlgo.h.

References edm::RefVector< C, T, F >::begin(), HLT_25ns14e33_v1_cff::distance, edm::RefVector< C, T, F >::end(), and edm::RefVector< C, T, F >::push_back().

19 {
20  edm::RefVector<C> elementsInCone;
21  for( typename edm::RefVector<C>::const_iterator element = elements.begin();
22  element != elements.end(); ++element ) {
23  double distance = metric(coneAxis, (*element)->momentum());
24 
25  if ( distance <= coneSize ) {
26  elementsInCone.push_back(*element);
27  }
28  }
29 
30  return elementsInCone;
31 }
const_iterator end() const
Termination of iteration.
Definition: RefVector.h:249
const_iterator begin() const
Initialize an iterator over the RefVector.
Definition: RefVector.h:244
void push_back(value_type const &ref)
Add a Ref&lt;C, T&gt; to the RefVector.
Definition: RefVector.h:64