scenario_simulator_v2 C++ API
private.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__PRIVATE_HPP_
16 #define OPENSCENARIO_INTERPRETER__SYNTAX__PRIVATE_HPP_
17 
18 #include <boost/json.hpp>
22 #include <pugixml.hpp>
23 
25 {
26 inline namespace syntax
27 {
28 /* ---- Private ----------------------------------------------------------------
29  *
30  * <xsd:complexType name="Private">
31  * <xsd:sequence>
32  * <xsd:element name="PrivateAction" type="PrivateAction" maxOccurs="unbounded"/>
33  * </xsd:sequence>
34  * <xsd:attribute name="entityRef" type="String" use="required"/>
35  * </xsd:complexType>
36  *
37  * -------------------------------------------------------------------------- */
38 struct Private : public Scope
39 {
41 
42  std::list<PrivateAction> private_actions;
43 
44  explicit Private(const pugi::xml_node &, Scope &);
45 
46  auto accomplished() const -> bool;
47 
48  auto endsImmediately() const -> bool;
49 
50  auto run() -> void;
51 
52  auto runInstantaneousActions() -> void;
53 
54  auto runNonInstantaneousActions() -> void;
55 
56  auto start() -> void;
57 
58  auto startInstantaneousActions() -> void;
59 
60  auto startNonInstantaneousActions() -> void;
61 };
62 
63 auto operator<<(boost::json::object &, const Private &) -> boost::json::object &;
64 } // namespace syntax
65 } // namespace openscenario_interpreter
66 
67 #endif // OPENSCENARIO_INTERPRETER__SYNTAX__PRIVATE_HPP_
Definition: scope.hpp:154
Definition: escape_sequence.hpp:22
Definition: private.hpp:39
auto run() -> void
Definition: private.cpp:48
auto accomplished() const -> bool
Definition: private.cpp:34
std::list< PrivateAction > private_actions
Definition: private.hpp:42
auto runNonInstantaneousActions() -> void
Definition: private.cpp:59
auto runInstantaneousActions() -> void
Definition: private.cpp:50
auto start() -> void
Definition: private.cpp:68
const Entity entity_ref
Definition: private.hpp:40
auto startInstantaneousActions() -> void
Definition: private.cpp:70
auto endsImmediately() const -> bool
Definition: private.cpp:41
auto startNonInstantaneousActions() -> void
Definition: private.cpp:79
Private(const pugi::xml_node &, Scope &)
Definition: private.cpp:24