]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSgeomSPD.cxx
Fixed compiler warnings with regards to copy construtors and unused variabls
[u/mrichter/AliRoot.git] / ITS / AliITSgeomSPD.cxx
index ab42545007d96cc2784a4961367591f804d16f0d..8ce1cfe2aa2445b84f939be4e58c7aa6e2d84fdc 100644 (file)
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
-/*
-$Log$
-Revision 1.16  2002/10/14 14:57:00  hristov
-Merging the VirtualMC branch to the main development branch (HEAD)
-
-Revision 1.14.6.1  2002/06/10 17:51:15  hristov
-Merged with v3-08-02
-
-Revision 1.15  2002/05/19 18:17:03  hristov
-Changes needed by ICC/IFC compiler (Intel)
-
-Revision 1.14  2001/10/19 21:32:35  nilsen
-Minor changes to remove compliation warning on gcc 2.92.2 compiler, and
-cleanded up a little bit of code.
-
-Revision 1.13  2001/10/12 22:07:20  nilsen
-A patch for C++ io manipulation functions so that they will work both
-with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
-other platforms.
-
-Revision 1.12  2001/08/24 21:06:37  nilsen
-Added more documentation, fixed up some coding violations, and some
-forward declorations.
-
-Revision 1.11  2001/05/16 08:17:49  hristov
-Bug fixed in the StepManager to account for the difference in the geometry 
-tree for the ITS pixels. This fixes both the funny distribution of pixel 
-coordinates and the missing hits/digits/points in many sectors of the ITS 
-pixel barrel. Also included is a patch to properly get and use the detector 
-dimensions through out the ITS code. (B.Nilsen)
-
-Revision 1.10  2001/04/26 22:44:34  nilsen
-Bug fix.
-
-Revision 1.9  2001/02/09 00:00:57  nilsen
-Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
-bugs in iostream based streamers used to read and write .det files. Fixed
-some detector sizes. Fixed bugs in some default-special constructors.
-
-Revision 1.8  2001/02/03 00:00:30  nilsen
-New version of AliITSgeom and related files. Now uses automatic streamers,
-set up for new formatted .det file which includes detector information.
-Additional smaller modifications are still to come.
-
-*/
+/* $Id$ */
 
 ////////////////////////////////////////////////////////////////////////
 // This class is for the Silicon Pixel Detector, SPD, specific geometry.
@@ -125,7 +81,7 @@ void AliITSgeomSPD::ReSetBins(Float_t dy,Int_t nx,Float_t *bx,
     return;
 }
 //______________________________________________________________________
