CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
GsfPropagatorAdapter.cc
Go to the documentation of this file.
2 
5 
6 #include <atomic>
7 
9  : Propagator(aPropagator.propagationDirection()), thePropagator(aPropagator.clone()) {}
10 
11 std::pair<TrajectoryStateOnSurface, double> GsfPropagatorAdapter::propagateWithPath(
12  const TrajectoryStateOnSurface& tsos, const Plane& plane) const {
14  return multiPropagator.propagateWithPath(tsos, plane);
15 }
16 
17 std::pair<TrajectoryStateOnSurface, double> GsfPropagatorAdapter::propagateWithPath(
18  const TrajectoryStateOnSurface& tsos, const Cylinder& cylinder) const {
20  return multiPropagator.propagateWithPath(tsos, cylinder);
21 }
22 
23 std::pair<TrajectoryStateOnSurface, double> GsfPropagatorAdapter::propagateWithPath(const FreeTrajectoryState& fts,
24  const Plane& plane) const {
26  static std::atomic<int> nWarn{0};
27  if (nWarn++ < 5)
28  edm::LogInfo("GsfPropagatorAdapter") << "GsfPropagator used from FTS = single state mode!";
29  return thePropagator->propagateWithPath(fts, plane);
30 }
31 
32 std::pair<TrajectoryStateOnSurface, double> GsfPropagatorAdapter::propagateWithPath(const FreeTrajectoryState& fts,
33  const Cylinder& cylinder) const {
35  static std::atomic<int> nWarn{0};
36  if (nWarn++ < 5)
37  edm::LogInfo("GsfPropagatorAdapter") << "GsfPropagator used from FTS = single state mode!";
38  return thePropagator->propagateWithPath(fts, cylinder);
39 }
40 
44 }
virtual void setPropagationDirection(PropagationDirection dir)
Definition: Propagator.h:130
GsfPropagatorAdapter(const Propagator &Propagator)
Constructor with explicit propagator.
std::pair< TrajectoryStateOnSurface, double > propagateWithPath(const TrajectoryStateOnSurface &, const Plane &) const override
PropagationDirection
Definition: Plane.h:16
virtual std::pair< TrajectoryStateOnSurface, double > propagateWithPath(const FreeTrajectoryState &, const Surface &) const final
Definition: Propagator.cc:10
void setPropagationDirection(PropagationDirection dir) override
DeepCopyPointerByClone< Propagator > thePropagator
Log< level::Info, false > LogInfo
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
Definition: eve_macros.cc:135
std::pair< TrajectoryStateOnSurface, double > propagateWithPath(const TrajectoryStateOnSurface &tsos, const T &surface) const