]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - RALICE/AliEvent.cxx
01-feb-2003 NvE Memberfunction Info() renamed to Data() in various classes in order to
[u/mrichter/AliRoot.git] / RALICE / AliEvent.cxx
index 8335b9241ba3b89e56499c24af04f77e9677768b..4ef2b3cab35274290b3383fa09fe239e4548441f 100644 (file)
@@ -13,7 +13,7 @@
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
-// $Id: AliEvent.cxx,v 1.6 2002/04/26 11:23:37 nick Exp $
+// $Id: AliEvent.cxx,v 1.9 2003/01/09 16:06:35 nick Exp $
 
 ///////////////////////////////////////////////////////////////////////////
 // Class AliEvent
 //        jx=v2.GetJet(2);
 //        evt.AddJet(jx,0); 
 // 
-//        evt.Info("sph");
+//        evt.Data("sph");
 //        v1.ListAll();
 //        v2.List("cyl");
 //
 //        Float_t loc[3];
 //        evt.GetPosition(loc,"sph");
 //        AliPosition r=v1.GetPosition();
-//        r.Info(); 
+//        r.Data(); 
 //        Int_t nt=v2.GetNtracks();
 //        AliTrack* tv=v2.GetTrack(1); // Access track number 1 of Vertex v2
 //
 // Note : All quantities are in GeV, GeV/c or GeV/c**2
 //
 //--- Author: Nick van Eijndhoven 27-may-2001 UU-SAP Utrecht
-//- Modified: NvE $Date: 2002/04/26 11:23:37 $ UU-SAP Utrecht
+//- Modified: NvE $Date: 2003/01/09 16:06:35 $ UU-SAP Utrecht
 ///////////////////////////////////////////////////////////////////////////
 
 #include "AliEvent.h"
@@ -206,9 +206,11 @@ AliEvent::AliEvent()
  fAproj=0;
  fZproj=0;
  fPnucProj=0;
+ fIdProj=0;
  fAtarg=0;
  fZtarg=0;
  fPnucTarg=0;
+ fIdTarg=0;
  fNcals=0;
  fCalorimeters=0;
  fCalCopy=0;
@@ -218,16 +220,17 @@ AliEvent::AliEvent(Int_t n): AliVertex(n)
 {
 // Create an event to hold initially a maximum of n tracks
 // All variables initialised to default values
- cout << "AliEvent init with n = " << n << endl;
  fDaytime.Set();
  fRun=0;
  fEvent=0;
  fAproj=0;
  fZproj=0;
  fPnucProj=0;
+ fIdProj=0;
  fAtarg=0;
  fZtarg=0;
  fPnucTarg=0;
+ fIdTarg=0;
  fNcals=0;
  fCalorimeters=0;
  fCalCopy=0;
@@ -255,9 +258,11 @@ void AliEvent::Reset()
  fAproj=0;
  fZproj=0;
  fPnucProj=0;
+ fIdProj=0;
  fAtarg=0;
  fZtarg=0;
  fPnucTarg=0;
+ fIdTarg=0;
 
  fNcals=0;
  if (fCalorimeters)
@@ -334,12 +339,14 @@ Int_t AliEvent::GetEventNumber()
  return fEvent;
 }
 ///////////////////////////////////////////////////////////////////////////
-void AliEvent::SetProjectile(Int_t a,Int_t z,Double_t pnuc)
+void AliEvent::SetProjectile(Int_t a,Int_t z,Double_t pnuc,Int_t id)
 {
-// Set the projectile A, Z and momentum value per nucleon.
+// Set the projectile A, Z, momentum per nucleon and user defined particle ID.
+// By default the particle ID is set to zero.
  fAproj=a;
  fZproj=z;
  fPnucProj=pnuc;
+ fIdProj=id;
 }
 ///////////////////////////////////////////////////////////////////////////
 Int_t AliEvent::GetProjectileA()
@@ -360,12 +367,20 @@ Double_t AliEvent::GetProjectilePnuc()
  return fPnucProj;
 }
 ///////////////////////////////////////////////////////////////////////////
-void AliEvent::SetTarget(Int_t a,Int_t z,Double_t pnuc)
+Int_t AliEvent::GetProjectileId()
 {
-// Set the target A, Z and momentum value per nucleon.
+// Provide the user defined particle ID of the projectile.
+ return fIdProj;
+}
+///////////////////////////////////////////////////////////////////////////
+void AliEvent::SetTarget(Int_t a,Int_t z,Double_t pnuc,Int_t id)
+{
+// Set the target A, Z, momentum per nucleon and user defined particle ID.
+// By default the particle ID is set to zero.
  fAtarg=a;
  fZtarg=z;
  fPnucTarg=pnuc;
+ fIdTarg=id;
 }
 ///////////////////////////////////////////////////////////////////////////
 Int_t AliEvent::GetTargetA()
@@ -386,7 +401,13 @@ Double_t AliEvent::GetTargetPnuc()
  return fPnucTarg;
 }
 ///////////////////////////////////////////////////////////////////////////
-void AliEvent::HeaderInfo()
+Int_t AliEvent::GetTargetId()
+{
+// Provide the user defined particle ID of the target.
+ return fIdTarg;
+}
+///////////////////////////////////////////////////////////////////////////
+void AliEvent::HeaderData()
 {
 // Provide event header information
  Int_t date=fDaytime.GetDate();
@@ -402,7 +423,7 @@ void AliEvent::HeaderInfo()
  char* c[12]={"jan","feb","mar","apr","may","jun",
               "jul","aug","sep","oct","nov","dec"};
 
- cout << " *AliEvent::Info* Run : " << fRun << " Event : " << fEvent;
+ cout << " *AliEvent::Data* Run : " << fRun << " Event : " << fEvent;
  cout.fill('0');
  cout << " Date : " << setw(2) << day << "-" << c[month-1] << "-" << year
       << " Time : " << setw(2) << hh << ":" << setw(2) << mm << ":" << setw(2) << ss;
@@ -410,11 +431,11 @@ void AliEvent::HeaderInfo()
  cout << " Ncalorimeters : " << fNcals << endl;
 }
 ///////////////////////////////////////////////////////////////////////////
-void AliEvent::Info(TString f)
+void AliEvent::Data(TString f)
 {
 // Provide event information within the coordinate frame f
- HeaderInfo();
- AliVertex::Info(f);
+ HeaderData();
+ AliVertex::Data(f);
 } 
 ///////////////////////////////////////////////////////////////////////////
 Int_t AliEvent::GetNcalorimeters()