2 /**************************************************************************
3 * This file is property of and copyright by the ALICE HLT Project *
4 * ALICE Experiment at CERN, All rights reserved. *
6 * Primary Authors: Artur Szostak <artursz@iafrica.com> *
7 * for The ALICE HLT Project. *
9 * Permission to use, copy, modify and distribute this software and its *
10 * documentation strictly for non-commercial purposes is hereby granted *
11 * without fee, provided that the above copyright notice appears in all *
12 * copies and that both the copyright notice and this permission notice *
13 * appear in the supporting documentation. The authors make no claims *
14 * about the suitability of this software for any purpose. It is *
15 * provided "as is" without express or implied warranty. *
16 **************************************************************************/
18 /// @file AliHLTTriggerMenuSymbol.cxx
19 /// @author Artur Szostak <artursz@iafrica.com>
21 /// @brief Implementation of the AliHLTTriggerMenuSymbol class.
23 /// The AliHLTTriggerMenuSymbol contains information about a symbol used in the
24 /// global HLT trigger menu.
26 #include "AliHLTTriggerMenuSymbol.h"
27 #include "Riostream.h"
29 ClassImp(AliHLTTriggerMenuSymbol)
32 AliHLTTriggerMenuSymbol::AliHLTTriggerMenuSymbol() :
36 fBlockType(kAliHLTAnyDataType),
42 // Default constructor.
46 AliHLTTriggerMenuSymbol::~AliHLTTriggerMenuSymbol()
48 // Default destructor.
52 void AliHLTTriggerMenuSymbol::Print(Option_t* option) const
54 // Prints the contents of the trigger menu item.
57 if (opt.Contains("compact"))
59 cout << "{fRealName = \"" << fRealName.Data()
60 << "\", fType = \"" << fType.Data()
61 << "\", fBlockType = \"";
62 fBlockType.Print("noendl");
63 cout << "\", fClass = \"" << fClass
64 << "\", fAssignExpr = \"" << fAssignExpr
65 << "\", fDefaultValue = \"" << fDefaultValue
70 cout << " Name = " << Name() << endl;
71 cout << " RealName = " << RealName() << endl;
72 cout << " Data type = " << Type() << endl;
73 cout << " Block type = "; fBlockType.Print();
74 cout << " Class type = " << ObjectClass() << endl;
75 cout << " Assignment expression = " << AssignExpression() << endl;
76 cout << "Default value expression = " << DefaultValue() << endl;
81 const char* AliHLTTriggerMenuSymbol::RealName() const
83 // return the real name of the symbol which can contain '-'
85 // backward compatibility with old versions of the class
86 if (fRealName.IsNull()) return fName;
90 void AliHLTTriggerMenuSymbol::Name(const char* value)
92 // sets the name and real name of the symbol
93 // replaces '-' and '.' in the real name with '_' in order to comply with
97 fName.ReplaceAll("-", "_");
98 fName.ReplaceAll(".", "_");