CMS 3D CMS Logo

CMSSW_4_4_3_patch1/src/DetectorDescription/Core/interface/DDTransform.h

Go to the documentation of this file.
00001 #ifndef DDTransform_h
00002 #define DDTransform_h
00003 
00005 #include "DetectorDescription/Core/interface/DDBase.h"
00006 #include "DetectorDescription/Core/interface/DDName.h"
00007 #include "DetectorDescription/Base/interface/DDRotationMatrix.h"
00008 //#include "DetectorDescription/Base/interface/DDTranslation.h"
00009 
00010 class DDRotation;
00011 
00012 std::ostream & operator<<(std::ostream &, const DDRotation &);
00014 
00018 DDRotation DDrot(const DDName & name,
00019                  DDRotationMatrix * rot);
00020 
00022 
00024 DDRotation DDrot(const DDName & name,
00025                          double thetaX, double phiX,
00026                          double thetaY, double phiY,
00027                          double thetaZ, double phiZ);
00028      
00029 
00031 
00034 DDRotation DDrotReflect(const DDName & name,
00035                          double thetaX, double phiX,
00036                          double thetaY, double phiY,
00037                          double thetaZ, double phiZ);
00038                          
00039 
00040 DDRotation DDrotReflect(const DDName & name,
00041                         DDRotationMatrix * rot);
00042 
00043 
00045 
00049 DDRotation DDanonymousRot(DDRotationMatrix * rot);
00050 
00052 
00055 DDRotationMatrix * DDcreateRotationMatrix(double thetaX, double phiX,
00056                          double thetaY, double phiY,
00057                          double thetaZ, double phiZ);
00058 
00060 
00066 class DDRotation : public DDBase<DDName,DDRotationMatrix*>
00067 {
00068   friend std::ostream & operator<<(std::ostream &, const DDRotation &);
00069   friend DDRotation DDrot(const DDName &, DDRotationMatrix *);
00070   friend DDRotation DDrotReflect(const DDName&,double,double,double,double,double,double);
00071   friend DDRotation DDanonymousRot(DDRotationMatrix*);
00072 public:
00074   DDRotation();
00075 
00077 
00086   DDRotation(const DDName & name);
00087 
00088   DDRotation(const DDName &, DDRotationMatrix*);
00090   const DDRotationMatrix * rotation() const  { return &(rep()); }   
00091   
00092   DDRotationMatrix * rotation()   { return &(rep()); }
00093   
00094   DDRotationMatrix * matrix() { return rotation(); }
00095   //DDRotationMatrix* unit();
00096   
00097 /*   static void clear(); */
00098 private:  
00099   DDRotation(DDRotationMatrix*); 
00100 };
00101 
00102 
00103                          
00104 #endif