Browse Source

add the stands of GrPlugin and TST

Sven Czarnian 3 years ago
parent
commit
2cc7c401e8
1 changed files with 9 additions and 0 deletions
  1. 9 0
      src/PlugIn.cpp

+ 9 - 0
src/PlugIn.cpp

@@ -334,6 +334,15 @@ void PlugIn::generateAircraftReportMessage(const EuroScopePlugIn::CRadarTarget&
         report->set_distancetoiaf(static_cast<int>(std::round(distanceToIaf)));
     }
     report->set_destination(std::string(destination));
+
+    /* support GrPlugin and TST with the stand association */
+    if (nullptr != radarTarget.GetCorrelatedFlightPlan().GetControllerAssignedData().GetFlightStripAnnotation(6)) {
+        std::string stand(radarTarget.GetCorrelatedFlightPlan().GetControllerAssignedData().GetFlightStripAnnotation(6));
+        auto split = String::splitString(stand, "/");
+        if (3 == split.size() && "s" == gsl::at(split, 0) && "s" == gsl::at(split, 2))
+            report->set_plannedgate(gsl::at(split, 1));
+    }
+
     report->set_allocated_aircraft(aircraft);
     report->set_allocated_dynamics(dynamics);
     report->set_allocated_position(coordinate);