ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/IPHCalignment2/TrackingTools/PatternTools/interface/TrajectoryStateClosestToPointBuilder.h
Revision: 1.1
Committed: Fri Nov 25 16:38:24 2011 UTC (13 years, 5 months ago) by econte
Content type: text/plain
Branch: MAIN
CVS Tags: TBD2011, TBD_2011, HEAD
Log Message:
new IPHC alignment

File Contents

# Content
1 #ifndef TrajectoryStateClosestToPointBuilder_H
2 #define TrajectoryStateClosestToPointBuilder_H
3
4 #include "TrackingTools/TrajectoryState/interface/TrajectoryStateOnSurface.h"
5 #include "TrackingTools/TrajectoryState/interface/TrajectoryStateClosestToPoint.h"
6
7 /**
8 * This class builds a TrajectoryStateClosestToPoint given an original
9 * TrajectoryStateOnSurface or FreeTrajectoryState. This new state is then
10 * defined at the point of closest approach to the reference point.
11 * In case the propagation was not successful, this state can be invalid.
12 */
13
14 class TrajectoryStateClosestToPointBuilder
15 {
16 public:
17 typedef TrajectoryStateOnSurface TSOS;
18 typedef FreeTrajectoryState FTS;
19
20 virtual ~TrajectoryStateClosestToPointBuilder(){}
21
22 virtual TrajectoryStateClosestToPoint operator() (const FTS& originalFTS,
23 const GlobalPoint& referencePoint) const = 0;
24
25 virtual TrajectoryStateClosestToPoint operator() (const TSOS& originalTSOS,
26 const GlobalPoint& referencePoint) const = 0;
27
28 bool positionEqual(const GlobalPoint& ptB, const GlobalPoint& ptA) const
29 {
30 if ((ptA.x() == ptB.x()) && (ptA.y() == ptB.y()) && (ptA.z() == ptB.z()))
31 return true;
32 else return false;
33 }
34
35 protected:
36
37 TrajectoryStateClosestToPoint constructTSCP(const FTS& originalFTS,
38 const GlobalPoint& referencePoint) const
39 {return TrajectoryStateClosestToPoint(originalFTS, referencePoint);}
40
41
42 };
43 #endif