ATLAS Offline Software
DetectorDescription
AGDD
AGDDKernel
src
AGDDSectionStore.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
AGDDKernel/AGDDSectionStore.h
"
6
#include "
AGDDKernel/AGDDSection.h
"
7
8
#include <iostream>
9
10
AGDDSectionStore::AGDDSectionStore
():m_currentSection(0)
11
{
12
}
13
AGDDSection
*
AGDDSectionStore::GetSection
(
const
std::string&
n
)
14
{
15
if
(
m_theSections
.find(
n
) !=
m_theSections
.end())
16
return
m_theSections
[
n
];
17
else
18
{
19
std::cout<<
" Section "
<<
n
<<
" not found in store!"
<<std::endl;
20
return
0;
21
}
22
}
23
void
AGDDSectionStore::RegisterSection
(
AGDDSection
*
s
)
24
{
25
std::string
n
=
s
->Name();
26
if
(
m_theSections
.find(
n
) !=
m_theSections
.end())
27
std::cout<<
" Section "
<<
n
<<
" already in store "
<<std::endl;
28
else
29
m_theSections
[
n
]=
s
;
30
m_currentSection
=
s
;
31
}
32
void
AGDDSectionStore::PrintAllSections
()
const
33
{
34
sectionList::const_iterator
it
;
35
for
(
it
=
m_theSections
.begin();
it
!=
m_theSections
.end();++
it
)
36
{
37
(*it).second->Print();
38
}
39
}
40
41
void
AGDDSectionStore::Clean
()
42
{
43
sectionList::const_iterator
it
;
44
for
(
it
=
m_theSections
.begin();
it
!=
m_theSections
.end();++
it
)
45
{
46
delete
(*it).second;
47
}
48
m_theSections
.clear();
49
}
50
python.SystemOfUnits.s
int s
Definition:
SystemOfUnits.py:131
skel.it
it
Definition:
skel.GENtoEVGEN.py:423
AGDDSectionStore.h
AGDDSectionStore::m_theSections
sectionList m_theSections
Definition:
AGDDSectionStore.h:25
AGDDSectionStore::GetSection
AGDDSection * GetSection(const std::string &)
Definition:
AGDDSectionStore.cxx:13
beamspotman.n
n
Definition:
beamspotman.py:731
AGDDSectionStore::Clean
void Clean()
Definition:
AGDDSectionStore.cxx:41
AGDDSectionStore::PrintAllSections
void PrintAllSections() const
Definition:
AGDDSectionStore.cxx:32
AGDDSection
Definition:
AGDDSection.h:17
AGDDSectionStore::RegisterSection
void RegisterSection(AGDDSection *)
Definition:
AGDDSectionStore.cxx:23
AGDDSectionStore::AGDDSectionStore
AGDDSectionStore()
Definition:
AGDDSectionStore.cxx:10
AGDDSection.h
AGDDSectionStore::m_currentSection
AGDDSection * m_currentSection
Definition:
AGDDSectionStore.h:24
Generated on Fri Jul 5 2024 21:10:04 for ATLAS Offline Software by
1.8.18