15#include "External/nlohmann/json.hpp"
Système de journalisation à 5 niveaux de trace, un fichier par moteur.
Modèle de domaine d'un bloc de voie droite (Straight).
Modèle de domaine d'un aiguillage ferroviaire à 3 branches.
nlohmann::json JsonDocument
Definition TopologyRenderer.h:17
Definition StraightBlock.h:24
Definition SwitchBlock.h:41
Utilitaire statique d'export de la topologie ferroviaire en GeoJSON.
Definition TopologyRenderer.h:33
static std::wstring renderSwitchBlock(const SwitchBlock &sw)
Construit l'appel JS renderSwitch(id, lat, lon, isDouble).
Definition TopologyRenderer.cpp:315
static JsonDocument convertStraightToFeature(const StraightBlock &straight)
Convertit un StraightBlock en feature GeoJSON de type LineString.
Definition TopologyRenderer.cpp:130
static std::wstring loadGeoJsonToWebView()
Génère le script JavaScript d'injection GeoJSON dans le WebView.
Definition TopologyRenderer.cpp:213
static void exportToFile(const std::string &outputPath)
Exporte la topologie ferroviaire dans un fichier GeoJSON.
Definition TopologyRenderer.cpp:188
static std::wstring renderStraightBlock(const StraightBlock &straightBlock)
Construit l'appel JS renderStraightBlock(id, Coordinates) pour un bloc.
Definition TopologyRenderer.cpp:289
TopologyRenderer()=delete
static std::wstring renderSwitchBranches(const SwitchBlock &sw)
Construit l'appel JS renderSwitchBranches(...) pour un switch.
Definition TopologyRenderer.cpp:332
static JsonDocument convertSwitchToFeature(const SwitchBlock &switchBlock)
Convertit un SwitchBlock en feature GeoJSON de type Point.
Definition TopologyRenderer.cpp:157
static std::wstring renderAllTopology()
Génère le script JS complet de rendu de toute la topologie.
Definition TopologyRenderer.cpp:257
static std::wstring escapeForJavaScript(const std::string &input)
Échappe une chaîne JSON pour l'injection dans JavaScript.
Definition TopologyRenderer.cpp:233
static std::wstring updateSwitchBlocks(const SwitchBlock &sw)
Génère le script JS de mise à jour visuelle d'un switch et ses partenaires.
Definition TopologyRenderer.cpp:393