Fireworks
Core
interface
FWEnumParameter.h
Go to the documentation of this file.
1
#ifndef Fireworks_Core_FWEnumParameter_h
2
#define Fireworks_Core_FWEnumParameter_h
3
// -*- C++ -*-
4
//
5
// Package: Core
6
// Class : FWEnumParameter
7
//
16
//
17
// Original Author: matevz
18
// Created: Fri Apr 30 15:16:55 CEST 2010
19
//
20
21
// system include files
22
23
// user include files
24
#include "
Fireworks/Core/interface/FWLongParameter.h
"
25
#include "RtypesCore.h"
26
#include <map>
27
28
// forward declarations
29
30
class
FWEnumParameter
:
public
FWLongParameter
{
31
public
:
32
FWEnumParameter
() :
FWLongParameter
() {}
33
34
FWEnumParameter
(
35
FWParameterizable
* iParent,
const
std::string
& iName,
const
long
& iDefault = 0,
long
iMin = -1,
long
iMax = -1)
36
:
FWLongParameter
(iParent, iName, iDefault, iMin, iMax) {}
37
38
template
<
class
K>
39
FWEnumParameter
(
FWParameterizable
* iParent,
40
const
std::string
& iName,
41
K iCallback,
42
const
long
& iDefault = 0,
43
long
iMin = -1,
44
long
iMax = -1)
45
:
FWLongParameter
(iParent, iName, iCallback, iDefault, iMin, iMax) {}
46
47
// ---------- const member functions ---------------------
48
49
// ---------- static member functions --------------------
50
51
// ---------- member functions ---------------------------
52
53
bool
addEntry
(Long_t
id
,
const
std::string
& txt) {
return
m_enumEntries
.insert(std::make_pair(
id
, txt)).second; }
54
55
const
std::map<Long_t, std::string>&
entryMap
()
const
{
return
m_enumEntries
; }
56
57
private
:
58
FWEnumParameter
(
const
FWEnumParameter
&) =
delete
;
// stop default
59
const
FWEnumParameter
&
operator=
(
const
FWEnumParameter
&) =
delete
;
// stop default
60
61
// ---------- member data --------------------------------
62
std::map<Long_t, std::string>
m_enumEntries
;
63
};
64
65
#endif
FWEnumParameter::entryMap
const std::map< Long_t, std::string > & entryMap() const
Definition:
FWEnumParameter.h:55
FWEnumParameter
Definition:
FWEnumParameter.h:30
FWGenericParameterWithRange
Definition:
FWGenericParameterWithRange.h:27
FWEnumParameter::addEntry
bool addEntry(Long_t id, const std::string &txt)
Definition:
FWEnumParameter.h:53
FWEnumParameter::m_enumEntries
std::map< Long_t, std::string > m_enumEntries
Definition:
FWEnumParameter.h:62
FWEnumParameter::operator=
const FWEnumParameter & operator=(const FWEnumParameter &)=delete
FWEnumParameter::FWEnumParameter
FWEnumParameter(FWParameterizable *iParent, const std::string &iName, const long &iDefault=0, long iMin=-1, long iMax=-1)
Definition:
FWEnumParameter.h:34
FWLongParameter.h
FWEnumParameter::FWEnumParameter
FWEnumParameter()
Definition:
FWEnumParameter.h:32
FWParameterizable
Definition:
FWParameterizable.h:29
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
FWEnumParameter::FWEnumParameter
FWEnumParameter(FWParameterizable *iParent, const std::string &iName, K iCallback, const long &iDefault=0, long iMin=-1, long iMax=-1)
Definition:
FWEnumParameter.h:39
Generated for CMSSW Reference Manual by
1.8.16