]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
New constructors added to AliAlignObj and the derived classes (R.Grosso)
authorcvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 24 Mar 2006 16:20:50 +0000 (16:20 +0000)
committercvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 24 Mar 2006 16:20:50 +0000 (16:20 +0000)
STEER/AliAlignObj.cxx
STEER/AliAlignObj.h
STEER/AliAlignObjAngles.cxx
STEER/AliAlignObjAngles.h
STEER/AliAlignObjMatrix.cxx
STEER/AliAlignObjMatrix.h

index 1b198fa658db189fd36edefc8dce4894bd381dcc..7ef8c3c1c54ce14dfd759ec55e03072f7619a2cb 100644 (file)
@@ -98,6 +98,23 @@ AliAlignObj::AliAlignObj():
   InitVolPaths();
 }
 
+//_____________________________________________________________________________
+AliAlignObj::AliAlignObj(const char* volpath, UShort_t voluid) : TObject()
+{
+  // standard constructor
+  //
+  fVolPath=volpath;
+  fVolUID=voluid;
+}
+
+AliAlignObj::AliAlignObj(const char* volpath, ELayerID detId, Int_t volId) : TObject()
+{
+  // standard constructor
+  // 
+  fVolPath=volpath;
+  SetVolUID(detId,volId); 
+}
+
 //_____________________________________________________________________________
 AliAlignObj::AliAlignObj(const AliAlignObj& theAlignObj) :
   TObject(theAlignObj)
