Coding Violations
authoralibrary <alibrary@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 11 Apr 2005 08:03:05 +0000 (08:03 +0000)
committeralibrary <alibrary@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 11 Apr 2005 08:03:05 +0000 (08:03 +0000)
STEER/AliRun.cxx
STEER/TTreeStream.cxx
STEER/TTreeStream.h
TPC/AliTPCtrackerMI.cxx
TPC/AliTPCtrackerMI.h

index 086bf46..3f5d5ce 100644 (file)
@@ -64,7 +64,7 @@
 #include "AliRun.h"
 #include "AliStack.h"
 #ifdef __APPLE__
-#include "AliTPCTrackHitsInterfaces.h"
+//#include "AliTPCTrackHitsInterfaces.h"
 #endif
 
 AliRun *gAlice;
@@ -176,9 +176,9 @@ AliRun::AliRun(const char *name, const char *title):
 #ifdef __APPLE__
   // Terrible hack to avoid problem with the initialisation of 
   // static and globals on Mac OS X 
-  AliClassAliTrackHitsInfo p1=galiclass____AliClassAliTrackHitsInfo;
-  AliClassAliTrackHitsParam p2=galiclass____AliTrackHitsParam;
-  AliClassAliHitInfo p3=galiclass____AliHitInfo;
+  //  AliClassAliTrackHitsInfo p1=galiclass____AliClassAliTrackHitsInfo;
+  // AliClassAliTrackHitsParam p2=galiclass____AliTrackHitsParam;
+  //AliClassAliHitInfo p3=galiclass____AliHitInfo;
 #endif
 
 }
index 7904ef5..a6cdeba 100644 (file)
@@ -1,7 +1,24 @@
-#include "TObjArray.h"
+//
+//  marian.ivanov@cern.ch
+//
+//  ------------------------------------------------------------------------------------------------
+//  TTreeStream
+//  Standard stream (cout) like input for the tree
+//  Run and see TTreeStreamer::Test() - to see TTreeStreamer functionality
+//  ------------------------------------------------------------------------------------------------  
+//
+//  -------------------------------------------------------------------------------------------------
+//  TTreeSRedirector
+//  Redirect file to  different TTreeStreams  
+//  Run and see   TTreeSRedirector::Test() as an example of TTreeSRedirectorer functionality 
+// 
+
+/* $Id$ */
+
+#include "TBrowser.h"
 #include "TFile.h"
+#include "TObjArray.h"
 #include "TTree.h"
-#include "TBrowser.h"
 #include "TTreeStream.h"
 
 
@@ -9,21 +26,6 @@ ClassImp(TTreeDataElement)
 ClassImp(TTreeStream)
 ClassImp(TTreeSRedirector)
 
-/*
-  marian.ivanov@cern.ch
-  //
-  ------------------------------------------------------------------------------------------------
-  TTreeStream
-  Standard stream (cout) like input for the tree
-  Run and see TTreeStreamer::Test() - to see TTreeStreamer functionality
-  ------------------------------------------------------------------------------------------------  
-  //
-  -------------------------------------------------------------------------------------------------
-  TTreeSRedirector
-  Redirect file to  different TTreeStreams  
-  Run and see   TTreeSRedirector::Test() as an example of TTreeSRedirectorer functionality 
-  // 
-*/
 
 
 void TTreeStream::Test()
