ATLAS Offline Software
AGDDColorStore.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 #include "AGDDModel/AGDDColor.h"
7 #include <iostream>
8 
10 {
11 }
12 
14 {
15  std::string name=v->GetName();
16  (*this)[name]=v;
17 }
18 
19 bool AGDDColorStore::Exist(const std::string& n) const
20 {
21  return ((*this).find(n) != (*this).end());
22 }
23 
25 {
26  if ((*this).find(name) != (*this).end())
27  return (*this)[name];
28  else
29  {
30  std::cout << " Color "<<name<<" not found: returning 0"<<std::endl;
31  return nullptr;
32  }
33 }
34 
AGDDColorStore::Register
void Register(AGDDColor *)
Definition: AGDDColorStore.cxx:13
AGDDColorStore::GetColor
AGDDColor * GetColor(const std::string &)
Definition: AGDDColorStore.cxx:24
AGDDColorStore::AGDDColorStore
AGDDColorStore()
Definition: AGDDColorStore.cxx:9
beamspotman.n
n
Definition: beamspotman.py:731
AGDDColor
Definition: AGDDColor.h:12
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
AGDDColor.h
python.PyAthena.v
v
Definition: PyAthena.py:157
AGDDColorStore.h
AGDDColorStore::Exist
bool Exist(const std::string &) const
Definition: AGDDColorStore.cxx:19