CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Protected Attributes
TrackingRecHitProduct Class Reference

#include <TrackingRecHitProduct.h>

Public Types

typedef std::pair
< FastSingleTrackerRecHit,
std::vector< SimHitIdPair > > 
RecHitToSimHitIdPairs
 
typedef std::pair< unsigned
int, const PSimHit * > 
SimHitIdPair
 

Public Member Functions

virtual void addRecHit (const FastSingleTrackerRecHit &recHit, std::vector< SimHitIdPair > simHitIdPairs={})
 
const DetIdgetDetId () const
 
virtual const std::vector
< RecHitToSimHitIdPairs > & 
getRecHitToSimHitIdPairs () const
 
virtual std::vector
< SimHitIdPair > & 
getSimHitIdPairs ()
 
virtual unsigned int numberOfRecHits () const
 
 TrackingRecHitProduct (const DetId &detId, std::vector< SimHitIdPair > &simHitsIdPairList)
 
virtual ~TrackingRecHitProduct ()
 

Protected Attributes

const DetId_detId
 
std::vector
< RecHitToSimHitIdPairs
_recHits
 
std::vector< SimHitIdPair_simHitsIdPairList
 

Detailed Description

Definition at line 13 of file TrackingRecHitProduct.h.

Member Typedef Documentation

Definition at line 17 of file TrackingRecHitProduct.h.

typedef std::pair<unsigned int,const PSimHit*> TrackingRecHitProduct::SimHitIdPair

Definition at line 16 of file TrackingRecHitProduct.h.

Constructor & Destructor Documentation

TrackingRecHitProduct::TrackingRecHitProduct ( const DetId detId,
std::vector< SimHitIdPair > &  simHitsIdPairList 
)
inline

Definition at line 26 of file TrackingRecHitProduct.h.

26  :
27  _detId(detId),
28  _simHitsIdPairList(simHitsIdPairList)
29  {
30  }
std::vector< SimHitIdPair > _simHitsIdPairList
virtual TrackingRecHitProduct::~TrackingRecHitProduct ( )
inlinevirtual

Definition at line 61 of file TrackingRecHitProduct.h.

62  {
63  }

Member Function Documentation

virtual void TrackingRecHitProduct::addRecHit ( const FastSingleTrackerRecHit recHit,
std::vector< SimHitIdPair simHitIdPairs = {} 
)
inlinevirtual

Definition at line 42 of file TrackingRecHitProduct.h.

42  {})
43  {
44  _recHits.push_back(std::make_pair(recHit,simHitIdPairs));
45  for (unsigned int isimhit = 0; isimhit < simHitIdPairs.size(); ++isimhit)
46  {
47  _recHits.back().first.addSimTrackId(simHitIdPairs[isimhit].second->trackId());
48  }
49  }
U second(std::pair< T, U > const &p)
std::vector< RecHitToSimHitIdPairs > _recHits
const DetId& TrackingRecHitProduct::getDetId ( void  ) const
inline

Definition at line 32 of file TrackingRecHitProduct.h.

References _detId.

33  {
34  return _detId;
35  }
virtual const std::vector<RecHitToSimHitIdPairs>& TrackingRecHitProduct::getRecHitToSimHitIdPairs ( ) const
inlinevirtual

Definition at line 51 of file TrackingRecHitProduct.h.

References _recHits.

52  {
53  return _recHits;
54  }
std::vector< RecHitToSimHitIdPairs > _recHits
virtual std::vector<SimHitIdPair>& TrackingRecHitProduct::getSimHitIdPairs ( )
inlinevirtual

Definition at line 37 of file TrackingRecHitProduct.h.

References _simHitsIdPairList.

38  {
39  return _simHitsIdPairList;
40  }
std::vector< SimHitIdPair > _simHitsIdPairList
virtual unsigned int TrackingRecHitProduct::numberOfRecHits ( void  ) const
inlinevirtual

Definition at line 56 of file TrackingRecHitProduct.h.

References _recHits.

57  {
58  return _recHits.size();
59  }
std::vector< RecHitToSimHitIdPairs > _recHits

Member Data Documentation

const DetId& TrackingRecHitProduct::_detId
protected

Definition at line 19 of file TrackingRecHitProduct.h.

Referenced by getDetId().

std::vector<RecHitToSimHitIdPairs> TrackingRecHitProduct::_recHits
protected

Definition at line 23 of file TrackingRecHitProduct.h.

Referenced by getRecHitToSimHitIdPairs(), and numberOfRecHits().

std::vector<SimHitIdPair> TrackingRecHitProduct::_simHitsIdPairList
protected

Definition at line 21 of file TrackingRecHitProduct.h.

Referenced by getSimHitIdPairs().