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 **************************************************************************/
17 // $MpId: AliMpPadPair.cxx,v 1.7 2006/05/24 13:58:29 ivana Exp $
20 //-----------------------------------------------------------------------------
23 // Wrap up for std::pair<AliMpPad, AliMpPad>
24 // to avoid problems with CINT.
25 // Included in AliRoot: 2003/05/02
26 // Authors: David Guez, Ivana Hrivnacova; IPN Orsay
27 //-----------------------------------------------------------------------------
29 #include "AliMpPadPair.h"
32 ClassImp(AliMpPadPair)
35 //_____________________________________________________________________________
36 AliMpPadPair::AliMpPadPair(const AliMpPad& pad1, const AliMpPad& pad2)
41 /// Standard constructor
44 //_____________________________________________________________________________
45 AliMpPadPair::AliMpPadPair(const AliMpPadPair& right)
47 fPadFirst(right.GetFirst()),
48 fPadSecond(right.GetSecond())
53 //_____________________________________________________________________________
54 AliMpPadPair::AliMpPadPair()
56 fPadFirst(AliMpPad::Invalid()),
57 fPadSecond(AliMpPad::Invalid())
59 /// Default constructor
62 //_____________________________________________________________________________
63 AliMpPadPair::~AliMpPadPair()
68 //_____________________________________________________________________________
69 Bool_t AliMpPadPair::operator == (const AliMpPadPair& right) const
73 return (fPadFirst == right.fPadFirst && fPadSecond == right.fPadSecond);
76 //_____________________________________________________________________________
77 Bool_t AliMpPadPair::operator!= (const AliMpPadPair& right) const
79 /// Non-equality operator
81 return !(*this == right);
84 //_____________________________________________________________________________
85 AliMpPadPair& AliMpPadPair::operator = (const AliMpPadPair& right)
87 /// Assignment operator
89 // check assignment to self
90 if (this == &right) return *this;
92 // base class assignment
93 TObject::operator=(right);
95 // assignment operator
96 fPadFirst = right.fPadFirst;
97 fPadSecond = right.fPadSecond;