scenario_simulator_v2 C++ API
user_defined_distribution.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__USER_DEFINED_DISTRIBUTION_HPP_
16 #define OPENSCENARIO_INTERPRETER__SYNTAX__USER_DEFINED_DISTRIBUTION_HPP_
17 
19 #include <pugixml.hpp>
20 
22 {
23 inline namespace syntax
24 {
25 /*
26  UserDefinedDistribution (OpenSCENARIO XML 1.3.1)
27 
28  Indicates a user defined distribution which can be deterministic or stochastic.
29  This distribution contains a property with the name type and some user defined content.
30 
31  <xsd:complexType name="UserDefinedDistribution">
32  <xsd:simpleContent>
33  <xsd:extension base="xsd:string">
34  <xsd:attribute name="type" type="String" use="required"/>
35  </xsd:extension>
36  </xsd:simpleContent>
37  </xsd:complexType>
38 */
39 struct UserDefinedDistribution : private Scope, public ComplexType
40 {
41  const String type;
42 
43  explicit UserDefinedDistribution(const pugi::xml_node &, const Scope &);
44 
45  // TODO: implement evaluate()?`
46 };
47 } // namespace syntax
48 } // namespace openscenario_interpreter
49 
50 #endif // OPENSCENARIO_INTERPRETER__SYNTAX__USER_DEFINED_DISTRIBUTION_HPP_
Definition: scope.hpp:154
std::string String
Definition: string.hpp:24
Definition: hypot.hpp:22
Definition: user_defined_distribution.hpp:40
const String type
Definition: user_defined_distribution.hpp:41
UserDefinedDistribution(const pugi::xml_node &, const Scope &)
Definition: user_defined_distribution.cpp:23