diff --git a/MantleAPI/include/MantleAPI/Execution/i_environment.h b/MantleAPI/include/MantleAPI/Execution/i_environment.h index bbd668623bd6b52eecabe34b2579f3febb15304f..86f1f04e9df3d54b7960392661261d7f2d8273f0 100644 --- a/MantleAPI/include/MantleAPI/Execution/i_environment.h +++ b/MantleAPI/include/MantleAPI/Execution/i_environment.h @@ -21,6 +21,7 @@ #include <MantleAPI/EnvironmentalConditions/weather.h> #include <MantleAPI/Map/i_coord_converter.h> #include <MantleAPI/Map/i_lane_location_query_service.h> +#include <MantleAPI/Map/map_details.h> #include <MantleAPI/Traffic/i_entity_repository.h> #include <string> @@ -37,7 +38,7 @@ class IEnvironment /// /// @param file_path map file path from the scenario file. If this path is not resolved by the engine, the /// environment must do so. - virtual void CreateMap(const std::string& map_file_path, const std::vector<Position>& map_region) = 0; + virtual void CreateMap(const std::string& map_file_path, const mantle_api::MapDetails* map_details) = 0; /// Creates a controller from the given config. A created controller can be assigned to multiple entities /// diff --git a/MantleAPI/include/MantleAPI/Map/map_details.h b/MantleAPI/include/MantleAPI/Map/map_details.h new file mode 100644 index 0000000000000000000000000000000000000000..0233cdf2a63fad6db3b3a4b889198a4bec9e3b84 --- /dev/null +++ b/MantleAPI/include/MantleAPI/Map/map_details.h @@ -0,0 +1,34 @@ +/******************************************************************************* + * Copyright (c) 2021, Bayerische Motoren Werke Aktiengesellschaft (BMW AG) + * + * This program and the accompanying materials are made + * available under the terms of the Eclipse Public License 2.0 + * which is available at https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + *******************************************************************************/ + +//----------------------------------------------------------------------------- +/** @file map_details.h */ +//----------------------------------------------------------------------------- + +#ifndef MANTLEAPI_MAP_MAPDETAILS_H +#define MANTLEAPI_MAP_MAPDETAILS_H + +#include <MantleAPI/Common/position.h> + +#include <vector> + +namespace mantle_api +{ + +struct MapDetails +{ + virtual ~MapDetails() = default; + + std::vector<Position> map_region; +}; + +} // namespace mantle_api + +#endif // MANTLEAPI_MAP_MAPDETAILS_H diff --git a/MantleAPI/test/MantleAPI/Test/test_utils.h b/MantleAPI/test/MantleAPI/Test/test_utils.h index ef91d049fb9dd354e1dd94795c558a681dabc420..2dc30a8d5d3277a7873e38da50982c6cdb4ebb47 100644 --- a/MantleAPI/test/MantleAPI/Test/test_utils.h +++ b/MantleAPI/test/MantleAPI/Test/test_utils.h @@ -301,7 +301,7 @@ class MockEnvironment : public mantle_api::IEnvironment public: MOCK_METHOD(void, CreateMap, - (const std::string& file_path, const std::vector<mantle_api::Position>& map_region), + (const std::string& file_path, const mantle_api::MapDetails* map_details), (override) );