00001 #ifndef FinalTreeBuilder_H 00002 #define FinalTreeBuilder_H 00003 00004 #include "RecoVertex/KinematicFitPrimitives/interface/RefCountedKinematicTree.h" 00005 #include "RecoVertex/KinematicFitPrimitives/interface/KinematicVertexFactory.h" 00006 #include "RecoVertex/KinematicFitPrimitives/interface/VirtualKinematicParticleFactory.h" 00007 #include "RecoVertex/VertexPrimitives/interface/CachingVertex.h" 00008 #include "RecoVertex/KinematicFitPrimitives/interface/KinematicRefittedTrackState.h" 00009 #include "RecoVertex/KinematicFitPrimitives/interface/Matrices.h" 00010 00016 class FinalTreeBuilder{ 00017 00018 public: 00019 FinalTreeBuilder(); 00020 00021 ~FinalTreeBuilder(); 00022 00023 RefCountedKinematicTree buildTree(const CachingVertex<6>& vtx, 00024 std::vector<RefCountedKinematicParticle> input) const; 00025 00026 private: 00027 00028 typedef ReferenceCountingPointer<VertexTrack<6> > RefCountedVertexTrack; 00029 typedef ReferenceCountingPointer<LinearizedTrackState<6> > RefCountedLinearizedTrackState; 00030 typedef ReferenceCountingPointer<RefittedTrackState<6> > RefCountedRefittedTrackState; 00031 00032 //internal calculation and helper methods 00033 AlgebraicMatrix momentumPart(const CachingVertex<6>& vtx, 00034 const AlgebraicVector7& par)const; 00035 00036 KinematicVertexFactory * kvFactory; 00037 VirtualKinematicParticleFactory * pFactory; 00038 }; 00039 00040 #endif