scenario_simulator_v2 C++ API
dynamic_constraints.hpp
Go to the documentation of this file.
1 // Copyright 2015 TIER IV, Inc. All rights reserved.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 #ifndef OPENSCENARIO_INTERPRETER__SYNTAX__DYNAMIC_CONSTRAINTS_HPP_
16 #define OPENSCENARIO_INTERPRETER__SYNTAX__DYNAMIC_CONSTRAINTS_HPP_
17 
20 #include <pugixml.hpp>
21 #include <traffic_simulator_msgs/msg/dynamic_constraints.hpp>
22 
24 {
25 inline namespace syntax
26 {
27 /* ---- DynamicConstraints 1.2 -------------------------------------------------
28  *
29  * <xsd:complexType name="DynamicConstraints">
30  * <xsd:attribute name="maxAcceleration" type="Double"/>
31  * <xsd:attribute name="maxAccelerationRate" type="Double"/>
32  * <xsd:attribute name="maxDeceleration" type="Double"/>
33  * <xsd:attribute name="maxDecelerationRate" type="Double"/>
34  * <xsd:attribute name="maxSpeed" type="Double"/>
35  * </xsd:complexType>
36  *
37  * syntax `Vehicle.Performance` has exactly the same elements as
38  * this syntax `DynamicConstraints`, but `Vehicle.Performance` expresses the
39  * maximum design performance of the vehicle, whereas `DynamicConstraints`
40  * expresses how much of it the driver is allowed to use.
41  *
42  * -------------------------------------------------------------------------- */
44 {
46 
48 
50 
52 
54 
55  explicit DynamicConstraints(
61 
62  explicit DynamicConstraints(const pugi::xml_node &, Scope &);
63 
64  explicit operator traffic_simulator_msgs::msg::DynamicConstraints() const;
65 };
66 } // namespace syntax
67 } // namespace openscenario_interpreter
68 
69 #endif // OPENSCENARIO_INTERPRETER__SYNTAX__DYNAMIC_CONSTRAINTS_HPP_
Definition: scope.hpp:154
Definition: escape_sequence.hpp:22
static auto infinity() noexcept -> Double
Definition: double.cpp:39
Definition: dynamic_constraints.hpp:44
DynamicConstraints(const Double max_acceleration=Double::infinity(), const Double max_acceleration_rate=Double::infinity(), const Double max_deceleration=Double::infinity(), const Double max_deceleration_rate=Double::infinity(), const Double max_speed=Double::infinity())
Definition: dynamic_constraints.cpp:22
const Double max_acceleration
Definition: dynamic_constraints.hpp:45
const Double max_acceleration_rate
Definition: dynamic_constraints.hpp:47
const Double max_speed
Definition: dynamic_constraints.hpp:53
const Double max_deceleration_rate
Definition: dynamic_constraints.hpp:51
const Double max_deceleration
Definition: dynamic_constraints.hpp:49