ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
DetectorDescription
IdDict
IdDict
IdDictAltRegions.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef IDDICT_IdDictAltRegions_H
6
#define IDDICT_IdDictAltRegions_H
7
8
#include "
IdDict/IdDictDictEntry.h
"
9
10
#include <string>
11
#include <string_view>
12
#include <map>
13
#include <memory>
14
15
class
Range
;
16
class
IdDictMgr
;
17
class
IdDictDictionary
;
18
class
IdDictRegion
;
19
20
21
22
class
IdDictAltRegions
:
public
IdDictDictEntry
{
23
public
:
24
// ==================================
25
//** @name Constructor/destructor
26
// @{
27
28
IdDictAltRegions
();
29
virtual
~IdDictAltRegions
();
30
31
33
// ==================================
34
//** @name Simple accessors.
35
// @{
36
38
virtual
std::string
group_name
()
const override
;
39
41
IdDictRegion
*
selected_region
();
42
43
45
// ==================================
46
//** @name Methods used to initialize the object.
47
// @{
48
50
void
add_region
(std::unique_ptr<IdDictRegion> region);
51
53
void
select_region
(
const
std::string& name);
54
55
56
virtual
void
set_index
(
size_t
index
)
override
;
57
virtual
Range
build_range
()
const override
;
58
virtual
void
resolve_references
(
IdDictMgr
& idd,
59
IdDictDictionary
& dictionary)
override
;
60
virtual
void
generate_implementation
(
const
IdDictMgr
& idd,
61
IdDictDictionary
& dictionary,
62
std::string_view tag =
""
)
override
;
63
virtual
void
reset_implementation
()
override
;
64
virtual
bool
verify
()
const override
;
65
virtual
void
clear
()
override
;
66
67
69
70
71
private
:
72
using
map_type
= std::map<std::string, std::unique_ptr<IdDictRegion>, std::less<> >;
73
using
map_iterator
= map_type::iterator;
74
using
value_type
= map_type::value_type;
75
76
map_type
m_regions
;
77
IdDictRegion
*
m_selected_region
{};
78
};
79
80
82
inline
83
IdDictRegion
*
IdDictAltRegions::selected_region
()
84
{
85
return
m_selected_region
;
86
}
87
88
89
#endif
IdDictDictEntry.h
IdDictAltRegions::select_region
void select_region(const std::string &name)
Select the named region.
Definition
IdDictAltRegions.cxx:98
IdDictAltRegions::m_selected_region
IdDictRegion * m_selected_region
Definition
IdDictAltRegions.h:77
IdDictAltRegions::add_region
void add_region(std::unique_ptr< IdDictRegion > region)
Add a new region, with key given by the tag.
Definition
IdDictAltRegions.cxx:91
IdDictAltRegions::clear
virtual void clear() override
Definition
IdDictAltRegions.cxx:77
IdDictAltRegions::generate_implementation
virtual void generate_implementation(const IdDictMgr &idd, IdDictDictionary &dictionary, std::string_view tag="") override
Definition
IdDictAltRegions.cxx:47
IdDictAltRegions::set_index
virtual void set_index(size_t index) override
Definition
IdDictAltRegions.cxx:30
IdDictAltRegions::resolve_references
virtual void resolve_references(IdDictMgr &idd, IdDictDictionary &dictionary) override
Definition
IdDictAltRegions.cxx:37
IdDictAltRegions::map_iterator
map_type::iterator map_iterator
Definition
IdDictAltRegions.h:73
IdDictAltRegions::m_regions
map_type m_regions
Definition
IdDictAltRegions.h:76
IdDictAltRegions::build_range
virtual Range build_range() const override
Definition
IdDictAltRegions.cxx:82
IdDictAltRegions::~IdDictAltRegions
virtual ~IdDictAltRegions()
IdDictAltRegions::IdDictAltRegions
IdDictAltRegions()
Definition
IdDictAltRegions.cxx:15
IdDictAltRegions::selected_region
IdDictRegion * selected_region()
Currently selected region.
Definition
IdDictAltRegions.h:83
IdDictAltRegions::reset_implementation
virtual void reset_implementation() override
Definition
IdDictAltRegions.cxx:67
IdDictAltRegions::value_type
map_type::value_type value_type
Definition
IdDictAltRegions.h:74
IdDictAltRegions::map_type
std::map< std::string, std::unique_ptr< IdDictRegion >, std::less<> > map_type
Definition
IdDictAltRegions.h:72
IdDictAltRegions::verify
virtual bool verify() const override
Definition
IdDictAltRegions.cxx:72
IdDictAltRegions::group_name
virtual std::string group_name() const override
Group name for this region.
Definition
IdDictAltRegions.cxx:23
IdDictDictEntry::IdDictDictEntry
IdDictDictEntry()
Definition
IdDictDictEntry.cxx:7
IdDictDictionary
Definition
IdDictDictionary.h:33
IdDictMgr
Definition
IdDictMgr.h:17
IdDictRegion
Definition
IdDictRegion.h:22
Range
A Range describes the possible ranges for the field values of an ExpandedIdentifier.
Definition
DetectorDescription/Identifier/Identifier/Range.h:31
index
Definition
index.py:1
Generated on
for ATLAS Offline Software by
1.17.0