-AliITSgeomSPD::AliITSgeomSPD(AliITSgeomSPD &source){
+AliITSgeomSPD::AliITSgeomSPD(AliITSgeomSPD &source) : TObject(source){
     // Copy constructor
 
     *this = source; // just use the = operator for now.
@@ -202,7 +158,7 @@ void AliITSgeomSPD::Print(ostream *os) const {
     Int_t fmt;
 #endif
 #else
-#if defined __ICC
+#if defined __ICC || defined __ECC
     ios::fmtflags fmt;
 #else
     Int_t fmt;
@@ -263,65 +219,6 @@ istream &operator>>(istream &is,AliITSgeomSPD &r){
 }
 //=====================================================================
 
-/*
-$Log$
-Revision 1.16  2002/10/14 14:57:00  hristov
-Merging the VirtualMC branch to the main development branch (HEAD)
-
-Revision 1.14.6.1  2002/06/10 17:51:15  hristov
-Merged with v3-08-02
-
-Revision 1.15  2002/05/19 18:17:03  hristov
-Changes needed by ICC/IFC compiler (Intel)
-
-Revision 1.14  2001/10/19 21:32:35  nilsen
-Minor changes to remove compliation warning on gcc 2.92.2 compiler, and
-cleanded up a little bit of code.
-
-Revision 1.13  2001/10/12 22:07:20  nilsen
-A patch for C++ io manipulation functions so that they will work both
-with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
-other platforms.
-
-Revision 1.12  2001/08/24 21:06:37  nilsen
-Added more documentation, fixed up some coding violations, and some
-forward declorations.
-
-Revision 1.11  2001/05/16 08:17:49  hristov
-Bug fixed in the StepManager to account for the difference in the geometry tree for the ITS pixels. This fixes both the funny distribution of pixel coordinates and the missing hits/digits/points in many sectors of the ITS pixel barrel. Also included is a patch to properly get and use the detector dimensions through out the ITS code. (B.Nilsen)
-
-Revision 1.10  2001/04/26 22:44:34  nilsen
-Bug fix.
-
-Revision 1.9  2001/02/09 00:00:57  nilsen
-Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
-bugs in iostream based streamers used to read and write .det files. Fixed
-some detector sizes. Fixed bugs in some default-special constructors.
-
-Revision 1.8  2001/02/03 00:00:30  nilsen
-New version of AliITSgeom and related files. Now uses automatic streamers,
-set up for new formatted .det file which includes detector information.
-Additional smaller modifications are still to come.
-
-Revision 1.7  2000/10/02 16:32:35  barbera
-Forward declaration added
-
-Revision 1.1.2.8  2000/10/02 15:52:05  barbera
-Forward declaration added
-
-Revision 1.6  2000/07/10 16:07:18  fca
-Release version of ITS code
-
-Revision 1.4  2000/06/10 20:34:37  nilsen
-Fixed compilation warning with HP unix.
-
-Revision 1.3  2000/06/10 10:43:04  nilsen
-Fixed bug in copy and operator =.
-
-*/
-
-//#include "AliITSgeomSPD300.h"
-
 ClassImp(AliITSgeomSPD300)
 
 AliITSgeomSPD300::AliITSgeomSPD300() : AliITSgeomSPD(){
@@ -385,65 +282,6 @@ istream &operator>>(istream &is,AliITSgeomSPD300 &r){
     return is;
 }
 //=====================================================================
-/*
-$Log$
-Revision 1.16  2002/10/14 14:57:00  hristov
-Merging the VirtualMC branch to the main development branch (HEAD)
-
-Revision 1.14.6.1  2002/06/10 17:51:15  hristov
-Merged with v3-08-02
-
-Revision 1.15  2002/05/19 18:17:03  hristov
-Changes needed by ICC/IFC compiler (Intel)
-
-Revision 1.14  2001/10/19 21:32:35  nilsen
-Minor changes to remove compliation warning on gcc 2.92.2 compiler, and
-cleanded up a little bit of code.
-
-Revision 1.13  2001/10/12 22:07:20  nilsen
-A patch for C++ io manipulation functions so that they will work both
-with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
-other platforms.
-
-Revision 1.12  2001/08/24 21:06:37  nilsen
-Added more documentation, fixed up some coding violations, and some
-forward declorations.
-
-Revision 1.11  2001/05/16 08:17:49  hristov
-Bug fixed in the StepManager to account for the difference in the geometry tree for the ITS pixels. This fixes both the funny distribution of pixel coordinates and the missing hits/digits/points in many sectors of the ITS pixel barrel. Also included is a patch to properly get and use the detector dimensions through out the ITS code. (B.Nilsen)
-
-Revision 1.10  2001/04/26 22:44:34  nilsen
-Bug fix.
-
-Revision 1.9  2001/02/09 00:00:57  nilsen
-Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
-bugs in iostream based streamers used to read and write .det files. Fixed
-some detector sizes. Fixed bugs in some default-special constructors.
-
-Revision 1.8  2001/02/03 00:00:30  nilsen
-New version of AliITSgeom and related files. Now uses automatic streamers,
-set up for new formatted .det file which includes detector information.
-Additional smaller modifications are still to come.
-
-Revision 1.7  2000/10/02 16:32:35  barbera
-Forward declaration added
-
-Revision 1.1.2.8  2000/10/02 15:52:05  barbera
-Forward declaration added
-
-Revision 1.6  2000/07/10 16:07:18  fca
-Release version of ITS code
-
-Revision 1.4  2000/06/10 20:34:22  nilsen
-Fixed compilation warning with HP unix.
-
-Revision 1.3  2000/06/10 10:42:49  nilsen
-Fixed bug in copy and operator =.
-
-
-*/
-
-//#include "AliITSgeomSPD425Short.h"
 
 ClassImp(AliITSgeomSPD425Short)
 
@@ -505,6 +343,11 @@ AliITSgeomSPD425Short::AliITSgeomSPD425Short(Int_t npar,Float_t *par) :
     for(i=0;i<knbinz;i++) dz += binSizeZ[i];
     dz *= 0.5;
 
+    if(npar<3){
+       Error("AliITSgeomSPD425Short",
+              "npar=%d<3 array par must be at least [3] or larger",npar);
+       return;
+    } // end if
     SetShape("ActiveSPD","Active volume of SPD","SPD SI DET",
             par[0],par[1],par[2]);
     if(TMath::Abs(dx-kdx)>1.0E-4 || TMath::Abs(dz-kdz)>1.0E-4) 
@@ -537,66 +380,6 @@ istream &operator>>(istream &is,AliITSgeomSPD425Short &r){
 }
 //======================================================================
 
-/*
-$Log$
-Revision 1.16  2002/10/14 14:57:00  hristov
-Merging the VirtualMC branch to the main development branch (HEAD)
-
-Revision 1.14.6.1  2002/06/10 17:51:15  hristov
-Merged with v3-08-02
-
-Revision 1.15  2002/05/19 18:17:03  hristov
-Changes needed by ICC/IFC compiler (Intel)
-
-Revision 1.14  2001/10/19 21:32:35  nilsen
-Minor changes to remove compliation warning on gcc 2.92.2 compiler, and
-cleanded up a little bit of code.
-
-Revision 1.13  2001/10/12 22:07:20  nilsen
-A patch for C++ io manipulation functions so that they will work both
-with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
-other platforms.
-
-Revision 1.12  2001/08/24 21:06:37  nilsen
-Added more documentation, fixed up some coding violations, and some
-forward declorations.
-
-Revision 1.11  2001/05/16 08:17:49  hristov
-Bug fixed in the StepManager to account for the difference in the geometry tree for the ITS pixels. This fixes both the funny distribution of pixel coordinates and the missing hits/digits/points in many sectors of the ITS pixel barrel. Also included is a patch to properly get and use the detector dimensions through out the ITS code. (B.Nilsen)
-
-Revision 1.10  2001/04/26 22:44:34  nilsen
-Bug fix.
-
-Revision 1.9  2001/02/09 00:00:57  nilsen
-Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
-bugs in iostream based streamers used to read and write .det files. Fixed
-some detector sizes. Fixed bugs in some default-special constructors.
-
-Revision 1.8  2001/02/03 00:00:30  nilsen
-New version of AliITSgeom and related files. Now uses automatic streamers,
-set up for new formatted .det file which includes detector information.
-Additional smaller modifications are still to come.
-
-Revision 1.7  2000/10/02 16:32:35  barbera
-Forward declaration added
-
-Revision 1.1.2.8  2000/10/02 15:52:05  barbera
-Forward declaration added
-
-Revision 1.6  2000/07/10 16:07:18  fca
-Release version of ITS code
-
-Revision 1.4  2000/06/10 20:34:22  nilsen
-Fixed compilation warning with HP unix.
-
-Revision 1.3  2000/06/10 10:42:49  nilsen
-Fixed bug in copy and operator =.
-
-
-*/
-
-//#include "AliITSgeomSPD425Long.h"
-
 ClassImp(AliITSgeomSPD425Long)
 
 AliITSgeomSPD425Long::AliITSgeomSPD425Long(){