CMS 3D CMS Logo

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

#include <CosmicTrajectoryBuilder.h>

Public Member Functions

 CompareHitY_plus (const TrackerGeometry &tracker)
 
 CompareHitY_plus (const TrackerGeometry &tracker)
 
bool operator() (const TrackingRecHit *rh1, const TrackingRecHit *rh2)
 
bool operator() (const TrackingRecHit *rh1, const TrackingRecHit *rh2)
 

Private Attributes

const TrackerGeometry_tracker
 

Detailed Description

Definition at line 58 of file CosmicTrajectoryBuilder.h.

Constructor & Destructor Documentation

CompareHitY_plus::CompareHitY_plus ( const TrackerGeometry tracker)
inline

Definition at line 60 of file CosmicTrajectoryBuilder.h.

60 :_tracker(tracker){}
const TrackerGeometry & _tracker
CompareHitY_plus::CompareHitY_plus ( const TrackerGeometry tracker)
inline

Definition at line 111 of file CRackTrajectoryBuilder.h.

111 :_tracker(tracker){}
const TrackerGeometry & _tracker

Member Function Documentation

bool CompareHitY_plus::operator() ( const TrackingRecHit rh1,
const TrackingRecHit rh2 
)
inline

Definition at line 61 of file CosmicTrajectoryBuilder.h.

References _tracker, TrackingRecHit::geographicalId(), TrackerGeometry::idToDet(), TrackingRecHit::localPosition(), and GeomDet::toGlobal().

63  {
64  GlobalPoint gp1=_tracker.idToDet(rh1->geographicalId())->surface().toGlobal(rh1->localPosition());
65  GlobalPoint gp2=_tracker.idToDet(rh2->geographicalId())->surface().toGlobal(rh2->localPosition());
66  return gp1.y()>gp2.y();};
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
Definition: GeomDet.h:54
T y() const
Definition: PV3DBase.h:63
DetId geographicalId() const
virtual LocalPoint localPosition() const =0
const TrackerGeometry & _tracker
const TrackerGeomDet * idToDet(DetId) const
bool CompareHitY_plus::operator() ( const TrackingRecHit rh1,
const TrackingRecHit rh2 
)
inline

Definition at line 112 of file CRackTrajectoryBuilder.h.

References _tracker, TrackingRecHit::geographicalId(), TrackerGeometry::idToDet(), TrackingRecHit::localPosition(), GeomDet::toGlobal(), and PV3DBase< T, PVType, FrameType >::y().

114  {
115  GlobalPoint gp1=_tracker.idToDet(rh1->geographicalId())->surface().toGlobal(rh1->localPosition());
116  GlobalPoint gp2=_tracker.idToDet(rh2->geographicalId())->surface().toGlobal(rh2->localPosition());
117  return gp1.y()>gp2.y();};
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
Definition: GeomDet.h:54
T y() const
Definition: PV3DBase.h:63
DetId geographicalId() const
virtual LocalPoint localPosition() const =0
const TrackerGeometry & _tracker
const TrackerGeomDet * idToDet(DetId) const

Member Data Documentation

const TrackerGeometry & CompareHitY_plus::_tracker
private

Definition at line 66 of file CosmicTrajectoryBuilder.h.

Referenced by operator()().