@@ -263,10 +265,16 @@ TTreeStream::TTreeStream(const char *treename):
   fNextNameCounter(),
   fStatus(0)
 {
+  //
+  // Standard ctor
+  //
 }
 
 TTreeStream::~TTreeStream()
 {
+  //
+  // Class dtor
+  //
   fElements->Delete();
   fBranches->Clear();
   delete fElements;
@@ -276,11 +284,16 @@ TTreeStream::~TTreeStream()
 void TTreeStream::Close()
 {
   //
+  // Flush data to disk and close
+  //
   fTree->Write();
 }
 
 Int_t TTreeStream::CheckIn(Char_t type, void *pointer)
 {
+  //
+  // Insert object of given type
+  //
   if (!fElements) fElements = new TObjArray(1000);
   TTreeDataElement* element = (TTreeDataElement*)fElements->At(fCurrentIndex);
   if (!element) {
@@ -316,6 +329,7 @@ Int_t TTreeStream::CheckIn(Char_t type, void *pointer)
 
 Int_t TTreeStream::CheckIn(TObject *o){
   //
+  // Insert TObject
   //
   if (!o) return 0;
   if (!fElements) fElements = new TObjArray(1000);
@@ -353,6 +367,7 @@ Int_t TTreeStream::CheckIn(TObject *o){
 
 void TTreeStream::BuildTree(){
   //
+  // Build the Tree
   //
   if (fTree->GetEntries()>0) return;
   fTree = new TTree(GetName(),GetName());
@@ -390,6 +405,7 @@ void TTreeStream::BuildTree(){
 
 void TTreeStream::Fill(){
   //
+  // Fill the tree
   //
   if (fTree) { 
     Int_t entries=fElements->GetEntriesFast();
@@ -408,7 +424,11 @@ void TTreeStream::Fill(){
   }
 }
 
-TTreeStream & TTreeStream::Endl(){
+TTreeStream & TTreeStream::Endl()
+{
+  //
+  // Perform pseudo endl operation
+  //
   if (fTree->GetNbranches()==0) BuildTree();
   Fill();
   fStatus =0;
@@ -420,9 +440,8 @@ TTreeStream & TTreeStream::Endl(){
 TTreeStream  &TTreeStream::operator<<(Char_t *name)
 {
   //
+  // Endl 
   //
-  //
-  //Endl 
   if (name[0]=='\n'){
     return Endl();
   }
index c09d48a..f09a275 100644 (file)
@@ -83,7 +83,7 @@ public:
 class TTreeSRedirector: public TObject { 
 public:
   TTreeSRedirector(const char *fname);
-  ~TTreeSRedirector();
+  virtual ~TTreeSRedirector();
   void Close();
   static void Test();
   virtual   TTreeStream  &operator<<(Int_t id);
index 207004f..f35ec12 100644 (file)
@@ -30,8 +30,6 @@
 
 /* $Id$ */
 
-
-
 #include "Riostream.h"
 #include <TClonesArray.h>
 #include <TFile.h>
 
 #include "AliComplexCluster.h"
 #include "AliESD.h"
+#include "AliESDkink.h"
 #include "AliHelix.h"
 #include "AliRunLoader.h"
 #include "AliTPCClustersRow.h"
 #include "AliTPCParam.h"
+#include "AliTPCReconstructor.h"
 #include "AliTPCclusterMI.h"
 #include "AliTPCpolyTrack.h"
 #include "AliTPCreco.h" 
 #include "AliTPCtrackerMI.h"
 #include "TStopwatch.h"
-
-#include "AliTPCReconstructor.h"
-#include "AliESDkink.h"
 #include "TTreeStream.h"
 //
 
index 31882a6..211e941 100644 (file)
@@ -13,8 +13,6 @@
 //   Origin: 
 //-------------------------------------------------------
 
-#include <TError.h>
-
 #include "AliTracker.h"
 #include "AliTPCtrack.h"
 #include "AliComplexCluster.h"
@@ -71,8 +69,7 @@ class AliTPCseed : public AliTPCtrack {
      //
      //
  private:
-     //     AliTPCseed & operator = (const AliTPCseed &)
-     //  {::Fatal("= operator","Not Implemented\n");return *this;}
+     AliTPCseed & operator = (const AliTPCseed &);
      AliESDtrack * fEsd; //!
      AliTPCclusterMI*   fClusterPointer[160];  //! array of cluster pointers  - 
      TClonesArray * fPoints;              // array with points along the track
@@ -117,8 +114,8 @@ public:
     fInnerSec=fOuterSec=0; fSeeds=0; 
   }
   AliTPCtrackerMI(const AliTPCParam *par); 
-   AliTPCtrackerMI(const AliTPCtrackerMI& r);           //dummy copy constructor
-   AliTPCtrackerMI &operator=(const AliTPCtrackerMI& r);//dummy assignment operator
+  AliTPCtrackerMI(const AliTPCtrackerMI& r);           //dummy copy constructor
+  AliTPCtrackerMI &operator=(const AliTPCtrackerMI& r);//dummy assignment operator
   virtual ~AliTPCtrackerMI();
   //
   void SetIteration(Int_t iteration){fIteration = iteration;}
@@ -192,8 +189,6 @@ public:
      friend class AliTPCtrackerMI::AliTPCSector;
    public:
      AliTPCRow();
-     AliTPCRow(const AliTPCRow& /*r*/){;}           //dummy copy constructor
-     AliTPCRow &operator=(const AliTPCRow& /*r*/){return *this;} //dummy assignment operator
      ~AliTPCRow();
      void InsertCluster(const AliTPCclusterMI *c, UInt_t index);
      void ResetClusters();
@@ -209,6 +204,8 @@ public:
      void SetX(Double_t x) {fX=x;}
      Double_t GetX() const {return fX;}
 private:  
+     AliTPCRow & operator=(const AliTPCRow & );
+     AliTPCRow(const AliTPCRow& /*r*/);           //dummy copy constructor
      Float_t fDeadZone;  // the width of the dead zone
      AliTPCclusterMI *fClusters1; //array with clusters 1
      Int_t fN1;  //number of clusters on left side
@@ -230,33 +227,33 @@ private:
    public:
      AliTPCSector() { fN=0; fRow = 0; }
     ~AliTPCSector() { delete[] fRow; }
-    AliTPCSector(const AliTPCSector &/*s*/){;}           //dummy copy contructor 
-    AliTPCSector& operator=(const AliTPCSector &/*s*/){return *this;}//dummy assignment operator
-     AliTPCRow& operator[](Int_t i) const { return *(fRow+i); }
-     Int_t GetNRows() const { return fN; }
-     void Setup(const AliTPCParam *par, Int_t flag);
-     Double_t GetX(Int_t l) const {return fRow[l].GetX();}
-     Double_t GetMaxY(Int_t l) const {
-         return GetX(l)*TMath::Tan(0.5*GetAlpha());
-     } 
-     Double_t GetAlpha() const {return fAlpha;}
-     Double_t GetAlphaShift() const {return fAlphaShift;}     
-     //Int_t GetFirst(){return fFirstRow;}
-     Int_t GetRowNumber(Double_t  x) const;
-     Double_t GetPadPitchWidth()  const {return fPadPitchWidth;}
-     Double_t GetPadPitchLength() const {return fPadPitchLength;}
-     Double_t GetPadPitchLength(Float_t x) const {return (x<200) ? fPadPitchLength:f2PadPitchLength ;}
-
+    AliTPCRow& operator[](Int_t i) const { return *(fRow+i); }
+    Int_t GetNRows() const { return fN; }
+    void Setup(const AliTPCParam *par, Int_t flag);
+    Double_t GetX(Int_t l) const {return fRow[l].GetX();}
+    Double_t GetMaxY(Int_t l) const {
+      return GetX(l)*TMath::Tan(0.5*GetAlpha());
+    } 
+    Double_t GetAlpha() const {return fAlpha;}
+    Double_t GetAlphaShift() const {return fAlphaShift;}     
+    //Int_t GetFirst(){return fFirstRow;}
+    Int_t GetRowNumber(Double_t  x) const;
+    Double_t GetPadPitchWidth()  const {return fPadPitchWidth;}
+    Double_t GetPadPitchLength() const {return fPadPitchLength;}
+    Double_t GetPadPitchLength(Float_t x) const {return (x<200) ? fPadPitchLength:f2PadPitchLength ;}
+    
    private:
-     Int_t fN;                        //number of pad rows 
-     //Int_t fFirstRow;                 //offset
-     AliTPCRow *fRow;                    //array of pad rows
-     Double_t fAlpha;                    //opening angle
-     Double_t fAlphaShift;               //shift angle;
-     Double_t fPadPitchWidth;            //pad pitch width
-     Double_t fPadPitchLength;           //pad pitch length
-     Double_t f1PadPitchLength;           //pad pitch length
-     Double_t f2PadPitchLength;           //pad pitch length
+    AliTPCSector & operator=(const AliTPCSector & );
+    AliTPCSector(const AliTPCSector &/*s*/);           //dummy copy contructor 
+    Int_t fN;                        //number of pad rows 
+    //Int_t fFirstRow;                 //offset
+    AliTPCRow *fRow;                    //array of pad rows
+    Double_t fAlpha;                    //opening angle
+    Double_t fAlphaShift;               //shift angle;
+    Double_t fPadPitchWidth;            //pad pitch width
+    Double_t fPadPitchLength;           //pad pitch length
+    Double_t f1PadPitchLength;           //pad pitch length
+    Double_t f2PadPitchLength;           //pad pitch length
     
    };