| The Gaudi Framework v30r0 (c919700c)

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

GrammarsV2.h
Go to the documentation of this file.
1 // ============================================================================
2 #ifndef GAUDIKERNEL_GRAMMARSV2_H
3 #define GAUDIKERNEL_GRAMMARSV2_H 1
4 #ifdef __GNUC__
5 #pragma GCC system_header
6 #endif
7 // ============================================================================
8 // Include files
9 // ============================================================================
10 // STD:
11 //==============================================================================
12 #include <list>
13 #include <map>
14 #include <set>
15 #include <string>
16 #include <tuple>
17 #include <vector>
18 //==============================================================================
19 // Boost:
20 //==============================================================================
21 #include <boost/fusion/include/std_pair.hpp>
22 #include <boost/fusion/include/unused.hpp>
23 #include <boost/spirit/include/qi.hpp>
24
25 #include <boost/spirit/include/phoenix_core.hpp>
26 #include <boost/spirit/include/phoenix_operator.hpp>
27
28 #include <boost/type_traits.hpp>
29 #include <boost/utility/enable_if.hpp>
30
31 #include <boost/spirit/repository/include/qi_confix.hpp>
32 //==============================================================================
33 // Gaudi:
34 //==============================================================================
35 #include "GaudiKernel/HashMap.h"
36 #include "GaudiKernel/HistoDef.h"
37 #include "GaudiKernel/Point3DTypes.h"
38 #include "GaudiKernel/Point4DTypes.h"
39 #include "GaudiKernel/StringKey.h"
40 #include "GaudiKernel/VectorMap.h"
41 //==============================================================================
42 namespace Gaudi
43 {
44 namespace Parsers
45 {
46 //==============================================================================
47 // Namespace aliases:
48 //==============================================================================
49 namespace sp = boost::spirit;
50 namespace ph = boost::phoenix;
51 namespace qi = sp::qi;
52 namespace enc = sp::ascii;
53 namespace rep = sp::repository;
54 //==============================================================================
55 // Grammars
56 //==============================================================================
57 typedef std::string::const_iterator DefaultIterator;
58 typedef enc::space_type DefaultSkipper;
59 //==============================================================================
60 template <typename Iterator, typename T, typename Skipper, class Enable = void>
61 struct Grammar_ {
62 /* READ THIS IF YOUR COMPILE BREAKS ON THE FOLLOWING LINE
63 *
64 * To users: You have to ask developers to implement parser for your type T
65 * To developer: You have to implement and register Grammar for type T
66 *
67 */
68 BOOST_MPL_ASSERT_MSG( false, GRAMMAR_FOR_TYPE_DOES_NOT_EXISTS, ( T ) );
69 };
70
71 #define REGISTER_GRAMMAR( ResultType, GrammarName ) \
72 template <typename Iterator, typename Skipper> \
73 struct Grammar_<Iterator, ResultType, Skipper> { \
74 typedef GrammarName<Iterator, Skipper> Grammar; \
75 }
76 //==============================================================================
77 template <typename Iterator>
78 struct SkipperGrammar : qi::grammar<Iterator> {
79 SkipperGrammar() : SkipperGrammar::base_type( comments )
80 {
81 comments = enc::space | rep::confix( "/*", "*/" )[*( qi::char_ - "*/" )] |
82 rep::confix( "//", ( sp::eol | sp::eoi ) )[*( qi::char_ - ( sp::eol | sp::eoi ) )];
83 }
84 qi::rule<Iterator> comments;
85 };
86 //==============================================================================
87 template <typename Iterator, typename Skipper>
88 struct StringGrammar : qi::grammar<Iterator, std::string(), qi::locals<char>, Skipper> {
89 //------------------------------------------------------------------------------
90 typedef std::string ResultT;
91 //------------------------------------------------------------------------------
92 StringGrammar() : StringGrammar::base_type( str )
93 {
94 begin_quote = enc::char_( "\"'" );
95 quote = enc::char_( qi::_r1 );
96
97 str = qi::lexeme[begin_quote[qi::_a = qi::_1] >
98 *( ( enc::char_( '\\' ) >> quote( qi::_a ) )[qi::_val += qi::_a] |
99 ( enc::char_[qi::_val += qi::_1] - quote( qi::_a ) ) ) > quote( qi::_a )];
100 }
101 //------------------------------------------------------------------------------
102 qi::rule<Iterator, std::string(), qi::locals<char>, Skipper> str;
103 qi::rule<Iterator, char()> begin_quote;
104 qi::rule<Iterator, void( char )> quote;
105 //------------------------------------------------------------------------------
106 };
107 REGISTER_GRAMMAR( std::string, StringGrammar );
108 REGISTER_GRAMMAR( Gaudi::StringKey, StringGrammar );
109 //==============================================================================
110 template <typename Iterator, typename Skipper>
111 struct CharGrammar : qi::grammar<Iterator, char(), Skipper> {
112 typedef char ResultT;
113 CharGrammar() : CharGrammar::base_type( ch )
114 {
115 ch = qi::int_parser<char>() | '\'' >> ( qi::char_ - '\'' ) >> '\'';
116 }
117 qi::rule<Iterator, char(), Skipper> ch;
118 };
119 REGISTER_GRAMMAR( char, CharGrammar );
120 //==============================================================================
121 template <typename Iterator, typename Skipper>
122 struct BoolGrammar : qi::grammar<Iterator, bool(), Skipper> {
123 typedef bool ResultT;
124 BoolGrammar() : BoolGrammar::base_type( boolean_literal )
125 {
126 boolean_literal = ( qi::lit( "true" ) | "True" | "TRUE" | "1" )[qi::_val = true] |
127 ( qi::lit( "false" ) | "False" | "FALSE" | "0" )[qi::_val = false];
128 }
129 qi::rule<Iterator, bool(), Skipper> boolean_literal;
130 };
131 REGISTER_GRAMMAR( bool, BoolGrammar );
132 //==============================================================================
133 template <typename Iterator, typename RT, typename Skipper>
134 struct IntGrammar : qi::grammar<Iterator, RT(), Skipper> {
135 typedef RT ResultT;
136 IntGrammar() : IntGrammar::base_type( integer )
137 {
138 integer = qi::int_parser<RT>()[qi::_val = qi::_1] >> -qi::no_case[qi::char_( 'L' )];
139 }
140 qi::rule<Iterator, RT(), Skipper> integer;
141 };
142 // ----------------------------------------------------------------------------
143 // Register IntGrammar:
144 // ----------------------------------------------------------------------------
145 template <typename Iterator, typename T, typename Skipper>
146 struct Grammar_<Iterator, T, Skipper, typename boost::enable_if<boost::is_integral<T>>::type> {
147 typedef IntGrammar<Iterator, T, Skipper> Grammar;
148 };
149 //==============================================================================
150 template <typename Iterator, typename RT, typename Skipper>
151 struct RealGrammar : qi::grammar<Iterator, RT(), Skipper> {
152 typedef RT ResultT;
153 RealGrammar() : RealGrammar::base_type( real ) { real = qi::real_parser<RT>(); }
154 qi::rule<Iterator, RT(), Skipper> real;
155 };
156 // ----------------------------------------------------------------------------
157 // Register RealGrammar:
158 // ----------------------------------------------------------------------------
159 template <typename Iterator, typename T, typename Skipper>
160 struct Grammar_<Iterator, T, Skipper, typename boost::enable_if<boost::is_floating_point<T>>::type> {
161 typedef RealGrammar<Iterator, T, Skipper> Grammar;
162 };
163 //==============================================================================
164 // Grammar for std::tuples
165 //==============================================================================
166 template <typename T>
167 struct tuple_remove_first_type {
168 };
169
170 template <typename T>
171 struct tuple_get_first_type {
172 };
173
174 template <typename T, typename... Ts>
175 struct tuple_remove_first_type<std::tuple<T, Ts...>> {
176 typedef std::tuple<Ts...> type;
177 };
178
179 template <typename T, typename... Ts>
180 struct tuple_get_first_type<std::tuple<T, Ts...>> {
181 typedef T type;
182 };
183
184 // ----------------------------------------------------------------------------
185
186 template <typename Iterator, typename TupleT, std::size_t N, typename Skipper>
187 struct TupleInnerGrammar
188 : qi::grammar<Iterator, TupleT(), qi::locals<typename tuple_get_first_type<TupleT>::type>, Skipper> {
189 //---------------------------------------------------------------------------
190 typedef TupleT ResultT;
191 typedef typename tuple_remove_first_type<TupleT>::type TailT;
192 typedef typename tuple_get_first_type<TupleT>::type HeadT;
193 //---------------------------------------------------------------------------
194 struct Operations {
195 //----------------------------------------------------------------------
196
197 void operator()( ResultT& res, HeadT& head, TailT& tail ) const
198 {
199 res = std::tuple_cat( std::tuple<HeadT>( head ), tail );
200 }
201 //----------------------------------------------------------------------
202 };
203 //---------------------------------------------------------------------------
204 TupleInnerGrammar() : TupleInnerGrammar::base_type( tup )
205 {
206 tup = grHead[qi::_a = qi::_1] >> ',' >> grLast[op( qi::_val, qi::_a, qi::_1 )];
207 }
208
209 TupleInnerGrammar<Iterator, TailT, N - 1, Skipper> grLast;
210 typename Grammar_<Iterator, HeadT, Skipper>::Grammar grHead;
211
212 qi::rule<Iterator, ResultT(), qi::locals<HeadT>, Skipper> tup;
213 ph::function<Operations> op;
214 };
215
216 template <typename Iterator, typename TupleT, typename Skipper>
217 struct TupleInnerGrammar<Iterator, TupleT, 1, Skipper> : qi::grammar<Iterator, TupleT(), Skipper> {
218 //---------------------------------------------------------------------------
219 typedef TupleT ResultT;
220 // typedef typename ResultT::value_type Tuple1T;
221 //---------------------------------------------------------------------------
222 struct Operations {
223 //---------------------------------------------------------------------
224 void operator()( ResultT& res, const typename std::tuple_element<0, ResultT>::type& val ) const
225 {
226 res = ResultT();
227 std::get<0>( res ) = val;
228 }
229 //----------------------------------------------------------------------
230 };
231 //---------------------------------------------------------------------------
232 TupleInnerGrammar() : TupleInnerGrammar::base_type( tup ) { tup = grFirst[op( qi::_val, qi::_1 )]; }
233
234 typename Grammar_<Iterator, typename std::tuple_element<0, ResultT>::type, Skipper>::Grammar grFirst;
235
236 qi::rule<Iterator, ResultT(), Skipper> tup;
237 ph::function<Operations> op;
238 };
239
240 // ----------------------------------------------------------------------------
241 template <typename Iterator, typename TupleT, std::size_t N, typename Skipper>
242 struct TupleGrammar : qi::grammar<Iterator, TupleT(), qi::locals<char>, Skipper> {
243 typedef TupleT ResultT;
244 TupleGrammar() : TupleGrammar::base_type( tup )
245 {
246 begin = enc::char_( '[' )[qi::_val = ']'] | enc::char_( '(' )[qi::_val = ')'];
247 end = enc::char_( qi::_r1 );
248
249 tup = begin[qi::_a = qi::_1] >> grTuple[qi::_val = qi::_1] >> end( qi::_a );
250 }
251
252 qi::rule<Iterator, char()> begin;
253 qi::rule<Iterator, void( char )> end;
254 qi::rule<Iterator, ResultT(), qi::locals<char>, Skipper> tup;
255 TupleInnerGrammar<Iterator, TupleT, N, Skipper> grTuple;
256 };
257
258 // -----------------------------------------------------------------------------
259 // Register TupleGrammar for std::tuple:
260 // ----------------------------------------------------------------------------
261 template <typename Iterator, typename Skipper, typename... Args>
262 struct Grammar_<Iterator, std::tuple<Args...>, Skipper> {
263 typedef TupleGrammar<Iterator, std::tuple<Args...>, sizeof...( Args ), Skipper> Grammar;
264 };
265 //==============================================================================
266 template <typename Iterator, typename VectorT, typename Skipper>
267 struct VectorGrammar : qi::grammar<Iterator, VectorT(), qi::locals<char>, Skipper> {
268 //------------------------------------------------------------------------------
269 typedef VectorT ResultT;
270 //------------------------------------------------------------------------------
271 VectorGrammar() : VectorGrammar::base_type( vec )
272 {
273 begin =
274 enc::char_( '[' )[qi::_val = ']'] | enc::char_( '{' )[qi::_val = '}'] | enc::char_( '(' )[qi::_val = ')'];
275 end = enc::char_( qi::_r1 );
276 list = elementGrammar % ',';
277 vec = begin[qi::_a = qi::_1] >> -list[qi::_val = qi::_1] >> end( qi::_a );
278 }
279 // ----------------------------------------------------------------------------
280 typename Grammar_<Iterator, typename VectorT::value_type, Skipper>::Grammar elementGrammar;
281 qi::rule<Iterator, char()> begin;
282 qi::rule<Iterator, void( char )> end;
283
284 qi::rule<Iterator, ResultT(), qi::locals<char>, Skipper> vec;
285 qi::rule<Iterator, ResultT(), Skipper> list;
286 // ----------------------------------------------------------------------------
287 };
288 // ----------------------------------------------------------------------------
289 // Register VectorGrammar for std::vector:
290 // ----------------------------------------------------------------------------
291 template <typename Iterator, typename InnerT, typename AllocatorT, typename Skipper>
292 struct Grammar_<Iterator, std::vector<InnerT, AllocatorT>, Skipper> {
293 typedef VectorGrammar<Iterator, std::vector<InnerT, AllocatorT>, Skipper> Grammar;
294 };
295 // ----------------------------------------------------------------------------
296 // Register VectorGrammar for std::list:
297 // ----------------------------------------------------------------------------
298 template <typename Iterator, typename InnerT, typename AllocatorT, typename Skipper>
299 struct Grammar_<Iterator, std::list<InnerT, AllocatorT>, Skipper> {
300 typedef VectorGrammar<Iterator, std::list<InnerT, AllocatorT>, Skipper> Grammar;
301 };
302 // ----------------------------------------------------------------------------
303 // Register VectorGrammar for std::set:
304 // ----------------------------------------------------------------------------
305 template <typename Iterator, typename InnerT, typename CompareT, typename AllocatorT, typename Skipper>
306 struct Grammar_<Iterator, std::set<InnerT, CompareT, AllocatorT>, Skipper> {
307 typedef VectorGrammar<Iterator, std::set<InnerT, CompareT, AllocatorT>, Skipper> Grammar;
308 };
309
310 //==============================================================================
311 template <typename Iterator, typename PairT, typename Skipper>
312 struct PairGrammar : qi::grammar<Iterator, PairT(), qi::locals<char>, Skipper> {
313 //------------------------------------------------------------------------------
314 typedef PairT ResultT;
315 typedef typename PairT::first_type first_type;
316 typedef typename PairT::second_type second_type;
317 //------------------------------------------------------------------------------
318 PairGrammar() : PairGrammar::base_type( pair ) { init( "," ); }
319
320 PairGrammar( const std::string& delimeter ) : PairGrammar::base_type( pair ) { init( delimeter ); }
321 //------------------------------------------------------------------------------
322 struct first {
323 };
324 struct second {
325 };
326 void init( const std::string& delimeter )
327 {
328 begin = enc::char_( '(' )[qi::_val = ')'] | enc::char_( '[' )[qi::_val = ']'];
329 end = qi::char_( qi::_r1 );
330 pair = begin[qi::_a = qi::_1] >> pair_in[qi::_val = qi::_1] >> end( qi::_a );
331 pair_in = key >> qi::lit( delimeter ) >> value;
332 }
333 // ----------------------------------------------------------------------------
334 typename Grammar_<Iterator, typename PairT::first_type, Skipper>::Grammar key;
335 typename Grammar_<Iterator, typename PairT::second_type, Skipper>::Grammar value;
336 qi::rule<Iterator, char()> begin;
337 qi::rule<Iterator, void( char )> end;
338 qi::rule<Iterator, ResultT(), qi::locals<char>, Skipper> pair;
339 qi::rule<Iterator, ResultT(), Skipper> pair_in;
340 // ph::function<Operations> op;
341 // ----------------------------------------------------------------------------
342 }; // END PairGrammar
343 // ----------------------------------------------------------------------------
344 // Register PairGrammar:
345 // ----------------------------------------------------------------------------
346 template <typename Iterator, typename KeyT, typename ValueT, typename Skipper>
347 struct Grammar_<Iterator, std::pair<KeyT, ValueT>, Skipper> {
348 typedef PairGrammar<Iterator, std::pair<KeyT, ValueT>, Skipper> Grammar;
349 };
350 // ============================================================================
351 template <typename Iterator, typename MapT, typename Skipper>
352 struct MapGrammar : qi::grammar<Iterator, MapT(), Skipper> {
353 //------------------------------------------------------------------------------
354 typedef MapT ResultT;
355 typedef typename MapT::key_type KeyT;
356 typedef typename MapT::mapped_type MappedT;
357 typedef std::pair<KeyT, MappedT> PairT;
358
359 typedef std::vector<PairT> VectorPairT;
360 //------------------------------------------------------------------------------
361 struct tag_key {
362 };
363 struct tag_mapped {
364 };
365 struct Operations {
366 //----------------------------------------------------------------------
367 void operator()( ResultT& res, const VectorPairT& vec ) const
368 {
369 for ( auto cur = vec.begin(); cur != vec.end(); ++cur ) {
370 res.insert( *cur );
371 }
372 }
373 void operator()( PairT& res, const KeyT& key, tag_key ) const { res.first = key; }
374 void operator()( PairT& res, const MappedT& value, tag_mapped ) const { res.second = value; }
375 //----------------------------------------------------------------------
376 };
377 //------------------------------------------------------------------------------
378 MapGrammar() : MapGrammar::base_type( map )
379 {
380 pair = key[op( qi::_val, qi::_1, tag_key() )] > ( qi::lit( ':' ) | '=' ) >
381 value[op( qi::_val, qi::_1, tag_mapped() )];
382 list = -( pair % enc::char_( ',' ) );
383 map = ( ( '[' >> list >> ']' ) | ( '{' >> list >> '}' ) )[op( qi::_val, qi::_1 )];
384 }
385 // ----------------------------------------------------------------------------
386 typename Grammar_<Iterator, typename MapT::key_type, Skipper>::Grammar key;
387 typename Grammar_<Iterator, typename MapT::mapped_type, Skipper>::Grammar value;
388 qi::rule<Iterator, PairT(), Skipper> pair;
389 qi::rule<Iterator, VectorPairT(), Skipper> list;
390 qi::rule<Iterator, ResultT(), Skipper> map;
391 ph::function<Operations> op;
392 // ----------------------------------------------------------------------------
393 };
394 // ----------------------------------------------------------------------------
395 // Register MapGrammar for std::map:
396 // ----------------------------------------------------------------------------
397 template <typename Iterator, typename KeyT, typename ValueT, typename KeyCompareT, typename AllocatorT,
398 typename Skipper>
399 struct Grammar_<Iterator, std::map<KeyT, ValueT, KeyCompareT, AllocatorT>, Skipper> {
400 typedef MapGrammar<Iterator, std::map<KeyT, ValueT, KeyCompareT, AllocatorT>, Skipper> Grammar;
401 };
402 // ----------------------------------------------------------------------------
403 // Register MapGrammar for GaudiUtils::VectorMap:
404 // ----------------------------------------------------------------------------
405 template <typename Iterator, typename KeyT, typename ValueT, typename KeyCompareT, typename AllocatorT,
406 typename Skipper>
407 struct Grammar_<Iterator, GaudiUtils::VectorMap<KeyT, ValueT, KeyCompareT, AllocatorT>, Skipper> {
408 typedef MapGrammar<Iterator, GaudiUtils::VectorMap<KeyT, ValueT, KeyCompareT, AllocatorT>, Skipper> Grammar;
409 };
410 // ============================================================================
411 template <typename Iterator, typename PointT, typename Skipper>
412 struct Pnt3DGrammar : qi::grammar<Iterator, PointT(), Skipper> {
413 typedef PointT ResultT;
414 typedef typename PointT::Scalar Scalar;
415 // ----------------------------------------------------------------------------
416 struct Operations {
417 void operator()( ResultT& res, const Scalar& scalar, const char xyz ) const
418 {
419 switch ( xyz ) {
420 case 'x':
421 res.SetX( scalar );
422 break;
423 case 'y':
424 res.SetY( scalar );
425 break;
426 case 'z':
427 res.SetZ( scalar );
428 break;
429 default:
430 break;
431 }
432 }
433 }; // Operations
434 // ----------------------------------------------------------------------------
435 Pnt3DGrammar() : Pnt3DGrammar::base_type( point )
436 {
437 point = list | ( '(' >> list >> ')' ) | ( '[' >> list >> ']' );
438 list = -( enc::no_case[qi::lit( "x" ) | qi::lit( "px" )] >> ':' ) >> scalar[op( qi::_val, qi::_1, 'x' )] >>
439 ',' >> -( enc::no_case[qi::lit( "y" ) | qi::lit( "py" )] >> ':' ) >>
440 scalar[op( qi::_val, qi::_1, 'y' )] >> ',' >>
441 -( enc::no_case[qi::lit( "z" ) | qi::lit( "pz" )] >> ':' ) >> scalar[op( qi::_val, qi::_1, 'z' )];
442 }
443 // ----------------------------------------------------------------------------
444 qi::rule<Iterator, ResultT(), Skipper> point, list;
445 typename Grammar_<Iterator, Scalar, Skipper>::Grammar scalar;
446 ph::function<Operations> op;
447 // ----------------------------------------------------------------------------
448 }; // Pnt3DGrammar
449 // ----------------------------------------------------------------------------
450 // Register Pnt3DGrammar for ROOT::Math::PositionVector3D:
451 // ----------------------------------------------------------------------------
452 template <typename Iterator, typename T1, typename T2, typename Skipper>
453 struct Grammar_<Iterator, ROOT::Math::PositionVector3D<T1, T2>, Skipper> {
454 typedef Pnt3DGrammar<Iterator, ROOT::Math::PositionVector3D<T1, T2>, Skipper> Grammar;
455 };
456 // ----------------------------------------------------------------------------
457 // Register Pnt3DGrammar for ROOT::Math::DisplacementVector3D:
458 // ----------------------------------------------------------------------------
459 template <typename Iterator, typename T1, typename T2, typename Skipper>
460 struct Grammar_<Iterator, ROOT::Math::DisplacementVector3D<T1, T2>, Skipper> {
461 typedef Pnt3DGrammar<Iterator, ROOT::Math::DisplacementVector3D<T1, T2>, Skipper> Grammar;
462 };
463 // ============================================================================
464 template <typename Iterator, typename PointT, typename Skipper>
465 struct Pnt4DGrammar : qi::grammar<Iterator, PointT(), Skipper> {
466 typedef PointT ResultT;
467 typedef typename PointT::Scalar ScalarT;
468 //-----------------------------------------------------------------------------
469 struct Operations {
470
471 void operator()( ResultT& res, const ScalarT& scalar, const char xyz ) const
472 {
473 switch ( xyz ) {
474 case 'x':
475 res.SetPx( scalar );
476 break;
477 case 'y':
478 res.SetPy( scalar );
479 break;
480 case 'z':
481 res.SetPz( scalar );
482 break;
483 case 'e':
484 res.SetE( scalar );
485 break;
486 default:
487 break;
488 }
489 }
490 void operator()( ResultT& res, const ResultT& xyz ) const
491 {
492 res.SetPx( xyz.Px() );
493 res.SetPy( xyz.Py() );
494 res.SetPz( xyz.Pz() );
495 }
496 }; // Operations
497 // ----------------------------------------------------------------------------
498 Pnt4DGrammar() : Pnt4DGrammar::base_type( point4d )
499 {
500 point4d = list4d | ( '(' >> list4d >> ')' ) | ( '[' >> list4d >> ']' );
501 list4d = ( point3d[op( qi::_val, qi::_1 )] >> enc::char_( ";," ) >> e[op( qi::_val, qi::_1, 'e' )] ) |
502 ( e[op( qi::_val, qi::_1, 'e' )] >> enc::char_( ";," ) >> point3d[op( qi::_val, qi::_1 )] );
503 e = -( enc::no_case[enc::char_( "te" )] >> ':' ) >> scalar[qi::_val = qi::_1];
504
505 point3d = list3d | ( '(' >> list3d >> ')' ) | ( '[' >> list3d >> ']' );
506 list3d = -( enc::no_case[qi::lit( "x" ) | qi::lit( "px" )] >> ':' ) >> scalar[op( qi::_val, qi::_1, 'x' )] >>
507 ',' >> -( enc::no_case[qi::lit( "y" ) | qi::lit( "py" )] >> ':' ) >>
508 scalar[op( qi::_val, qi::_1, 'y' )] >> ',' >>
509 -( enc::no_case[qi::lit( "z" ) | qi::lit( "pz" )] >> ':' ) >> scalar[op( qi::_val, qi::_1, 'z' )];
510 }
511 // ----------------------------------------------------------------------------
512 qi::rule<Iterator, ResultT(), Skipper> point3d, point4d, list3d, list4d;
513 qi::rule<Iterator, ScalarT(), Skipper> e;
514 typename Grammar_<Iterator, ScalarT, Skipper>::Grammar scalar;
515 ph::function<Operations> op;
516 // ----------------------------------------------------------------------------
517 }; // Pnt4DGrammar
518 // ----------------------------------------------------------------------------
519 // Register Pnt4DGrammar for ROOT::Math::LorentzVector:
520 // ----------------------------------------------------------------------------
521 template <typename Iterator, typename T1, typename Skipper>
522 struct Grammar_<Iterator, ROOT::Math::LorentzVector<T1>, Skipper> {
523 typedef Pnt4DGrammar<Iterator, ROOT::Math::LorentzVector<T1>, Skipper> Grammar;
524 };
525 // ============================================================================
526 template <typename Iterator, typename Skipper>
527 struct Histo1DGrammar : qi::grammar<Iterator, Gaudi::Histo1DDef(), qi::locals<char>, Skipper> {
528 typedef Gaudi::Histo1DDef ResultT;
529 // ----------------------------------------------------------------------------
530 struct Operations {
531 void operator()( ResultT& res, const std::string& title ) const { res.setTitle( title ); }
532 void operator()( ResultT& res, const double& val, const char lh ) const
533 {
534 switch ( lh ) {
535 case 'l':
536 res.setLowEdge( val );
537 break;
538 case 'h':
539 res.setHighEdge( val );
540 break;
541 default:
542 break;
543 }
544 }
545 void operator()( ResultT& res, int val ) const { res.setBins( val ); }
546 void operator()( ResultT& res ) const {}
547 }; // Operations
548 // ----------------------------------------------------------------------------
549 Histo1DGrammar() : Histo1DGrammar::base_type( hist )
550 {
551 val1 = title[op( qi::_val, qi::_1 )] >> ',' >> qi::double_[op( qi::_val, qi::_1, 'l' )] >> ',' >>
552 qi::double_[op( qi::_val, qi::_1, 'h' )] >> -( ',' >> qi::int_[op( qi::_val, qi::_1 )] );
553 val2 = qi::double_[op( qi::_val, qi::_1, 'l' )] >> ',' >> qi::double_[op( qi::_val, qi::_1, 'h' )] >> ',' >>
554 title[op( qi::_val, qi::_1 )] >> -( ',' >> qi::int_[op( qi::_val, qi::_1 )] );
555 val3 = qi::double_[op( qi::_val, qi::_1, 'l' )] >> ',' >> qi::double_[op( qi::_val, qi::_1, 'h' )] >>
556 -( ',' >> title[op( qi::_val, qi::_1 )] ) >> -( ',' >> qi::int_[op( qi::_val, qi::_1 )] );
557 begin = enc::char_( '[' )[qi::_val = ']'] | enc::char_( '(' )[qi::_val = ')'];
558 end = enc::char_( qi::_r1 );
559 hist = begin[qi::_a = qi::_1] >> ( val1 | val2 | val3 )[qi::_val = qi::_1] >> end( qi::_a );
560 }
561 // ----------------------------------------------------------------------------
562 qi::rule<Iterator, ResultT(), qi::locals<char>, Skipper> hist;
563 qi::rule<Iterator, ResultT(), Skipper> val1, val2, val3;
564 qi::rule<Iterator, char()> begin;
565 qi::rule<Iterator, void( char )> end;
566 StringGrammar<Iterator, Skipper> title;
567 ph::function<Operations> op;
568 // ----------------------------------------------------------------------------
569 }; // Histo1DGrammar
570 // ----------------------------------------------------------------------------
571 REGISTER_GRAMMAR( Gaudi::Histo1DDef, Histo1DGrammar );
572 // ============================================================================
573 template <typename Iterator, typename Skipper>
574 struct KeyValueGrammar : qi::grammar<Iterator, std::pair<std::string, std::string>(), Skipper> {
575 //------------------------------------------------------------------------------
576 typedef std::pair<std::string, std::string> ResultT;
577 //------------------------------------------------------------------------------
578 struct first {
579 };
580 struct second {
581 };
582
583 KeyValueGrammar() : KeyValueGrammar::base_type( pair )
584 {
585 //------------------------------------------------------------------------------
586 pair = gstring >> ":" >> +enc::char_;
587 }
588 // ----------------------------------------------------------------------------
589 StringGrammar<Iterator, Skipper> gstring;
590 qi::rule<Iterator, ResultT(), Skipper> pair;
591 // ----------------------------------------------------------------------------
592 }; // END KeyValueGrammar
593 // We don't register KeyalueGrammar because it's a special parser
594 // ============================================================================
595 }
596 } // Gaudi::Parsers
597 //============================================================================
598 #endif
Gaudi::Parsers::PairGrammar::begin
qi::rule< Iterator, char()> begin
Definition: GrammarsV2.h:336
Gaudi::Parsers::CharGrammar::ResultT
char ResultT
Definition: GrammarsV2.h:112
Gaudi::Parsers::Pnt3DGrammar::Pnt3DGrammar
Pnt3DGrammar()
Definition: GrammarsV2.h:435
Gaudi::Parsers::KeyValueGrammar::pair
qi::rule< Iterator, ResultT(), Skipper > pair
Definition: GrammarsV2.h:590
Gaudi::Parsers::Grammar_< Iterator, std::vector< InnerT, AllocatorT >, Skipper >::Grammar
VectorGrammar< Iterator, std::vector< InnerT, AllocatorT >, Skipper > Grammar
Definition: GrammarsV2.h:293
Gaudi::Parsers::BoolGrammar
Definition: Grammar.h:95
Gaudi::Parsers::Histo1DGrammar::val3
qi::rule< Iterator, ResultT(), Skipper > val3
Definition: GrammarsV2.h:563
Gaudi::Parsers::MapGrammar::MapGrammar
MapGrammar()
Definition: GrammarsV2.h:378
Gaudi::Parsers::PairGrammar::first
Definition: GrammarsV2.h:322
Gaudi::Parsers::MapGrammar::list
qi::rule< Iterator, VectorPairT(), Skipper > list
Definition: GrammarsV2.h:389
Gaudi::Parsers::IntGrammar::IntGrammar
IntGrammar()
Definition: GrammarsV2.h:136
Gaudi::Parsers::KeyValueGrammar::gstring
StringGrammar< Iterator, Skipper > gstring
Definition: GrammarsV2.h:589
Gaudi::Parsers::tuple_remove_first_type< std::tuple< T, Ts... > >::type
std::tuple< Ts... > type
Definition: GrammarsV2.h:176
Gaudi::Parsers::PairGrammar::init
void init(const std::string &delimeter)
Definition: GrammarsV2.h:326
Gaudi::Parsers::Grammar_< Iterator, std::map< KeyT, ValueT, KeyCompareT, AllocatorT >, Skipper >::Grammar
MapGrammar< Iterator, std::map< KeyT, ValueT, KeyCompareT, AllocatorT >, Skipper > Grammar
Definition: GrammarsV2.h:400
Gaudi::Parsers::Pnt4DGrammar::Operations::operator()
void operator()(ResultT &res, const ScalarT &scalar, const char xyz) const
Definition: GrammarsV2.h:471
Gaudi::Parsers::TupleGrammar::ResultT
TupleT ResultT
Definition: GrammarsV2.h:243
Gaudi::Parsers::Pnt3DGrammar
Definition: GrammarsV2.h:412
Gaudi::Parsers::Histo1DGrammar::Operations::operator()
void operator()(ResultT &res, const std::string &title) const
Definition: GrammarsV2.h:531
Gaudi::Parsers::Pnt4DGrammar::scalar
Grammar_< Iterator, ScalarT, Skipper >::Grammar scalar
Definition: GrammarsV2.h:514
Gaudi::Parsers::BoolGrammar::ResultT
bool ResultT
Definition: GrammarsV2.h:123
Gaudi::Parsers::Pnt3DGrammar::ResultT
PointT ResultT
Definition: GrammarsV2.h:413
Gaudi::Parsers::PairGrammar::second_type
PairT::second_type second_type
Definition: GrammarsV2.h:316
boost
The namespace threadpool contains a thread pool and related utility classes.
Definition: iter_pos.hpp:13
Gaudi::Parsers::RealGrammar
Definition: Grammar.h:108
Gaudi::Parsers::StringGrammar::ResultT
std::string ResultT
Definition: GrammarsV2.h:90
ROOT
Definition: IMagneticFieldSvc.h:9
Gaudi::Parsers::PairGrammar::key
Grammar_< Iterator, typename PairT::first_type, Skipper >::Grammar key
Definition: GrammarsV2.h:334
Gaudi::Parsers::Pnt3DGrammar::point
qi::rule< Iterator, ResultT(), Skipper > point
Definition: GrammarsV2.h:444
Gaudi::Parsers::Pnt3DGrammar::Operations
Definition: GrammarsV2.h:416
Gaudi::Parsers::Grammar_< Iterator, T, Skipper, typename boost::enable_if< boost::is_floating_point< T > >::type >::Grammar
RealGrammar< Iterator, T, Skipper > Grammar
Definition: GrammarsV2.h:161
Gaudi::Parsers::PairGrammar::pair
qi::rule< Iterator, ResultT(), qi::locals< char >, Skipper > pair
Definition: GrammarsV2.h:338
Gaudi::Parsers::tuple_get_first_type
Definition: GrammarsV2.h:171
Gaudi::Parsers::RealGrammar::ResultT
RT ResultT
Definition: GrammarsV2.h:152
Gaudi::Parsers::VectorGrammar::ResultT
VectorT ResultT
Definition: GrammarsV2.h:269
Gaudi::Parsers::TupleGrammar::tup
qi::rule< Iterator, ResultT(), qi::locals< char >, Skipper > tup
Definition: GrammarsV2.h:254
Gaudi::Parsers::IntGrammar
Definition: GrammarsV2.h:134
Gaudi::Parsers::SkipperGrammar::SkipperGrammar
SkipperGrammar()
Definition: GrammarsV2.h:79
Gaudi::Parsers::VectorGrammar::vec
qi::rule< Iterator, ResultT(), qi::locals< char >, Skipper > vec
Definition: GrammarsV2.h:284
Containers::vector
struct GAUDI_API vector
Parametrisation class for vector-like implementation.
Definition: KeyedObjectManager.h:30
Gaudi::Parsers::TupleInnerGrammar< Iterator, TupleT, 1, Skipper >::Operations::operator()
void operator()(ResultT &res, const typename std::tuple_element< 0, ResultT >::type &val) const
Definition: GrammarsV2.h:224
Gaudi::Parsers::Skipper
SkipperGrammar< IteratorT > Skipper
Definition: ParsersFactory.h:30
Gaudi::Parsers::TupleInnerGrammar::tup
qi::rule< Iterator, ResultT(), qi::locals< HeadT >, Skipper > tup
Definition: GrammarsV2.h:212
Gaudi::Parsers::Pnt3DGrammar::op
ph::function< Operations > op
Definition: GrammarsV2.h:446
std
STL namespace.
Gaudi::Parsers::KeyValueGrammar::second
Definition: GrammarsV2.h:580
Gaudi::Parsers::MapGrammar::MappedT
MapT::mapped_type MappedT
Definition: GrammarsV2.h:356
std::vector::end
T end(T...args)
Gaudi::Parsers::Histo1DGrammar::title
StringGrammar< Iterator, Skipper > title
Definition: GrammarsV2.h:566
Gaudi::Parsers::Pnt4DGrammar::ResultT
PointT ResultT
Definition: GrammarsV2.h:466
Gaudi::Parsers::MapGrammar::map
qi::rule< Iterator, ResultT(), Skipper > map
Definition: GrammarsV2.h:390
HashMap.h
boost::spirit
Definition: iter_pos.hpp:13
Gaudi::Parsers::TupleInnerGrammar::grLast
TupleInnerGrammar< Iterator, TailT, N-1, Skipper > grLast
Definition: GrammarsV2.h:209
Gaudi::Parsers::StringGrammar
Definition: Grammar.h:53
Gaudi::Parsers::Histo1DGrammar::Operations::operator()
void operator()(ResultT &res) const
Definition: GrammarsV2.h:546
Gaudi::Parsers::Grammar_::BOOST_MPL_ASSERT_MSG
BOOST_MPL_ASSERT_MSG(false, GRAMMAR_FOR_TYPE_DOES_NOT_EXISTS,(T))
Gaudi::StringKey
The helper class to represent the efficient "key" for access.
Definition: StringKey.h:35
Gaudi::Parsers::MapGrammar::tag_key
Definition: GrammarsV2.h:361
Gaudi::Parsers::Pnt4DGrammar::e
qi::rule< Iterator, ScalarT(), Skipper > e
Definition: GrammarsV2.h:513
begin
auto begin(reverse_wrapper< T > &w)
Definition: reverse.h:58
Gaudi::Parsers::IntGrammar::ResultT
RT ResultT
Definition: GrammarsV2.h:135
Gaudi::Parsers::PairGrammar::PairGrammar
PairGrammar(const std::string &delimeter)
Definition: GrammarsV2.h:320
std::string
STL class.
Gaudi::Parsers::KeyValueGrammar::first
Definition: GrammarsV2.h:578
Gaudi::Parsers::VectorGrammar::elementGrammar
Grammar_< Iterator, typename VectorT::value_type, Skipper >::Grammar elementGrammar
Definition: GrammarsV2.h:280
Gaudi::Parsers::TupleInnerGrammar::grHead
Grammar_< Iterator, HeadT, Skipper >::Grammar grHead
Definition: GrammarsV2.h:210
Gaudi::Parsers::BoolGrammar::BoolGrammar
BoolGrammar()
Definition: GrammarsV2.h:124
Gaudi::Parsers::TupleInnerGrammar
Definition: GrammarsV2.h:187
IOTest.N
int N
Definition: IOTest.py:101
Gaudi::Parsers::Histo1DGrammar::Operations::operator()
void operator()(ResultT &res, const double &val, const char lh) const
Definition: GrammarsV2.h:532
Gaudi::Parsers::Histo1DGrammar::begin
qi::rule< Iterator, char()> begin
Definition: GrammarsV2.h:564
Point3DTypes.h
3D point typedefs
Containers::map
struct GAUDI_API map
Parametrisation class for map-like implementation.
Definition: KeyedObjectManager.h:26
VectorMap.h
Gaudi::Parsers::TupleGrammar::end
qi::rule< Iterator, void(char)> end
Definition: GrammarsV2.h:253
Gaudi::Parsers::Histo1DGrammar::Operations
Definition: GrammarsV2.h:530
Gaudi::Parsers::Histo1DGrammar
Definition: GrammarsV2.h:527
Gaudi::Parsers::TupleGrammar
Definition: GrammarsV2.h:242
Gaudi::Parsers::TupleInnerGrammar< Iterator, TupleT, 1, Skipper >::ResultT
TupleT ResultT
Definition: GrammarsV2.h:219
Gaudi::Parsers::VectorGrammar::VectorGrammar
VectorGrammar()
Definition: GrammarsV2.h:271
Gaudi::Parsers::Pnt4DGrammar
Definition: GrammarsV2.h:465
Gaudi::Parsers::MapGrammar::PairT
std::pair< KeyT, MappedT > PairT
Definition: GrammarsV2.h:357
Gaudi::Parsers::TupleInnerGrammar::op
ph::function< Operations > op
Definition: GrammarsV2.h:213
Gaudi::Parsers::Grammar_< Iterator, ROOT::Math::DisplacementVector3D< T1, T2 >, Skipper >::Grammar
Pnt3DGrammar< Iterator, ROOT::Math::DisplacementVector3D< T1, T2 >, Skipper > Grammar
Definition: GrammarsV2.h:461
Gaudi::Parsers::Grammar_< Iterator, std::list< InnerT, AllocatorT >, Skipper >::Grammar
VectorGrammar< Iterator, std::list< InnerT, AllocatorT >, Skipper > Grammar
Definition: GrammarsV2.h:300
Gaudi::Parsers::PairGrammar::value
Grammar_< Iterator, typename PairT::second_type, Skipper >::Grammar value
Definition: GrammarsV2.h:335
Gaudi::Parsers::KeyValueGrammar::KeyValueGrammar
KeyValueGrammar()
Definition: GrammarsV2.h:583
gaudirun.type
type
Definition: gaudirun.py:133
Gaudi::Parsers::Pnt3DGrammar::Operations::operator()
void operator()(ResultT &res, const Scalar &scalar, const char xyz) const
Definition: GrammarsV2.h:417
Gaudi::Histo1DDef
Simple helper class for description of 1D-histogram The class is targeted to act as the primary "hist...
Definition: HistoDef.h:33
Gaudi::Parsers::Pnt4DGrammar::Operations
Definition: GrammarsV2.h:469
Gaudi::Parsers::Histo1DGrammar::hist
qi::rule< Iterator, ResultT(), qi::locals< char >, Skipper > hist
Definition: GrammarsV2.h:562
Gaudi::Parsers::tuple_remove_first_type
Definition: GrammarsV2.h:167
Gaudi::Parsers::MapGrammar::KeyT
MapT::key_type KeyT
Definition: GrammarsV2.h:355
Gaudi::Parsers::PairGrammar::pair_in
qi::rule< Iterator, ResultT(), Skipper > pair_in
Definition: GrammarsV2.h:339
Gaudi::Parsers::PairGrammar::first_type
PairT::first_type first_type
Definition: GrammarsV2.h:315
Gaudi::Parsers::TupleInnerGrammar::HeadT
tuple_get_first_type< TupleT >::type HeadT
Definition: GrammarsV2.h:192
Gaudi::Parsers::Pnt4DGrammar::point4d
qi::rule< Iterator, ResultT(), Skipper > point4d
Definition: GrammarsV2.h:512
Gaudi::Parsers::Grammar_
Definition: GrammarsV2.h:61
Gaudi::Parsers::TupleInnerGrammar< Iterator, TupleT, 1, Skipper >::TupleInnerGrammar
TupleInnerGrammar()
Definition: GrammarsV2.h:232
Gaudi::Parsers::MapGrammar::pair
qi::rule< Iterator, PairT(), Skipper > pair
Definition: GrammarsV2.h:388
Gaudi::Parsers::Histo1DGrammar::Histo1DGrammar
Histo1DGrammar()
Definition: GrammarsV2.h:549
StringKey.h
Gaudi::Parsers::MapGrammar::tag_mapped
Definition: GrammarsV2.h:363
Gaudi::Parsers::Grammar_< Iterator, GaudiUtils::VectorMap< KeyT, ValueT, KeyCompareT, AllocatorT >, Skipper >::Grammar
MapGrammar< Iterator, GaudiUtils::VectorMap< KeyT, ValueT, KeyCompareT, AllocatorT >, Skipper > Grammar
Definition: GrammarsV2.h:408
end
auto end(reverse_wrapper< T > &w)
Definition: reverse.h:64
Gaudi::Parsers::VectorGrammar::list
qi::rule< Iterator, ResultT(), Skipper > list
Definition: GrammarsV2.h:285
Gaudi::Parsers::Pnt4DGrammar::Pnt4DGrammar
Pnt4DGrammar()
Definition: GrammarsV2.h:498
Gaudi::Parsers::MapGrammar
Definition: GrammarsV2.h:352
Gaudi::Parsers::TupleGrammar::TupleGrammar
TupleGrammar()
Definition: GrammarsV2.h:244
Gaudi::Parsers::DefaultIterator
std::string::const_iterator DefaultIterator
Definition: GrammarsV2.h:57
Gaudi::Parsers::Grammar_< Iterator, T, Skipper, typename boost::enable_if< boost::is_integral< T > >::type >::Grammar
IntGrammar< Iterator, T, Skipper > Grammar
Definition: GrammarsV2.h:147
Gaudi::Parsers::MapGrammar::Operations::operator()
void operator()(PairT &res, const KeyT &key, tag_key) const
Definition: GrammarsV2.h:373
Gaudi::Parsers::PairGrammar::ResultT
PairT ResultT
Definition: GrammarsV2.h:314
Gaudi::Parsers::Grammar_< Iterator, ROOT::Math::LorentzVector< T1 >, Skipper >::Grammar
Pnt4DGrammar< Iterator, ROOT::Math::LorentzVector< T1 >, Skipper > Grammar
Definition: GrammarsV2.h:523
Gaudi::Parsers::SkipperGrammar
Definition: Grammar.h:43
Gaudi::Parsers::MapGrammar::key
Grammar_< Iterator, typename MapT::key_type, Skipper >::Grammar key
Definition: GrammarsV2.h:386
Gaudi::Parsers::Histo1DGrammar::Operations::operator()
void operator()(ResultT &res, int val) const
Definition: GrammarsV2.h:545
Gaudi::Parsers::MapGrammar::ResultT
MapT ResultT
Definition: GrammarsV2.h:354
Gaudi::Parsers::DefaultSkipper
enc::space_type DefaultSkipper
Definition: GrammarsV2.h:58
Gaudi::Parsers::StringGrammar::StringGrammar
StringGrammar()
Definition: GrammarsV2.h:92
std::tuple
std::pair
Gaudi::Parsers::TupleInnerGrammar::ResultT
TupleT ResultT
Definition: GrammarsV2.h:190
Gaudi::Parsers::MapGrammar::VectorPairT
std::vector< PairT > VectorPairT
Definition: GrammarsV2.h:359
Gaudi::Parsers::CharGrammar::CharGrammar
CharGrammar()
Definition: GrammarsV2.h:113
Gaudi::Parsers::VectorGrammar::end
qi::rule< Iterator, void(char)> end
Definition: GrammarsV2.h:282
Gaudi::Parsers::Pnt3DGrammar::Scalar
PointT::Scalar Scalar
Definition: GrammarsV2.h:414
std::tuple_cat
T tuple_cat(T...args)
Gaudi::Parsers::TupleInnerGrammar::Operations
Definition: GrammarsV2.h:194
Gaudi::Parsers::BoolGrammar::boolean_literal
qi::rule< Iterator, bool(), Skipper > boolean_literal
Definition: GrammarsV2.h:129
std::vector
STL class.
Gaudi::Parsers::RealGrammar::RealGrammar
RealGrammar()
Definition: GrammarsV2.h:153
Gaudi::Parsers::tuple_get_first_type< std::tuple< T, Ts... > >::type
T type
Definition: GrammarsV2.h:181
Gaudi::Parsers::MapGrammar::Operations
Definition: GrammarsV2.h:365
Iterator
boost::spirit::classic::position_iterator2< ForwardIterator > Iterator
Definition: Iterator.h:18
Gaudi::Parsers::Grammar_< Iterator, std::pair< KeyT, ValueT >, Skipper >::Grammar
PairGrammar< Iterator, std::pair< KeyT, ValueT >, Skipper > Grammar
Definition: GrammarsV2.h:348
std::vector::begin
T begin(T...args)
Gaudi::Parsers::MapGrammar::Operations::operator()
void operator()(ResultT &res, const VectorPairT &vec) const
Definition: GrammarsV2.h:367
Gaudi::Parsers::TupleInnerGrammar< Iterator, TupleT, 1, Skipper >::op
ph::function< Operations > op
Definition: GrammarsV2.h:237
Gaudi::Parsers::Pnt4DGrammar::Operations::operator()
void operator()(ResultT &res, const ResultT &xyz) const
Definition: GrammarsV2.h:490
GaudiUtils
Forward declarations for the functions in SerializeSTL.h.
Definition: GaudiHistoID.h:140
Gaudi::Parsers::TupleInnerGrammar::TailT
tuple_remove_first_type< TupleT >::type TailT
Definition: GrammarsV2.h:191
Gaudi::Parsers::CharGrammar::ch
qi::rule< Iterator, char(), Skipper > ch
Definition: GrammarsV2.h:117
Gaudi::Parsers::TupleGrammar::grTuple
TupleInnerGrammar< Iterator, TupleT, N, Skipper > grTuple
Definition: GrammarsV2.h:255
Gaudi::Parsers::PairGrammar::PairGrammar
PairGrammar()
Definition: GrammarsV2.h:318
Gaudi::Parsers::Histo1DGrammar::end
qi::rule< Iterator, void(char)> end
Definition: GrammarsV2.h:565
Gaudi::Parsers::TupleInnerGrammar::TupleInnerGrammar
TupleInnerGrammar()
Definition: GrammarsV2.h:204
Gaudi::Parsers::PairGrammar
Definition: GrammarsV2.h:312
Gaudi::Parsers::TupleInnerGrammar< Iterator, TupleT, 1, Skipper >::grFirst
Grammar_< Iterator, typename std::tuple_element< 0, ResultT >::type, Skipper >::Grammar grFirst
Definition: GrammarsV2.h:234
Gaudi::Parsers::VectorGrammar::begin
qi::rule< Iterator, char()> begin
Definition: GrammarsV2.h:281
Gaudi::Parsers::MapGrammar::op
ph::function< Operations > op
Definition: GrammarsV2.h:391
Gaudi::Parsers::Grammar_< Iterator, ROOT::Math::PositionVector3D< T1, T2 >, Skipper >::Grammar
Pnt3DGrammar< Iterator, ROOT::Math::PositionVector3D< T1, T2 >, Skipper > Grammar
Definition: GrammarsV2.h:454
Gaudi::Parsers::Grammar_< Iterator, std::set< InnerT, CompareT, AllocatorT >, Skipper >::Grammar
VectorGrammar< Iterator, std::set< InnerT, CompareT, AllocatorT >, Skipper > Grammar
Definition: GrammarsV2.h:307
Gaudi::Parsers::PairGrammar::second
Definition: GrammarsV2.h:324
Point4DTypes.h
4D point typedefs
Gaudi::Parsers::MapGrammar::value
Grammar_< Iterator, typename MapT::mapped_type, Skipper >::Grammar value
Definition: GrammarsV2.h:387
Gaudi::Parsers::RealGrammar::real
qi::rule< Iterator, RT(), Skipper > real
Definition: GrammarsV2.h:154
Gaudi::Parsers::IntGrammar::integer
qi::rule< Iterator, RT(), Skipper > integer
Definition: GrammarsV2.h:140
Gaudi::Parsers::TupleInnerGrammar::Operations::operator()
void operator()(ResultT &res, HeadT &head, TailT &tail) const
Definition: GrammarsV2.h:197
Gaudi::Parsers::CharGrammar
Definition: GrammarsV2.h:111
Gaudi::Parsers::TupleGrammar::begin
qi::rule< Iterator, char()> begin
Definition: GrammarsV2.h:252
Gaudi::Parsers::PairGrammar::end
qi::rule< Iterator, void(char)> end
Definition: GrammarsV2.h:337
Gaudi::Parsers::KeyValueGrammar
Definition: GrammarsV2.h:574
Gaudi::Parsers::MapGrammar::Operations::operator()
void operator()(PairT &res, const MappedT &value, tag_mapped) const
Definition: GrammarsV2.h:374
Gaudi
Helper functions to set/get the application return code.
Definition: __init__.py:1
Gaudi::Parsers::Histo1DGrammar::ResultT
Gaudi::Histo1DDef ResultT
Definition: GrammarsV2.h:528
Gaudi::Parsers::KeyValueGrammar::ResultT
std::pair< std::string, std::string > ResultT
Definition: GrammarsV2.h:576
Gaudi::Parsers::Pnt4DGrammar::op
ph::function< Operations > op
Definition: GrammarsV2.h:515
Gaudi::Parsers::TupleInnerGrammar< Iterator, TupleT, 1, Skipper >::tup
qi::rule< Iterator, ResultT(), Skipper > tup
Definition: GrammarsV2.h:236
Gaudi::Parsers::VectorGrammar
Definition: GrammarsV2.h:267
Gaudi::Parsers::Pnt4DGrammar::ScalarT
PointT::Scalar ScalarT
Definition: GrammarsV2.h:467
Gaudi::Parsers::Pnt3DGrammar::scalar
Grammar_< Iterator, Scalar, Skipper >::Grammar scalar
Definition: GrammarsV2.h:445
HistoDef.h
Gaudi::Parsers::Histo1DGrammar::op
ph::function< Operations > op
Definition: GrammarsV2.h:567
Gaudi::Parsers::REGISTER_GRAMMAR
REGISTER_GRAMMAR(GaudiMath::Interpolation::Type, InterpolGrammar)