FWCore
Utilities
interface
ESIndices.h
Go to the documentation of this file.
1
#ifndef FWCore_Utilities_ESIndices_h
2
#define FWCore_Utilities_ESIndices_h
3
// -*- C++ -*-
4
//
5
// Package: Framework
6
// Class : ESIndices
7
//
18
//
19
// Author: Chris Jones
20
// Created: Sat Apr 6 14:47:35 EST 2019
21
//
22
23
// system include files
24
#include <ostream>
25
26
// user include files
27
28
namespace
edm
{
29
class
ESProxyIndex
{
30
public
:
31
using
Value_t
=
int
;
32
constexpr
ESProxyIndex
() noexcept =
default
;
33
constexpr explicit
ESProxyIndex
(
Value_t
iValue) noexcept :
index_
{iValue} {}
34
constexpr
ESProxyIndex
(
ESProxyIndex
const
&) noexcept =
default
;
35
constexpr
ESProxyIndex
(
ESProxyIndex
&&) noexcept =
default
;
36
37
constexpr
ESProxyIndex
&
operator
=(
ESProxyIndex
const
&) noexcept =
default
;
38
constexpr
ESProxyIndex
&
operator
=(
ESProxyIndex
&&) noexcept =
default
;
39
40
constexpr
bool
operator
==(
ESProxyIndex
iOther)
const
noexcept {
return
iOther.index_ ==
index_
; }
41
constexpr
bool
operator!=
(
ESProxyIndex
iOther)
const
noexcept {
return
iOther.index_ !=
index_
; }
42
43
constexpr
Value_t
value
()
const
noexcept {
return
index_
; }
44
45
private
:
46
Value_t
index_
=
std::numeric_limits<int>::max
();
47
};
48
49
inline
std::ostream&
operator<<
(std::ostream& iOS,
ESProxyIndex
const
& iIndex) {
50
iOS << iIndex.
value
();
51
return
iOS;
52
}
53
54
class
ESTokenIndex
{
55
public
:
56
using
Value_t
=
int
;
57
58
constexpr
ESTokenIndex
() noexcept =
default
;
59
constexpr explicit
ESTokenIndex
(
Value_t
iValue) noexcept :
index_
{iValue} {}
60
constexpr
ESTokenIndex
(
ESTokenIndex
const
&) noexcept =
default
;
61
constexpr
ESTokenIndex
(
ESTokenIndex
&&) noexcept =
default
;
62
63
constexpr
ESTokenIndex
&
operator
=(
ESTokenIndex
const
&) noexcept =
default
;
64
constexpr
ESTokenIndex
&
operator
=(
ESTokenIndex
&&) noexcept =
default
;
65
66
constexpr
bool
operator
==(
ESTokenIndex
iOther)
const
noexcept {
return
iOther.index_ ==
index_
; }
67
constexpr
bool
operator!=
(
ESTokenIndex
iOther)
const
noexcept {
return
iOther.index_ !=
index_
; }
68
69
constexpr
Value_t
value
()
const
noexcept {
return
index_
; }
70
71
private
:
72
Value_t
index_
=
std::numeric_limits<Value_t>::max
();
73
};
74
inline
std::ostream&
operator<<
(std::ostream& iOS,
ESTokenIndex
const
& iIndex) {
75
iOS << iIndex.
value
();
76
return
iOS;
77
}
78
79
class
ESRecordIndex
{
80
public
:
81
using
Value_t
=
unsigned
int
;
82
83
constexpr
ESRecordIndex
() noexcept =
default
;
84
constexpr explicit
ESRecordIndex
(
unsigned
int
iValue) noexcept :
index_
{iValue} {}
85
constexpr
ESRecordIndex
(
ESRecordIndex
const
&) noexcept =
default
;
86
constexpr
ESRecordIndex
(
ESRecordIndex
&&) noexcept =
default
;
87
88
constexpr
ESRecordIndex
&
operator
=(
ESRecordIndex
const
&) noexcept =
default
;
89
constexpr
ESRecordIndex
&
operator
=(
ESRecordIndex
&&) noexcept =
default
;
90
91
constexpr
bool
operator
==(
ESRecordIndex
iOther)
const
noexcept {
return
iOther.index_ ==
index_
; }
92
constexpr
bool
operator!=
(
ESRecordIndex
iOther)
const
noexcept {
return
iOther.index_ !=
index_
; }
93
94
constexpr
Value_t
value
()
const
noexcept {
return
index_
; }
95
96
private
:
97
Value_t
index_
=
std::numeric_limits<int>::max
();
98
};
99
inline
std::ostream&
operator<<
(std::ostream& iOS,
ESRecordIndex
const
& iIndex) {
100
iOS << iIndex.
value
();
101
return
iOS;
102
}
103
104
}
// namespace edm
105
#endif
edm::ESRecordIndex::ESRecordIndex
constexpr ESRecordIndex() noexcept=default
edm::ESTokenIndex
Definition:
ESIndices.h:54
edm::ESTokenIndex::operator!=
constexpr bool operator!=(ESTokenIndex iOther) const noexcept
Definition:
ESIndices.h:67
edm
HLT enums.
Definition:
AlignableModifier.h:19
edm::ESProxyIndex::Value_t
int Value_t
Definition:
ESIndices.h:31
edm::ESProxyIndex::operator!=
constexpr bool operator!=(ESProxyIndex iOther) const noexcept
Definition:
ESIndices.h:41
edm::ESProxyIndex::ESProxyIndex
constexpr ESProxyIndex() noexcept=default
edm::ESRecordIndex
Definition:
ESIndices.h:79
watchdog.const
const
Definition:
watchdog.py:83
edm::ESProxyIndex
Definition:
ESIndices.h:29
Utilities.operator
operator
Definition:
Utilities.py:24
edm::operator<<
std::ostream & operator<<(std::ostream &ost, const HLTGlobalStatus &hlt)
Formatted printout of trigger tbale.
Definition:
HLTGlobalStatus.h:106
edm::ESRecordIndex::index_
Value_t index_
Definition:
ESIndices.h:97
edm::ESRecordIndex::value
constexpr Value_t value() const noexcept
Definition:
ESIndices.h:94
ESRecordIndex
edm::ESTokenIndex::value
constexpr Value_t value() const noexcept
Definition:
ESIndices.h:69
ESTokenIndex
edm::ESTokenIndex::Value_t
int Value_t
Definition:
ESIndices.h:56
writedatasetfile.default
default
Definition:
writedatasetfile.py:11
SiStripPI::max
Definition:
SiStripPayloadInspectorHelper.h:169
createfilelist.int
int
Definition:
createfilelist.py:10
ESProxyIndex
edm::ESRecordIndex::operator!=
constexpr bool operator!=(ESRecordIndex iOther) const noexcept
Definition:
ESIndices.h:92
edm::ESProxyIndex::value
constexpr Value_t value() const noexcept
Definition:
ESIndices.h:43
edm::ESTokenIndex::ESTokenIndex
constexpr ESTokenIndex() noexcept=default
edm::ESProxyIndex::index_
Value_t index_
Definition:
ESIndices.h:46
edm::ESTokenIndex::index_
Value_t index_
Definition:
ESIndices.h:72
edm::ESRecordIndex::Value_t
unsigned int Value_t
Definition:
ESIndices.h:81
Generated for CMSSW Reference Manual by
1.8.16