]>
Commit | Line | Data |
---|---|---|
ab2f6604 | 1 | // -*- C++ -*- |
2 | // | |
3 | // 1998/11/25 | |
4 | // --------------------------------------------------------------------------- | |
5 | // | |
6 | // AliGConfig Class | |
7 | // | |
8 | // This file is part of the ALICE Geometry Database . | |
9 | // | |
10 | // Author: Joana E. Santo/David Collados/Antonino Bajeli | |
11 | // | |
12 | // --------------------------------------------------------------------------- | |
13 | ||
14 | #include <iostream.h> | |
15 | #include "AliGConfig.h" | |
16 | ||
17 | ClassImp(AliGConfig) | |
18 | ||
19 | //------------------------------------------------------------------------- | |
20 | ||
21 | AliGConfig::AliGConfig( Text_t* name, Text_t* title, TStringLong formula, Text_t* detail, const Text_t* shapetype, const Text_t* shapename, const Text_t* materialname, Int_t beg, Int_t end ) : TNamed(name, title) | |
22 | { | |
23 | /* Constructor */ | |
24 | fBeg.Set(beg,0000); // Time validity of node version | |
25 | fDetail = detail; // Level of detail | |
26 | fEnd.Set(end,0000); // Time validity of node version | |
27 | ||
28 | fFormula = formula; //Formula describing the node structure below | |
29 | fMaterialName = materialname; | |
30 | fShapeName = shapename; | |
31 | fShapeType = shapetype; | |
32 | } | |
33 | ||
34 | //------------------------------------------------------------------------- | |
35 | ||
36 | AliGConfig::AliGConfig( AliGConfig* Config ) | |
37 | { | |
38 | if( Config ) { | |
39 | /* Copy Constructor */ | |
40 | fBeg.Copy(Config->fBeg); // Time validity of node version | |
41 | fDetail = Config->fDetail.Copy(); // Level of detail | |
42 | fEnd.Copy(Config->fEnd); // Time validity of node version | |
43 | ||
44 | fFormula = Config->fFormula.Copy(); | |
45 | fMaterialName = Config->fMaterialName.Copy(); | |
46 | fName = Config->fName.Copy(); | |
47 | fShapeName = Config->fShapeName.Copy(); | |
48 | fShapeType = Config->fShapeType.Copy(); | |
49 | fTitle = Config->fTitle.Copy(); | |
50 | } | |
51 | else { | |
52 | /* Default Constructor */ | |
53 | fBeg.Set(); // Time validity of node version | |
54 | fDetail = ""; // Level of detail | |
55 | fEnd.Set(); // Time validity of node version | |
56 | fFormula = ""; // Formula describing the node structure below | |
57 | fMaterialName = ""; | |
58 | fName = ""; | |
59 | fShapeName = ""; | |
60 | fShapeType = ""; | |
61 | fTitle = ""; | |
62 | } | |
63 | } | |
64 | ||
65 | //------------------------------------------------------------------------- | |
66 | ||
67 | AliGConfig::~AliGConfig() | |
68 | { | |
69 | /* Destructor */ | |
70 | } | |
71 | ||
72 | //------------------------------------------------------------------------- | |
73 | ||
74 | AliGConfig* AliGConfig::operator=( AliGConfig* Config ) | |
75 | { | |
76 | /* Operator = */ | |
77 | if( this == Config) return this; // special case. | |
78 | ||
79 | Config->fBeg.Copy(this->fBeg); // Time validity of node version | |
80 | fDetail = Config->fDetail; // Level of detail | |
81 | Config->fEnd.Copy(this->fEnd); // Time validity of node version | |
82 | ||
83 | fFormula = Config->fFormula.Copy(); | |
84 | fMaterialName = Config->fMaterialName.Copy(); | |
85 | fName = Config->fName.Copy(); | |
86 | fShapeName = Config->fShapeName.Copy(); | |
87 | fShapeType = Config->fShapeType.Copy(); | |
88 | fTitle = Config->fTitle.Copy(); | |
89 | ||
90 | return this; | |
91 | } | |
92 | ||
93 | //------------------------------------------------------------------------- | |
94 |