ATLAS Offline Software
Loading...
Searching...
No Matches
AGDDVolumeStore.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
8#include <iostream>
9
13
15{
16 std::string name=v->GetName();
17 (*this)[name]=v;
18}
19
20bool AGDDVolumeStore::Exist(std::string n)
21{
22 return ((*this).find(n) != (*this).end());
23}
24
26{
27 if ((*this).find(name) != (*this).end())
28 return (*this)[name];
29 else
30 {
31 std::cout << " Volume "<<name<<" not found: returning 0"<<std::endl;
32 return 0;
33 }
34}
35
37{
38 for (auto volumeIt : *this)
39 {
40 if (!(volumeIt.second->IsSensitiveVolume()))
41 delete (volumeIt.second);
42 }
43 this->clear();
44}
bool Exist(std::string)
void RegisterVolume(AGDDVolume *)
AGDDVolume * GetVolume(std::string)