Formula Student Autonomous Systems
The code for the main driverless system
Loading...
Searching...
No Matches
map.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <map>
4#include <memory>
5#include <string>
6
9
10/*
11 * Map of adapters, with the key being the type of the adapter and the value being a lambda function
12 * that creates the adapter
13 */
14const std::map<std::string, std::function<std::shared_ptr<VENode>(const VEParameters&)>,
15 std::less<>>
16 adapter_map = {{"pacsim",
17 [](const VEParameters& params) -> std::shared_ptr<VENode> {
18 return std::make_shared<PacsimAdapter>(params);
19 }},
20 {"vehicle", [](const VEParameters& params) -> std::shared_ptr<VENode> {
21 return std::make_shared<VehicleAdapter>(params);
22 }}};
const std::map< std::string, std::function< std::shared_ptr< ControlNode >(const ControlParameters &)>, std::less<> > adapter_map
Definition map.hpp:18