|
Gaudi Framework, version v21r8 |
| Home | Generated: 17 Mar 2010 |
1 cm = 10 1 m = 1000 .
More...
#include <ParserGrammar.h>
Public Member Functions | |
| UnitsFileGrammar (Parser *parser) | |
| Constructor. | |
| void | matchUnit () const |
| Action called when matched unit definition. | |
| void | matchLeftReal (double real) const |
| Action called when number matched in left part of definition. | |
| void | matchLeftUnit (std::string newunit) const |
| Action called when new unit name matched. | |
| void | matchRight (std::string value) const |
| Action called when right part number (possible with unit) matched. | |
| Parser * | parser () const |
| Pointer to parser. | |
Private Attributes | |
| Parser * | m_parser |
Classes | |
| struct | definition |
1 cm = 10 1 m = 1000 .
Definition at line 214 of file ParserGrammar.h.
| Gaudi::Parsers::UnitsFileGrammar::UnitsFileGrammar | ( | Parser * | parser | ) | [inline] |
Constructor.
| parser | Pointer to parser object |
Definition at line 224 of file ParserGrammar.h.
| void Gaudi::Parsers::UnitsFileGrammar::matchUnit | ( | ) | const [inline] |
Action called when matched unit definition.
Definition at line 228 of file ParserGrammar.h.
00229 { 00230 file_position fpos = val().get_position(); 00231 m_parser->matchUnitEntry 00232 (attrs().get<0>(),attrs().get<1>(), 00233 Position(fpos.file,fpos.line,fpos.column)); 00234 attrs().get<1>() = 1; 00235 }
| void Gaudi::Parsers::UnitsFileGrammar::matchLeftReal | ( | double | real | ) | const [inline] |
Action called when number matched in left part of definition.
| real | Matched number |
Definition at line 240 of file ParserGrammar.h.
| void Gaudi::Parsers::UnitsFileGrammar::matchLeftUnit | ( | std::string | newunit | ) | const [inline] |
Action called when new unit name matched.
| newunit | Matched name |
Definition at line 247 of file ParserGrammar.h.
| void Gaudi::Parsers::UnitsFileGrammar::matchRight | ( | std::string | value | ) | const [inline] |
Action called when right part number (possible with unit) matched.
| value | String representation of number |
Definition at line 254 of file ParserGrammar.h.
00255 { attrs().get<1>() = 00256 boost::lexical_cast<double>(value)/attrs().get<1>(); }
| Parser* Gaudi::Parsers::UnitsFileGrammar::parser | ( | ) | const [inline] |
Parser* Gaudi::Parsers::UnitsFileGrammar::m_parser [private] |
Definition at line 282 of file ParserGrammar.h.