15 #ifndef OPENSCENARIO_INTERPRETER__SYNTAX__PROPERTIES_HPP_
16 #define OPENSCENARIO_INTERPRETER__SYNTAX__PROPERTIES_HPP_
21 #include <pugixml.hpp>
22 #include <unordered_map>
26 inline namespace syntax
64 auto get(
const String & name,
const T & default_value)
const ->
auto
67 if (
const auto [name, property] = *iter; not
property.value.empty()) {
68 return boost::lexical_cast<T>(property.value);
80 return get<T>(name, T());
Definition: scope.hpp:154
std::string String
Definition: string.hpp:24
Definition: escape_sequence.hpp:22
Definition: properties.hpp:42
auto get(const String &name, const T &default_value) const -> auto
Definition: properties.hpp:64
auto get(const String &name) const -> auto
Definition: properties.hpp:78
std::unordered_map< String, Property > properties
Definition: properties.hpp:48
std::list< File > files
Definition: properties.hpp:57