Methods concerning collision geometry added.
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 7 Jan 2003 14:09:06 +0000 (14:09 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 7 Jan 2003 14:09:06 +0000 (14:09 +0000)
STEER/AliGenerator.cxx
STEER/AliGenerator.h

index 95b93f209e8e9b2dd26c7fddec44ff7d06aac2d3..a5443bca1c23393b031db7bc304af3b7c9995f2a 100644 (file)
@@ -15,6 +15,9 @@
 
 /*
 $Log$
+Revision 1.21  2002/11/21 16:13:03  alibrary
+Removing AliMCProcess and AliMC
+
 Revision 1.20  2002/10/29 14:26:49  hristov
 Code clean-up (F.Carminati)
 
@@ -93,6 +96,7 @@ Introduction of the Copyright and cvs Log
 
 #include "AliConfig.h"
 #include "AliGenerator.h"
+#include "AliCollisionGeometry.h"
 #include "AliRun.h"
 #include "AliStack.h"
 
@@ -126,7 +130,8 @@ AliGenerator::AliGenerator():
   fOsigma(3),
   fVertex(3),
   fEventVertex(0),
-  fStack(0)
+  fStack(0),
+  fCollisionGeometry(0)
 {
   //
   // Default constructor
@@ -181,7 +186,8 @@ AliGenerator::AliGenerator(Int_t npart):
   fOsigma(3),
   fVertex(3),
   fEventVertex(0),
-  fStack(0)
+  fStack(0),
+  fCollisionGeometry(0)
 {
   //
   // Standard constructor
index 2707a45bc8dfc309b81d9ea8e3025f0e4b658409..e85d18e9d66969120d4212a74e9c942cfbe4fdde 100644 (file)
@@ -19,6 +19,7 @@
 #include "AliRndm.h"
 class TGenerator;
 class AliStack;
+class AliCollisionGeometry;
 
 
 typedef enum { kNoSmear, kPerEvent, kPerTrack } VertexSmear_t;
@@ -72,10 +73,14 @@ class AliGenerator : public TNamed, public AliRndm
        {ox=fOrigin.At(0);oy=fOrigin.At(1);oz=fOrigin.At(2);}
     virtual void GetOrigin(TLorentzVector &o) const
        {o[0]=fOrigin.At(0);o[1]=fOrigin.At(1);o[2]=fOrigin.At(2);o[3]=0;}
-
+  // Stack 
     void SetStack (AliStack *stack) {fStack = stack;}
     AliStack* GetStack(){return fStack;}
-// Comminication with stack
+  // Collision Geometry
+    virtual Bool_t ProvidesCollisionGeometry() {return kFALSE;}
+    virtual Bool_t NeedsCollisionGeometry()    {return kFALSE;}    
+    virtual AliCollisionGeometry* CollisionGeometry() {return fCollisionGeometry;}
+    virtual void SetCollisionGeometry(AliCollisionGeometry* geom) {fCollisionGeometry = geom;}
  protected:
     virtual  void  SetTrack(Int_t done, Int_t parent, Int_t pdg,
                                Float_t *pmom, Float_t *vpos, Float_t *polar,
@@ -118,6 +123,7 @@ class AliGenerator : public TNamed, public AliRndm
     TArrayF     fEventVertex;   //!The current event vertex
 
     AliStack*   fStack;      //! Local pointer to stack
+    AliCollisionGeometry* fCollisionGeometry; //!Collision geometry
     /*************************************************************************/
     enum {kThetaRange    = BIT(14),
          kVertexRange   = BIT(15),
@@ -126,7 +132,7 @@ class AliGenerator : public TNamed, public AliRndm
          kYRange        = BIT(18),
          kMomentumRange = BIT(19)     
     };
-    ClassDef(AliGenerator,2) // Base class for event generators
+    ClassDef(AliGenerator,3) // Base class for event generators
 };
 
 #endif