32#ifndef G4MODELCOLOURMAP_HH
33#define G4MODELCOLOURMAP_HH
56 void Print(std::ostream& ostr)
const;
61 std::map<T, G4Colour> fMap;
84 ed <<
"G4Colour with key "<<colour<<
" does not exist ";
86 (
"G4ColourMap::Set(Charge charge, const G4String& colour)",
93 Set(quantity, myColour);
100 fMap[quantity] = colour;
111 typename std::map<T, G4Colour>::const_iterator iter = fMap.find(quantity);
113 if (iter != fMap.end()) {
114 colour = iter->second;
125 typename std::map<T, G4Colour>::const_iterator iter = fMap.begin();
127 while (iter != fMap.end()) {
128 ostr<< iter->first <<
" : "<< iter->second <<
G4endl;
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
std::ostringstream G4ExceptionDescription
static G4bool GetColour(const G4String &key, G4Colour &result)
G4Colour & operator[](const T &quantity)
bool GetColour(const T &, G4Colour &) const
void Print(std::ostream &ostr) const
const std::map< T, G4Colour > & GetBasicMap() const
void Set(const T &, const G4String &)
virtual ~G4ModelColourMap()
void Set(const T &, const G4Colour &)