47 lines
1.1 KiB
C++
47 lines
1.1 KiB
C++
#pragma once
|
|
|
|
|
|
#include "SimCore/Identifier.hpp"
|
|
#include "SimCore/IdentifierMaker.hpp"
|
|
#include "SimCore/Messages/SimTrack.hpp"
|
|
#include "nlohmann/json.hpp"
|
|
#include <atomic>
|
|
#include <cstddef>
|
|
#include <list>
|
|
#include <memory>
|
|
|
|
#include <SimCore/Position.hpp>
|
|
#include <SimCore/SafeMap.hpp>
|
|
// #include <Entities/Tracklist/TracklistItem.hpp>
|
|
#include <string>
|
|
#include <thread>
|
|
#include <loguru.hpp>
|
|
|
|
namespace TrackList
|
|
{
|
|
|
|
class TrackList
|
|
{
|
|
public:
|
|
TrackList();
|
|
void addTrack(std::shared_ptr<SimCore::SimTrack> Track);
|
|
std::shared_ptr<SimCore::SimTrack> getTrack(SimCore::Identifier);
|
|
|
|
void deleteTrack(std::string ID);
|
|
void deleteTrack(SimCore::Identifier);
|
|
std::shared_ptr<SimCore::SimTrack> getTrackBySringID(std::string ID);
|
|
|
|
size_t getSize();
|
|
|
|
void getJsonTRackList(nlohmann::json &message);
|
|
|
|
|
|
private:
|
|
mutable std::mutex mx_;
|
|
std::map<std::string, std::shared_ptr<SimCore::SimTrack>> TrackStore_;
|
|
|
|
|
|
};
|
|
|
|
|
|
} |