]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - MUON/AliMUONPointWithRef.h
Fix coverity defect
[u/mrichter/AliRoot.git] / MUON / AliMUONPointWithRef.h
... / ...
CommitLineData
1#ifndef ALIMUONPOINTWITHREF_H
2#define ALIMUONPOINTWITHREF_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5* See cxx source for full Copyright notice */
6
7// $Id$
8
9/// \ingroup geometry
10/// \class AliMUONPointWithRef
11/// \brief A TVector2 with an integer ref, and a specific Compare
12///
13// author Laurent Aphecetche
14
15#ifndef ROOT_TObject
16# include "TObject.h"
17#endif
18
19class AliMUONPointWithRef : public TObject
20{
21public:
22 AliMUONPointWithRef(Double_t x, Double_t y, Int_t ref);
23 AliMUONPointWithRef();
24 /// Destructor
25 virtual ~AliMUONPointWithRef() {}
26
27 /// We are sortable
28 virtual Bool_t IsSortable() const { return kTRUE; }
29
30 virtual Int_t Compare(const TObject* obj) const;
31
32 /// Return x value
33 Double_t X() const { return fX; }
34
35 /// Return y value
36 Double_t Y() const { return fY; }
37
38 /// Return the index of the original point in some array
39 Int_t Ref() const { return fRef; }
40
41 void Print(Option_t* opt="") const;
42
43private:
44 Double_t fX; ///< x value
45 Double_t fY; ///< y value
46 Int_t fRef; ///< index of the original point in some array
47
48 ClassDef(AliMUONPointWithRef,1) // A point with an external integer reference
49};
50
51#endif