CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
reco::TrackInfo Class Reference

#include <DataFormats/TrackAnalysisInfo/interface/TrackInfo.h>

Public Types

typedef reco::StateType StateType
 
typedef std::map< TrackingRecHitRef, TrackingRecHitInfoTrajectoryInfo
 default constructor More...
 

Public Member Functions

const LocalVector localTrackMomentum (StateType, TrackingRecHitRef) const
 
const LocalVector localTrackMomentumOnMono (StateType, TrackingRecHitRef) const
 
const LocalVector localTrackMomentumOnStereo (StateType, TrackingRecHitRef) const
 
const LocalPoint localTrackPosition (StateType, TrackingRecHitRef) const
 
const LocalPoint localTrackPositionOnMono (StateType, TrackingRecHitRef) const
 
const LocalPoint localTrackPositionOnStereo (StateType, TrackingRecHitRef) const
 
const TrajectorySeedseed () const
 
const PTrajectoryStateOnDetstateOnDet (StateType, TrackingRecHitRef) const
 
 TrackInfo ()
 
 TrackInfo (const TrajectorySeed &seed_, const TrajectoryInfo &trajstate)
 
const TrajectoryInfotrajStateMap () const
 
const RecHitType type (TrackingRecHitRef) const
 

Private Attributes

TrajectorySeed seed_
 
TrajectoryInfo trajstates_
 

Detailed Description

It contains additional info for tracker studies

Author
Chiara Genta

Definition at line 23 of file TrackInfo.h.

Member Typedef Documentation

◆ StateType

Definition at line 27 of file TrackInfo.h.

◆ TrajectoryInfo

default constructor

Definition at line 26 of file TrackInfo.h.

Constructor & Destructor Documentation

◆ TrackInfo() [1/2]

reco::TrackInfo::TrackInfo ( )
inline

Definition at line 29 of file TrackInfo.h.

29 {}

◆ TrackInfo() [2/2]

TrackInfo::TrackInfo ( const TrajectorySeed seed_,
const TrajectoryInfo trajstate 
)

Definition at line 6 of file TrackInfo.cc.

7  : seed_(seed), trajstates_(trajstates) {}

Member Function Documentation

◆ localTrackMomentum()

const LocalVector TrackInfo::localTrackMomentum ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 31 of file TrackInfo.cc.

31  {
32  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
33  if (states != trajstates_.end()) {
34  const PTrajectoryStateOnDet* state = states->second.stateOnDet(statetype);
35  if (state != nullptr)
36  return state->parameters().momentum();
37  } else
38  edm::LogError("TrackInfo") << "This rechit does not exist";
39  return LocalVector(0, 0, 0);
40 }

References LocalTrajectoryParameters::momentum(), PTrajectoryStateOnDet::parameters(), and trajstates_.

◆ localTrackMomentumOnMono()

const LocalVector TrackInfo::localTrackMomentumOnMono ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 42 of file TrackInfo.cc.

42  {
43  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
44  if (states != trajstates_.end())
45  return states->second.localTrackMomentumOnMono(statetype);
46  else
47  edm::LogError("TrackInfo") << "This rechit does not exist";
48  return LocalVector(0, 0, 0);
49 }

References trajstates_.

◆ localTrackMomentumOnStereo()

const LocalVector TrackInfo::localTrackMomentumOnStereo ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 51 of file TrackInfo.cc.

51  {
52  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
53  if (states != trajstates_.end())
54  return states->second.localTrackMomentumOnStereo(statetype);
55  return LocalVector(0, 0, 0);
56 }

References trajstates_.

◆ localTrackPosition()

const LocalPoint TrackInfo::localTrackPosition ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 58 of file TrackInfo.cc.

58  {
59  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
60  if (states != trajstates_.end()) {
61  const PTrajectoryStateOnDet* state = states->second.stateOnDet(statetype);
62  if (state != nullptr)
63  return state->parameters().position();
64  } else
65  edm::LogError("TrackInfo") << "This rechit does not exist";
66  return LocalPoint(0, 0, 0);
67 }

