reverting to version 1.12 due to new library dependencies
[u/mrichter/AliRoot.git] / HLT / src / AliHLTTrackArray.h
CommitLineData
4aa41877 1// @(#) $Id$
2
3#ifndef ALIL3TRACKARRAY_H
4#define ALIL3TRACKARRAY_H
5
6#include "AliHLTRootTypes.h"
7
8class AliHLTConfMapTrack;
9class AliHLTTrack;
10class AliHLTTrackSegmentData;
11
12class AliHLTTrackArray {
13
14 private:
15
16 Char_t fTrackType; //track type
17 Int_t fSize; //size of arra
18 Bool_t *fIsPresent;//!
19 Int_t fNAbsent; //ntracks absent
20
21 AliHLTTrack **fTrack;//!
22 Int_t fNTracks; //ntracks in
23
24 UInt_t WriteConfMapTracks(AliHLTTrackSegmentData* tr);
25 void DeleteArray();
26
27 public:
28 AliHLTTrackArray();
29 AliHLTTrackArray(Int_t ntrack);
30 AliHLTTrackArray(char* tracktype,Int_t ntrack);
31 AliHLTTrackArray(char* tracktype);
32 virtual ~AliHLTTrackArray();
33 Int_t GetTrackType(){return fTrackType;}
34 Int_t GetSize() const {return fSize;}
35 Bool_t SetSize(Int_t newsize=2000);
36
37 Int_t GetNPresent() const {return (fNTracks- fNAbsent);}
38 Int_t GetNTracks() const {return fNTracks;}
39 AliHLTTrack *NextTrack();
40 AliHLTTrack *GetCheckedTrack(Int_t t){if(fIsPresent[t]) return fTrack[t]; return 0;}
41 AliHLTTrack *GetTrack(Int_t t){return fTrack[t];}
42
43 void Remove(Int_t track);
44 void RemoveLast() {fNTracks--;}
45 void Compress();
46 void Reset();
47 void QSort();
48 void QSort( AliHLTTrack **a, Int_t first, Int_t last);
49 Int_t TrackCompare(AliHLTTrack *a, AliHLTTrack *b) const;
50
51 void FillTracks(Int_t ntracks, AliHLTTrackSegmentData* tr,Int_t slice); //Fill tracks and transform
52 void FillTracks(Int_t ntracks, AliHLTTrackSegmentData* tr); //Fill tracks
53 UInt_t WriteTracks(AliHLTTrackSegmentData* tr); //Write tracks
54 UInt_t WriteTracks(UInt_t & ntracks,AliHLTTrackSegmentData* tr); //Write tracks
55 UInt_t GetOutSize();
56 UInt_t GetOutCount(){return (UInt_t) GetNPresent();}
57 void AddTracks(AliHLTTrackArray *newtrack,Bool_t remove_old=kTRUE,Int_t slice=-1);//add all Tracks to this
58 void AddLast(AliHLTTrack *track);
59
60 ClassDef(AliHLTTrackArray,1) //Track array class
61};
62
63typedef AliHLTTrackArray AliL3TrackArray; // for backward compatibility
64
65#endif