index 3746ae05ff11c2ee7f50dcd695612051873eb09a..6810d5336c7e329feb8d8eff9f2ad848a0c280df 100644 (file)
@@ -18,11 +18,6 @@ class AliAlignObj : public TObject {
 
  public:
 
-  AliAlignObj();
-  AliAlignObj(const AliAlignObj& theAlignObj);
-  AliAlignObj& operator= (const AliAlignObj& theAlignObj);
-  AliAlignObj& operator*=(const AliAlignObj& theAlignObj);
-  virtual ~AliAlignObj();
   enum ELayerID{kInvalidLayer=0,
                kFirstLayer=1,
                kSPD1=1, kSPD2=2,
@@ -35,6 +30,13 @@ class AliAlignObj : public TObject {
                kRICH=18,
                kMUON=19,
                kLastLayer=20};
+  AliAlignObj();
+  AliAlignObj(const char* volpath, UShort_t voluid);
+  AliAlignObj(const char* volpath, ELayerID detId, Int_t modId);
+  AliAlignObj(const AliAlignObj& theAlignObj);
+  AliAlignObj& operator= (const AliAlignObj& theAlignObj);
+  AliAlignObj& operator*=(const AliAlignObj& theAlignObj);
+  virtual ~AliAlignObj();
 
   //Setters
   virtual void SetTranslation(Double_t x, Double_t y, Double_t z) = 0;
@@ -59,6 +61,7 @@ class AliAlignObj : public TObject {
   virtual void GetPars(Double_t transl[], Double_t rot[]) const=0;
   virtual void GetMatrix(TGeoHMatrix& m) const=0;
 
+  Bool_t   IsSortable() const {return kTRUE;}
   Int_t         GetLevel() const;
   virtual Int_t Compare(const TObject* obj) const;
 
index 46f2d9fb85253afd32255e28a94d1bcd8c28363c..3741f65868f2e58fec88fd7cd6aa91248775e4db 100644 (file)
@@ -35,18 +35,16 @@ AliAlignObjAngles::AliAlignObjAngles() : AliAlignObj()
 }
 
 //_____________________________________________________________________________
-AliAlignObjAngles::AliAlignObjAngles(const char* volpath, UShort_t voluid, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi) : AliAlignObj()
+AliAlignObjAngles::AliAlignObjAngles(const char* volpath, UShort_t volUID, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi) : AliAlignObj(volpath,volUID)
 {
   // standard constructor with 3 translation + 3 rotation parameters
   //
-  fVolPath=volpath;
-  fVolUID=voluid;
   fTranslation[0]=x; fTranslation[1]=y; fTranslation[2]=z;
   fRotation[0]=psi; fRotation[1]=theta; fRotation[2]=phi;
 }
 
 //_____________________________________________________________________________
-AliAlignObjAngles::AliAlignObjAngles(const char* volpath, ELayerID detId, Int_t volId, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi, Bool_t global) throw (const Char_t *) : AliAlignObj()
+AliAlignObjAngles::AliAlignObjAngles(const char* volpath, ELayerID layerId, Int_t volId, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi, Bool_t global) throw (const Char_t *) : AliAlignObj(volpath,layerId,volId)
 {
   // standard constructor with 3 translation + 3 rotation parameters
   // If the user explicitly sets the global variable to kFALSE then the
@@ -54,8 +52,6 @@ AliAlignObjAngles::AliAlignObjAngles(const char* volpath, ELayerID detId, Int_t
   // This requires to have a gGeoMenager active instance, otherwise the
   // constructor will fail (no object created)
   // 
-  fVolPath=volpath;
-  SetVolUID(detId,volId);
   if(global){
     fTranslation[0]=x; fTranslation[1]=y; fTranslation[2]=z;
     fRotation[0]=psi; fRotation[1]=theta; fRotation[2]=phi;
@@ -75,6 +71,15 @@ AliAlignObjAngles::AliAlignObjAngles(const char* volpath, UShort_t voluid, TGeoM
   SetRotation(m);
 }
 
+//_____________________________________________________________________________
+AliAlignObjAngles::AliAlignObjAngles(const char* volpath, ELayerID layerId, Int_t volId, TGeoMatrix& m) : AliAlignObj(volpath,layerId,volId)
+{
+  // standard constructor with TGeoMatrix
+  //
+  SetTranslation(m);
+  SetRotation(m);
+}
+
 //_____________________________________________________________________________
 AliAlignObjAngles::AliAlignObjAngles(const AliAlignObj& theAlignObj) :
   AliAlignObj(theAlignObj)
index 48824ac52308f0b81e2608798ea38648af3ee23d..b07ec4a30b211daedae8ed31a38eb6c624e6f348 100644 (file)
@@ -22,6 +22,7 @@ class AliAlignObjAngles : public AliAlignObj{
   AliAlignObjAngles(const char* volpath, UShort_t voluid, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi);
   AliAlignObjAngles(const char* volpath, ELayerID detId, Int_t volId, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi, Bool_t global=1) throw (const Char_t *);
   AliAlignObjAngles(const char* volpath, UShort_t voluid, TGeoMatrix& m);
+  AliAlignObjAngles(const char* volpath, ELayerID layerId, Int_t volId, TGeoMatrix& m);
   AliAlignObjAngles(const AliAlignObj& theAlignObj);
   AliAlignObjAngles& operator= (const AliAlignObj& theAlignObj);
   virtual ~AliAlignObjAngles();
index 69386253ab315f520a18ff0b6242e9b10fe0cd79..7360895744686b8bf28f47b32a8ac3a702c6a7e4 100644 (file)
@@ -33,18 +33,16 @@ AliAlignObjMatrix::AliAlignObjMatrix() : AliAlignObj()
 }
 
 //_____________________________________________________________________________
-AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, UShort_t voluid, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi) : AliAlignObj()
+AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, UShort_t voluid, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi) : AliAlignObj(volpath, voluid)
 {
   // standard constructor with 3 translation + 3 rotation parameters
   //
-  fVolPath=volpath;
-  fVolUID=voluid;
   SetTranslation(x, y, z);
   SetRotation(psi, theta, phi);
 }
 
 //_____________________________________________________________________________
-AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, ELayerID detId, Int_t volId, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi, Bool_t global) throw (const Char_t *) : AliAlignObj()
+AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, ELayerID layerId, Int_t volId, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi, Bool_t global) throw (const Char_t *) : AliAlignObj(volpath,layerId,volId)
 {
   // standard constructor with 3 translation + 3 rotation parameters
   // If the user explicitly sets the global variable to kFALSE then the
@@ -52,8 +50,6 @@ AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, ELayerID detId, Int_t
   // This requires to have a gGeoMenager active instance, otherwise the
   // constructor will fail (no object created)
   // 
-  fVolPath=volpath;
-  SetVolUID(detId,volId);
   if(global){
     SetTranslation(x, y, z);
     SetRotation(psi, theta, phi);
@@ -64,12 +60,19 @@ AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, ELayerID detId, Int_t
 
 
 //_____________________________________________________________________________
-AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, UShort_t voluid, TGeoMatrix& m) : AliAlignObj()
+AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, UShort_t volUID, TGeoMatrix& m) : AliAlignObj(volpath,volUID)
+{
+  // standard constructor with TGeoMatrix
+  //
+  SetTranslation(m);
+  SetRotation(m);
+}
+
+//_____________________________________________________________________________
+AliAlignObjMatrix::AliAlignObjMatrix(const char* volpath, ELayerID layerId, Int_t volId, TGeoMatrix& m) : AliAlignObj(volpath,layerId,volId)
 {
   // standard constructor with TGeoMatrix
   //
-  fVolPath=volpath;
-  fVolUID=voluid;
   SetTranslation(m);
   SetRotation(m);
 }
index c33f2738a4f53ba2f8269ea1bd0619d9a906d237..70c50984ee9eac399836e21c499bd4a3c1ba78de 100644 (file)
@@ -18,6 +18,7 @@ class AliAlignObjMatrix : public AliAlignObj {
   AliAlignObjMatrix(const char* volpath, UShort_t voluid, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi);
   AliAlignObjMatrix(const char* volpath, ELayerID detId, Int_t volId, Double_t x, Double_t y, Double_t z, Double_t psi, Double_t theta, Double_t phi, Bool_t global=1) throw (const Char_t *);
   AliAlignObjMatrix(const char* volpath, UShort_t voluid, TGeoMatrix& m);
+  AliAlignObjMatrix(const char* volpath, ELayerID layerId, Int_t volId, TGeoMatrix& m);
   AliAlignObjMatrix(const AliAlignObj& theAlignObj);
   AliAlignObjMatrix& operator= (const AliAlignObj& theAlignObj);
   virtual ~AliAlignObjMatrix();