References PTrajectoryStateOnDet::parameters(), LocalTrajectoryParameters::position(), and trajstates_.

◆ localTrackPositionOnMono()

const LocalPoint TrackInfo::localTrackPositionOnMono ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 69 of file TrackInfo.cc.

69  {
70  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
71  if (states != trajstates_.end())
72  return states->second.localTrackPositionOnMono(statetype);
73  else
74  edm::LogError("TrackInfo") << "This rechit does not exist";
75  return LocalPoint(0, 0, 0);
76 }

References trajstates_.

◆ localTrackPositionOnStereo()

const LocalPoint TrackInfo::localTrackPositionOnStereo ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 78 of file TrackInfo.cc.

78  {
79  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
80  if (states != trajstates_.end())
81  return states->second.localTrackPositionOnStereo(statetype);
82  else
83  edm::LogError("TrackInfo") << "This rechit does not exist";
84  return LocalPoint(0, 0, 0);
85 }

References trajstates_.

◆ seed()

const TrajectorySeed & TrackInfo::seed ( ) const

Definition at line 9 of file TrackInfo.cc.

9 { return seed_; }

References seed_.

◆ stateOnDet()

const PTrajectoryStateOnDet * TrackInfo::stateOnDet ( StateType  statetype,
TrackingRecHitRef  hit 
) const

Definition at line 22 of file TrackInfo.cc.

22  {
23  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
24  if (states != trajstates_.end())
25  return states->second.stateOnDet(statetype);
26  else
27  edm::LogError("TrackInfo") << "This rechit does not exist";
28  return nullptr;
29 }

References trajstates_.

◆ trajStateMap()

const reco::TrackInfo::TrajectoryInfo & TrackInfo::trajStateMap ( ) const

Definition at line 11 of file TrackInfo.cc.

11 { return trajstates_; }

References trajstates_.

◆ type()

const RecHitType TrackInfo::type ( TrackingRecHitRef  hit) const

Definition at line 13 of file TrackInfo.cc.

13  {
14  TrajectoryInfo::const_iterator states = trajstates_.find(hit);
15  if (states != trajstates_.end())
16  return states->second.type();
17  else
18  edm::LogError("TrackInfo") << "This rechit does not exist";
19  return Null;
20 }

References reco::Null, and trajstates_.

Member Data Documentation

◆ seed_

TrajectorySeed reco::TrackInfo::seed_
private

Definition at line 58 of file TrackInfo.h.

Referenced by seed().

◆ trajstates_

TrajectoryInfo reco::TrackInfo::trajstates_
private
align::LocalPoint
Point3DBase< Scalar, LocalTag > LocalPoint
Definition: Definitions.h:30
reco::TrackInfo::seed
const TrajectorySeed & seed() const
Definition: TrackInfo.cc:9
reco::Null
Definition: TrackInfoEnum.h:16
LocalTrajectoryParameters::position
LocalPoint position() const
Local x and y position coordinates.
Definition: LocalTrajectoryParameters.h:85
edm::LogError
Definition: MessageLogger.h:183
LocalVector
Local3DVector LocalVector
Definition: LocalVector.h:12
PTrajectoryStateOnDet::parameters
const LocalTrajectoryParameters & parameters() const
Definition: PTrajectoryStateOnDet.h:60
LocalTrajectoryParameters::momentum
LocalVector momentum() const
Momentum vector in the local frame.
Definition: LocalTrajectoryParameters.h:88
reco::TrackInfo::trajstates_
TrajectoryInfo trajstates_
Definition: TrackInfo.h:59
PTrajectoryStateOnDet
Definition: PTrajectoryStateOnDet.h:10
reco::TrackInfo::seed_
TrajectorySeed seed_
Definition: TrackInfo.h:58
hit
Definition: SiStripHitEffFromCalibTree.cc:88