CMS 3D CMS Logo

MTDNavigationSchool.h
Go to the documentation of this file.
1 #ifndef Navigation_MTDNavigationSchool_H
2 #define Navigation_MTDNavigationSchool_H
3 
23 #include <vector>
24 #include <map>
25 
26 class BTLNavigableLayer;
27 class ETLNavigableLayer;
28 class MTDEtaRange;
29 class BarrelDetLayer;
30 class ForwardDetLayer;
31 
33 
34  public:
36  MTDNavigationSchool(const MTDDetLayerGeometry *, bool enableBTL = true, bool enableETL = true);
38  ~MTDNavigationSchool() override;
40  StateType navigableLayers() override;
41  private:
43  void addBarrelLayer(const BarrelDetLayer*);
45  void addEndcapLayer(const ForwardDetLayer*);
47  void linkBarrelLayers();
49  void linkEndcapLayers(const MapE&,std::vector<ETLNavigableLayer*>&);
51  void createInverseLinks();
52  float calculateEta(const float&, const float& ) const;
53 
54  private:
55 
56  struct delete_layer
57  {
58  template <typename T>
59  void operator()(T*& p)
60  {
61  if( p)
62  {
63  delete p;
64  p = nullptr;
65  }
66  }
67  };
68 
72 
73  std::vector<BTLNavigableLayer*> theBarrelNLC;
74  std::vector<ETLNavigableLayer*> theForwardNLC;
75  std::vector<ETLNavigableLayer*> theBackwardNLC;
76 
78 
79 };
80 #endif
std::vector< BTLNavigableLayer * > theBarrelNLC
-z endcap
StateType navigableLayers() override
return navigable layers, from base class
std::map< const BarrelDetLayer *, MTDEtaRange, MTDDetLayerComp > MapB
std::vector< ETLNavigableLayer * > theBackwardNLC
void linkBarrelLayers()
link barrel layers
const MTDDetLayerGeometry * theMTDDetLayerGeometry
void linkEndcapLayers(const MapE &, std::vector< ETLNavigableLayer * > &)
link endcap layers
~MTDNavigationSchool() override
Destructor.
std::vector< ETLNavigableLayer * > theForwardNLC
MTDNavigationSchool(const MTDDetLayerGeometry *, bool enableBTL=true, bool enableETL=true)
Constructor.
void createInverseLinks()
establish inward links
std::vector< NavigableLayer * > StateType
float calculateEta(const float &, const float &) const
calculate pseudorapidity from r and z
MapE theBackwardLayers
+z endcap
void addEndcapLayer(const ForwardDetLayer *)
add endcap layer (backward and forward)
void addBarrelLayer(const BarrelDetLayer *)
add barrel layer
long double T
std::map< const ForwardDetLayer *, MTDEtaRange, MTDDetLayerComp > MapE