prevent running if CDB snapshot setting failed
[u/mrichter/AliRoot.git] / STEER / STEER / AliCTPInputTimeParams.cxx
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
16
17 #include <Riostream.h>
18
19 #include "TObject.h"
20 #include "AliLog.h"   
21 #include "AliCTPInputTimeParams.h"
22
23 using std::endl;
24 using std::cout;
25 ClassImp(AliCTPInputTimeParams)
26
27 //_____________________________________________________________________________
28 AliCTPInputTimeParams::AliCTPInputTimeParams():
29   fName(0),
30   fLevel(0),        
31   fDelay(0),        
32   fEdge(0),
33   fDeltaMin(0),
34   fDeltaMax(0)
35 {
36  // Default constructor
37 }     
38
39 //_____________________________________________________________________________
40 AliCTPInputTimeParams::AliCTPInputTimeParams( TString& name, UInt_t& level, UInt_t delay, TString edge, UInt_t deltamin, UInt_t deltamax ):
41   fName(name),        
42   fLevel(level),        
43   fDelay( delay),
44   fEdge(edge),
45   fDeltaMin(deltamin),
46   fDeltaMax(deltamax)
47 {
48 }
49 //_____________________________________________________________________________
50 AliCTPInputTimeParams::AliCTPInputTimeParams(const AliCTPInputTimeParams &ctptime):
51  TObject(ctptime),
52  fName(ctptime.fName),
53  fLevel(ctptime.fLevel),
54  fDelay(ctptime.fDelay),
55  fEdge(ctptime.fEdge),
56  fDeltaMin(ctptime.fDeltaMin),
57  fDeltaMax(ctptime.fDeltaMax)
58
59 {
60  // copy constructor
61 }
62 //_____________________________________________________________________________
63 AliCTPInputTimeParams& AliCTPInputTimeParams::operator=(const AliCTPInputTimeParams &ctptime)
64 {
65  //assignment operator
66  if(this==&ctptime) return *this;
67  ((TObject *)this)->operator=(ctptime);
68  fName=ctptime.fName;
69  fLevel=ctptime.fLevel;
70  fDelay=ctptime.fDelay;
71  fEdge=ctptime.fEdge;
72  fDeltaMin=ctptime.fDeltaMin;
73  fDeltaMax=ctptime.fDeltaMax;
74  return *this;
75 }
76 //_____________________________________________________________________________
77 void AliCTPInputTimeParams::SetCTPInputTimeParams( TString name, UInt_t level, UInt_t delay, TString edge, UInt_t deltamin, UInt_t deltamax )
78 {
79   fName = name;        
80   fLevel = level;        
81   fDelay = delay;
82   fEdge = edge;
83   fDeltaMin = deltamin;
84   fDeltaMax = deltamax;
85 }
86
87 //_____________________________________________________________________________
88 void AliCTPInputTimeParams::Print( const Option_t* ) const
89 {
90    // Print
91   cout << "  CTP Input Time Params " << endl;
92   cout << "  Input Name: " << fName << endl;
93   cout << "  Level:      " << fLevel << endl;
94   cout << "  Delay:      " << fDelay << endl;
95   cout << "  Edge:       " << fEdge << endl;
96   cout << "  DeltaMin:   " << fDeltaMin << endl;
97   cout << "  DeltaMax:   " << fDeltaMax << endl;
98 }