src
FWCore
ParameterSet
interface
DocFormatHelper.h
Go to the documentation of this file.
1
#ifndef FWCore_ParameterSet_DocFormatHelper_h
2
#define FWCore_ParameterSet_DocFormatHelper_h
3
4
// Used internally by ParameterSetDescription in its
5
// print function. This function is used to produce
6
// human readable documentation.
7
8
#include <string>
9
#include <iosfwd>
10
#include <utility>
11
#include <vector>
12
13
namespace
edm
{
14
15
class
ParameterDescriptionNode;
16
17
class
DocFormatHelper
{
18
public
:
19
enum
DescriptionParent
{
TOP
,
OR
,
XOR
,
AND
,
OTHER
};
20
21
DocFormatHelper
()
22
:
brief_
(
false
),
23
lineWidth_
(80),
24
indentation_
(4),
25
startColumn2_
(24
U
),
26
section_
(),
27
pass_
(0),
28
column1_
(0),
29
column2_
(0),
30
column3_
(0),
31
counter_
(0),
32
parent_
(
OTHER
) {}
33
34
void
init
();
35
36
bool
brief
()
const
{
return
brief_
; }
37
size_t
lineWidth
()
const
{
return
lineWidth_
; }
38
int
indentation
()
const
{
return
indentation_
; }
39
int
startColumn2
()
const
{
return
startColumn2_
; }
40
41
void
setBrief
(
bool
value
) {
brief_
=
value
; }
42
void
setLineWidth
(
size_t
value
) {
lineWidth_
=
value
; }
43
void
setIndentation
(
int
value
) {
indentation_
=
value
; }
44
45
std::string
const
&
section
()
const
{
return
section_
; }
46
void
setSection
(
std::string
const
&
value
) {
section_
=
value
; }
47
48
int
pass
()
const
{
return
pass_
; }
49
void
setPass
(
int
value
) {
pass_
=
value
; }
50
51
size_t
column1
()
const
{
return
column1_
; }
52
size_t
column2
()
const
{
return
column2_
; }
53
size_t
column3
()
const
{
return
column3_
; }
54
55
void
setAtLeast1
(
size_t
width
) {
56
if
(
width
>
column1_
)
57
column1_
=
width
;
58
}
59
void
setAtLeast2
(
size_t
width
) {
60
if
(
width
>
column2_
)
61
column2_
=
width
;
62
}
63
void
setAtLeast3
(
size_t
width
) {
64
if
(
width
>
column3_
)
65
column3_
=
width
;
66
}
67
68
int
counter
()
const
{
return
counter_
; }
69
void
setCounter
(
int
value
) {
counter_
=
value
; }
70
void
incrementCounter
() { ++
counter_
; }
71
void
decrementCounter
() { --
counter_
; }
72
73
DescriptionParent
parent
()
const
{
return
parent_
; }
74
void
setParent
(
DescriptionParent
value
) {
parent_
=
value
; }
75
76
size_t
commentWidth
()
const
;
77
78
static
void
wrapAndPrintText
(std::ostream& os,
std::string
const
&
text
,
size_t
indent
,
size_t
suggestedWidth);
79
80
void
indent
(std::ostream& os)
const
;
81
void
indent2
(std::ostream& os)
const
;
82
83
static
int
offsetModuleLabel
() {
return
2; }
84
static
int
offsetTopLevelPSet
() {
return
2; }
85
static
int
offsetSectionContent
() {
return
4; }
86
87
void
addCategory
(
std::string
const
&
pluginCategory
,
std::string
const
&
section
);
88
std::string
sectionOfCategoryAlreadyPrinted
(
std::string
const
&
pluginCategory
)
const
;
89
90
private
:
91
std::vector<std::pair<std::string, std::string>>
pluginCategoriesAlreadyPrinted_
;
92
bool
brief_
;
93
size_t
lineWidth_
;
94
int
indentation_
;
95
size_t
startColumn2_
;
96
97
std::string
section_
;
98
99
int
pass_
;
100
101
size_t
column1_
;
102
size_t
column2_
;
103
size_t
column3_
;
104
105
int
counter_
;
106
107
DescriptionParent
parent_
;
108
};
109
}
// namespace edm
110
#endif
edm::DocFormatHelper::counter_
int counter_
Definition:
DocFormatHelper.h:105
edm::DocFormatHelper::brief_
bool brief_
Definition:
DocFormatHelper.h:92
edm::DocFormatHelper::section_
std::string section_
Definition:
DocFormatHelper.h:97
edm::DocFormatHelper::OR
Definition:
DocFormatHelper.h:19
edm::DocFormatHelper::counter
int counter() const
Definition:
DocFormatHelper.h:68
edm::DocFormatHelper::AND
Definition:
DocFormatHelper.h:19
edm::DocFormatHelper::pass
int pass() const
Definition:
DocFormatHelper.h:48
funct::false
false
Definition:
Factorize.h:29
edm::DocFormatHelper::startColumn2
int startColumn2() const
Definition:
DocFormatHelper.h:39
edm::DocFormatHelper::wrapAndPrintText
static void wrapAndPrintText(std::ostream &os, std::string const &text, size_t indent, size_t suggestedWidth)
Definition:
DocFormatHelper.cc:98
edm::DocFormatHelper::pluginCategoriesAlreadyPrinted_
std::vector< std::pair< std::string, std::string > > pluginCategoriesAlreadyPrinted_
Definition:
DocFormatHelper.h:91
edm::DocFormatHelper::startColumn2_
size_t startColumn2_
Definition:
DocFormatHelper.h:95
edm::DocFormatHelper::TOP
Definition:
DocFormatHelper.h:19
edm::DocFormatHelper::init
void init()
Definition:
DocFormatHelper.cc:114
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::DocFormatHelper::indentation
int indentation() const
Definition:
DocFormatHelper.h:38
mitigatedMETSequence_cff.U
U
Definition:
mitigatedMETSequence_cff.py:36
edm::DocFormatHelper::commentWidth
size_t commentWidth() const
Definition:
DocFormatHelper.cc:124
edm::DocFormatHelper::setCounter
void setCounter(int value)
Definition:
DocFormatHelper.h:69
edm::DocFormatHelper::column1_
size_t column1_
Definition:
DocFormatHelper.h:101
edm::DocFormatHelper::indent2
void indent2(std::ostream &os) const
Definition:
DocFormatHelper.cc:140
edm::DocFormatHelper::offsetModuleLabel
static int offsetModuleLabel()
Definition:
DocFormatHelper.h:83
edm::DocFormatHelper::pass_
int pass_
Definition:
DocFormatHelper.h:99
edm::DocFormatHelper::setBrief
void setBrief(bool value)
Definition:
DocFormatHelper.h:41
edm::DocFormatHelper::column1
size_t column1() const
Definition:
DocFormatHelper.h:51
edm::DocFormatHelper::incrementCounter
void incrementCounter()
Definition:
DocFormatHelper.h:70
edm::DocFormatHelper::setAtLeast2
void setAtLeast2(size_t width)
Definition:
DocFormatHelper.h:59
edm::DocFormatHelper::offsetSectionContent
static int offsetSectionContent()
Definition:
DocFormatHelper.h:85
value
Definition:
value.py:1
edm::DocFormatHelper::column3
size_t column3() const
Definition:
DocFormatHelper.h:53
edm::DocFormatHelper::OTHER
Definition:
DocFormatHelper.h:19
edm::DocFormatHelper::setPass
void setPass(int value)
Definition:
DocFormatHelper.h:49
edm::DocFormatHelper::column2
size_t column2() const
Definition:
DocFormatHelper.h:52
edm::DocFormatHelper::XOR
Definition:
DocFormatHelper.h:19
edm::DocFormatHelper::DocFormatHelper
DocFormatHelper()
Definition:
DocFormatHelper.h:21
edm::DocFormatHelper::parent_
DescriptionParent parent_
Definition:
DocFormatHelper.h:107
edm::DocFormatHelper::section
std::string const & section() const
Definition:
DocFormatHelper.h:45
relativeConstraints.value
value
Definition:
relativeConstraints.py:53
cond::pluginCategory
const char * pluginCategory()
Definition:
ProductResolverFactory.cc:64
submitPVValidationJobs.text
string text
Definition:
submitPVValidationJobs.py:484
edm::DocFormatHelper::column3_
size_t column3_
Definition:
DocFormatHelper.h:103
ApeEstimator_cff.width
width
Definition:
ApeEstimator_cff.py:24
edm::DocFormatHelper::addCategory
void addCategory(std::string const &pluginCategory, std::string const §ion)
Definition:
DocFormatHelper.cc:146
edm
HLT enums.
Definition:
AlignableModifier.h:19
edm::DocFormatHelper::brief
bool brief() const
Definition:
DocFormatHelper.h:36
edm::DocFormatHelper
Definition:
DocFormatHelper.h:17
edm::DocFormatHelper::lineWidth_
size_t lineWidth_
Definition:
DocFormatHelper.h:93
edm::DocFormatHelper::lineWidth
size_t lineWidth() const
Definition:
DocFormatHelper.h:37
edm::DocFormatHelper::setAtLeast1
void setAtLeast1(size_t width)
Definition:
DocFormatHelper.h:55
edm::DocFormatHelper::setAtLeast3
void setAtLeast3(size_t width)
Definition:
DocFormatHelper.h:63
edm::DocFormatHelper::column2_
size_t column2_
Definition:
DocFormatHelper.h:102
edm::DocFormatHelper::offsetTopLevelPSet
static int offsetTopLevelPSet()
Definition:
DocFormatHelper.h:84
edm::DocFormatHelper::setSection
void setSection(std::string const &value)
Definition:
DocFormatHelper.h:46
edm::DocFormatHelper::indent
void indent(std::ostream &os) const
Definition:
DocFormatHelper.cc:134
edm::DocFormatHelper::sectionOfCategoryAlreadyPrinted
std::string sectionOfCategoryAlreadyPrinted(std::string const &pluginCategory) const
Definition:
DocFormatHelper.cc:150
edm::DocFormatHelper::indentation_
int indentation_
Definition:
DocFormatHelper.h:94
edm::DocFormatHelper::DescriptionParent
DescriptionParent
Definition:
DocFormatHelper.h:19
edm::DocFormatHelper::setParent
void setParent(DescriptionParent value)
Definition:
DocFormatHelper.h:74
edm::DocFormatHelper::parent
DescriptionParent parent() const
Definition:
DocFormatHelper.h:73
edm::DocFormatHelper::setIndentation
void setIndentation(int value)
Definition:
DocFormatHelper.h:43
edm::DocFormatHelper::setLineWidth
void setLineWidth(size_t value)
Definition:
DocFormatHelper.h:42
edm::DocFormatHelper::decrementCounter
void decrementCounter()
Definition:
DocFormatHelper.h:71
Generated for CMSSW Reference Manual by
1.8.14