Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:55:07

0001 #ifndef DDL_RotationAndReflection_H
0002 #define DDL_RotationAndReflection_H
0003 
0004 #include <string>
0005 
0006 #include "DDXMLElement.h"
0007 #include "DetectorDescription/Core/interface/DDTranslation.h"
0008 
0009 class DDCompactView;
0010 class DDLElementRegistry;
0011 
0012 ///  DDLRotationAndReflection handles RotationCMSIM and ReflectionRotation elements.
0013 /** @class DDLRotationAndReflection
0014  * @author Michael Case
0015  *
0016  *  DDLRotationAndReflection.h  -  description
0017  *  -------------------
0018  *  begin: Tue Oct 30 2001
0019  *  email: case@ucdhep.ucdavis.edu
0020  *
0021  *
0022  *  This is the Rotation and Reflection element processor.
0023  *
0024  */
0025 class DDLRotationAndReflection final : public DDXMLElement {
0026 public:
0027   DDLRotationAndReflection(DDLElementRegistry* myreg);
0028 
0029   /// returns 1 = left handed rotation matrix, 0 = right-handed, -1 = not orthonormal.
0030   int isLeftHanded(const DD3Vector& x, const DD3Vector& y, const DD3Vector& z, const std::string& nmspace);
0031 
0032   void processElement(const std::string& name, const std::string& nmspace, DDCompactView& cpv) override;
0033 
0034 private:
0035   DD3Vector makeX(const std::string& nmspace);
0036   DD3Vector makeY(const std::string& nmspace);
0037   DD3Vector makeZ(const std::string& nmspace);
0038 };
0039 
0040 #endif