1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
16 //-------------------------------------------------------------------------
17 // Implementation of the AliESDfriendTrack class
18 // This class keeps complementary to the AliESDtrack information
19 // Origin: Iouri Belikov, CERN, Jouri.Belikov@cern.ch
20 //-------------------------------------------------------------------------
21 #include "AliTrackPointArray.h"
22 #include "AliESDfriendTrack.h"
25 ClassImp(AliESDfriendTrack)
27 AliESDfriendTrack::AliESDfriendTrack(): TObject(), f1P(0), fPoints(0) {
29 // Default constructor
32 for (i=0; i<AliESDtrack::kMaxITScluster; i++) fITSindex[i]=-2;
33 for (i=0; i<AliESDtrack::kMaxTPCcluster; i++) fTPCindex[i]=-2;
34 for (i=0; i<AliESDtrack::kMaxTRDcluster; i++) fTRDindex[i]=-2;
37 AliESDfriendTrack::AliESDfriendTrack(const AliESDfriendTrack &t):
46 for (i=0; i<AliESDtrack::kMaxITScluster; i++) fITSindex[i]=t.fITSindex[i];
47 for (i=0; i<AliESDtrack::kMaxTPCcluster; i++) fTPCindex[i]=t.fTPCindex[i];
48 for (i=0; i<AliESDtrack::kMaxTRDcluster; i++) fTRDindex[i]=t.fTRDindex[i];
49 if (t.fPoints) fPoints=new AliTrackPointArray(*t.fPoints);
52 AliESDfriendTrack::AliESDfriendTrack(const AliESDtrack &t):
58 // Extracts the complementary info from the ESD track
60 t.GetITSclusters(fITSindex);
61 t.GetTPCclusters(fTPCindex);
62 t.GetTRDclusters(fTRDindex);
63 const AliTrackPointArray *points=t.GetTrackPointArray();
64 if (points) fPoints=new AliTrackPointArray(*points);
67 AliESDfriendTrack::~AliESDfriendTrack() {delete fPoints;}