Loading [MathJax]/extensions/tex2jax.js
The Gaudi Framework
v36r16 (ea80daf8)
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Typedefs
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
Enumerations
Enumerator
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
y
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
:
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Enumerations
a
c
d
e
f
i
l
m
n
o
p
r
s
t
Enumerator
a
b
c
d
e
f
i
j
k
l
m
n
o
p
r
s
t
u
v
w
Properties
Related Functions
:
a
b
c
d
e
g
h
i
m
o
p
s
t
v
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Functions
_
b
c
e
f
g
h
i
l
m
n
o
p
r
s
t
u
z
Variables
a
b
c
d
e
g
h
i
m
o
p
r
s
t
v
x
Typedefs
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
w
Enumerations
Enumerator
c
e
f
p
u
v
Macros
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
Factory.h
Go to the documentation of this file.
1
/***********************************************************************************\
2
* (c) Copyright 1998-2019 CERN for the benefit of the LHCb and ATLAS collaborations *
3
* *
4
* This software is distributed under the terms of the Apache version 2 licence, *
5
* copied verbatim in the file "LICENSE". *
6
* *
7
* In applying this licence, CERN does not waive the privileges and immunities *
8
* granted to it by virtue of its status as an Intergovernmental Organization *
9
* or submit itself to any jurisdiction. *
10
\***********************************************************************************/
11
#pragma once
12
// ============================================================================
13
// Include files
14
// ============================================================================
15
// STD & STL
16
// ============================================================================
17
#include <map>
18
#include <string>
19
#include <vector>
20
// ============================================================================
21
// Boost:
22
// ============================================================================
23
#include <boost/mpl/assert.hpp>
24
#include <boost/type_traits.hpp>
25
// ============================================================================
26
// Gaudi
27
// ============================================================================
28
#include <
Gaudi/Parsers/Grammars.h
>
29
#include <
GaudiKernel/StatusCode.h
>
30
// ============================================================================
31
namespace
Gaudi
{
32
namespace
Parsers {
33
// ========================================================================
34
typedef
std::string::const_iterator
IteratorT
;
35
// typedef boost::spirit::ascii::space_type Skipper;
36
typedef
SkipperGrammar<IteratorT>
Skipper
;
37
// ========================================================================
38
template
<
typename
ResultT>
39
inline
StatusCode
parse_
( ResultT& result,
const
std::string
& input ) {
40
Skipper
skipper;
41
typename
Grammar_<IteratorT, ResultT, Skipper>::Grammar
g
;
42
IteratorT
iter = input.
begin
(),
end
= input.
end
();
43
return
( qi::phrase_parse( iter,
end
,
g
, skipper, result ) && ( iter ==
end
) ?
StatusCode::SUCCESS
44
:
StatusCode::FAILURE
);
45
}
46
//=========================================================================
47
template
<>
48
inline
StatusCode
parse_
(
std::string
& result,
const
std::string
& input ) {
49
Skipper
skipper;
50
Grammar_<IteratorT, std::string, Skipper>::Grammar
g
;
51
IteratorT
iter = input.
begin
(),
end
= input.
end
();
52
if
( !( qi::phrase_parse( iter,
end
,
g
, skipper, result ) && ( iter ==
end
) ) ) { result = input; }
53
//@attention always
54
return
StatusCode::SUCCESS
;
55
}
56
//=========================================================================
57
template
<
typename
ResultT>
58
inline
StatusCode
parse
( ResultT& result,
const
std::string
& input ) {
59
return
parse_
( result, input );
60
}
61
//=========================================================================
62
}
// namespace Parsers
63
}
// namespace Gaudi
Gaudi::Parsers::IteratorT
std::string::const_iterator IteratorT
Definition:
Factory.h:34
std::string
STL class.
Grammars.h
StatusCode.h
StatusCode
Definition:
StatusCode.h:65
gaudirun.g
dictionary g
Definition:
gaudirun.py:581
Gaudi::Parsers::parse_
StatusCode parse_(ResultT &result, const std::string &input)
Definition:
Factory.h:39
Gaudi::Parsers::SkipperGrammar
Definition:
Grammar.h:51
Gaudi
Header file for std:chrono::duration-based Counters.
Definition:
__init__.py:1
Gaudi::Parsers::Skipper
SkipperGrammar< IteratorT > Skipper
Definition:
Factory.h:36
StatusCode::SUCCESS
constexpr static const auto SUCCESS
Definition:
StatusCode.h:100
Gaudi::Parsers::Grammar_
Definition:
Grammars.h:68
std::string::begin
T begin(T... args)
Gaudi::Parsers::parse
StatusCode parse(GaudiUtils::HashMap< K, V > &result, const std::string &input)
Basic parser for the types of HashMap used in DODBasicMapper.
Definition:
DODBasicMapper.cpp:21
std::string::end
T end(T... args)
IOTest.end
end
Definition:
IOTest.py:123
StatusCode::FAILURE
constexpr static const auto FAILURE
Definition:
StatusCode.h:101
GaudiKernel
include
Gaudi
Parsers
Factory.h
Generated on Fri Jul 28 2023 16:22:55 for The Gaudi Framework by
1.8.18