PandaRoot
PndTrackID.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 //-----------------------------------------------------------
14 // File and Version Information:
15 // $Id$
16 //
17 // Description:
18 // Implementation of class PndTrackID
19 //
20 // Environment:
21 // Software developed for the PANDA Detector at FAIR.
22 //
23 // Author List:
24 // 01/07/09 - Stefano Spataro (Torino)
25 //
26 //
27 //-----------------------------------------------------------
28 
29 #ifndef PNDTRACKID_HH
30 #define PNDTRACKID_HH
31 
32 // Root Class Headers ----------------
33 #include "TObject.h"
34 #include "TArrayI.h"
35 
36 class PndTrackID : public TObject {
37  public:
38  // Constructors/Destructors ---------
39  PndTrackID();
40  PndTrackID(const Int_t id, const TArrayI track, const TArrayI mult);
41  ~PndTrackID();
42 
43  // Accessors -----------------------
44  Int_t GetTrackID() const { return fTrackID; }
45  Short_t GetNCorrTrackId(void) const { return fCorrTrackIds.GetSize(); }
46  Int_t GetCorrTrackID(Int_t i = 0) const { return fCorrTrackIds[i]; }
47  Int_t GetMultTrackID(Int_t i = 0) const { return fMultTrackIds[i]; }
48 
49  // void Sort(); // not implemented
50 
51  // Modifiers -----------------------
52  void SetTrackID(Int_t id) { fTrackID = id; }
53  void SetCorrTrackID(const TArrayI track, const TArrayI mult)
54  {
55  fCorrTrackIds = track;
56  fMultTrackIds = mult;
57  }
58 
59  void Reset();
60 
61  void Print();
62 
63  private:
64  // Private Data Members ------------
65  Int_t fTrackID; // Index of PndTrack TCA
66  TArrayI fCorrTrackIds; // A unique list of correlated Ids
67  TArrayI fMultTrackIds; // A unique list of multiplicity of correlated Ids
68 
69  public:
70  ClassDef(PndTrackID, 1)
71 };
72 
73 #endif
74 
75 //--------------------------------------------------------------
76 // $Log$
77 //--------------------------------------------------------------
void Print()
Int_t GetMultTrackID(Int_t i=0) const
Definition: PndTrackID.h:47
unsigned int i
Definition: P4_F32vec4.h:33
Short_t GetNCorrTrackId(void) const
Definition: PndTrackID.h:45
void SetCorrTrackID(const TArrayI track, const TArrayI mult)
Definition: PndTrackID.h:53
Int_t GetTrackID() const
Definition: PndTrackID.h:44
void SetTrackID(Int_t id)
Definition: PndTrackID.h:52
void Reset()
Int_t GetCorrTrackID(Int_t i=0) const
Definition: PndTrackID.h:46