]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/mapping/AliMpPadPair.cxx
Updated for modifs in AliMpFiles
[u/mrichter/AliRoot.git] / MUON / mapping / AliMpPadPair.cxx
CommitLineData
dee1d5f1 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
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 **************************************************************************/
15
5f91c9e8 16// $Id$
dee1d5f1 17// $MpId: AliMpPadPair.cxx,v 1.6 2005/08/26 15:43:36 ivana Exp $
5f91c9e8 18// Category: basic
19//
20// Class AliMpPadPair
21// ------------------
22// Wrap up for std::pair<AliMpPad, AliMpPad>
23// to avoid problems with CINT.
dbe945cc 24// Included in AliRoot: 2003/05/02
5f91c9e8 25// Authors: David Guez, Ivana Hrivnacova; IPN Orsay
26
27#include "AliMpPadPair.h"
28
29ClassImp(AliMpPadPair)
30
31
32//_____________________________________________________________________________
33AliMpPadPair::AliMpPadPair(const AliMpPad& pad1, const AliMpPad& pad2)
34 : TObject(),
f79c58a5 35 fPadFirst(pad1),
dee1d5f1 36 fPadSecond(pad2)
37{
38/// Standard constructor
5f91c9e8 39}
40
41//_____________________________________________________________________________
42AliMpPadPair::AliMpPadPair(const AliMpPadPair& right)
43 : TObject(),
f79c58a5 44 fPadFirst(right.GetFirst()),
dee1d5f1 45 fPadSecond(right.GetSecond())
46{
47/// Copy constructor
5f91c9e8 48}
49
50//_____________________________________________________________________________
51AliMpPadPair::AliMpPadPair()
52 : TObject(),
f79c58a5 53 fPadFirst(AliMpPad::Invalid()),
dee1d5f1 54 fPadSecond(AliMpPad::Invalid())
55{
56/// Default constructor
5f91c9e8 57}
58
59//_____________________________________________________________________________
dee1d5f1 60AliMpPadPair::~AliMpPadPair()
61{
62/// Destructor
5f91c9e8 63}
64
65//_____________________________________________________________________________
66Bool_t AliMpPadPair::operator == (const AliMpPadPair& right) const
67{
dee1d5f1 68/// Equality operator
69
f79c58a5 70 return (fPadFirst == right.fPadFirst && fPadSecond == right.fPadSecond);
5f91c9e8 71}
72
73//_____________________________________________________________________________
74Bool_t AliMpPadPair::operator!= (const AliMpPadPair& right) const
75{
dee1d5f1 76/// Non-equality operator
77
5f91c9e8 78 return !(*this == right);
79}
80
81//_____________________________________________________________________________
82AliMpPadPair& AliMpPadPair::operator = (const AliMpPadPair& right)
83{
dee1d5f1 84/// Assignment operator
85
86 // check assignment to self
5f91c9e8 87 if (this == &right) return *this;
88
dee1d5f1 89 // base class assignment
5f91c9e8 90 TObject::operator=(right);
91
dee1d5f1 92 // assignment operator
f79c58a5 93 fPadFirst = right.fPadFirst;
94 fPadSecond = right.fPadSecond;
5f91c9e8 95
96 return *this;
97}
98
99