Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:44:33

0001 #ifndef Alignment_CommonAlignment_AlignableExtras_H
0002 #define Alignment_CommonAlignment_AlignableExtras_H
0003 
0004 /** \class AlignableExtras
0005  *
0006  * A container for additional/extra alignables
0007  *
0008  *  Original author: Andreas Mussgiller, August 2010
0009  *
0010  *  $Date: 2009/02/28 21:04:59 $
0011  *  $Revision: 1.3 $
0012  *  (last update by $Author: mussgill $)
0013  */
0014 
0015 #include "Alignment/CommonAlignment/interface/Alignable.h"
0016 #include "Alignment/CommonAlignment/interface/AlignableMap.h"
0017 #include "Alignment/CommonAlignment/interface/Utilities.h"
0018 
0019 class AlignableExtras {
0020 public:
0021   typedef align::Alignables Alignables;
0022 
0023   /// Constructor (builds all alignables)
0024   explicit AlignableExtras();
0025 
0026   /// Return alignables determined by name
0027   Alignables& subStructures(const std::string& subStructName) { return alignableLists_.find(subStructName); }
0028 
0029   /// Return beam spot alignable as a vector with one element
0030   Alignables& beamSpot() { return this->subStructures("BeamSpot"); }
0031 
0032   const Alignables& components() const { return components_; }
0033 
0034   /// Return alignments, sorted by DetId
0035   Alignments* alignments() const;
0036 
0037   /// Return alignment errors, sorted by DetId
0038   AlignmentErrorsExtended* alignmentErrors() const;
0039 
0040   void dump(void) const;
0041 
0042   /// Initialize the alignable beam spot with the given parameters
0043   void initializeBeamSpot(double x, double y, double z, double dxdz, double dydz);
0044 
0045   /// Initialize the alignable beam spot with the given parameters
0046   void resetBeamSpot();
0047 
0048 private:
0049   AlignableMap alignableLists_;  //< kind of map of lists of alignables
0050   Alignables components_;        //< list of alignables
0051 };
0052 
0053 #endif  //AlignableExtras_H