|
15 | 15 | #pragma once |
16 | 16 |
|
17 | 17 | #include "ros2_medkit_gateway/core/discovery/discovery_enums.hpp" |
| 18 | +#include "ros2_medkit_gateway/core/discovery/entity_discovery.hpp" |
18 | 19 | #include "ros2_medkit_gateway/core/discovery/layers/manifest_layer.hpp" |
19 | 20 | #include "ros2_medkit_gateway/core/discovery/merge_types.hpp" |
20 | 21 | #include "ros2_medkit_gateway/core/discovery/models/app.hpp" |
@@ -144,7 +145,7 @@ struct DiscoveryConfig { |
144 | 145 | * @see discovery::MergePipeline |
145 | 146 | * @see discovery::ManifestManager |
146 | 147 | */ |
147 | | -class DiscoveryManager : public ServiceActionResolver { |
| 148 | +class DiscoveryManager : public ServiceActionResolver, public EntityDiscovery { |
148 | 149 | public: |
149 | 150 | /** |
150 | 151 | * @brief Construct the discovery manager |
@@ -226,28 +227,28 @@ class DiscoveryManager : public ServiceActionResolver { |
226 | 227 | * @param id Area identifier |
227 | 228 | * @return Area if found |
228 | 229 | */ |
229 | | - std::optional<Area> get_area(const std::string & id); |
| 230 | + std::optional<Area> get_area(const std::string & id) override; |
230 | 231 |
|
231 | 232 | /** |
232 | 233 | * @brief Get component by ID |
233 | 234 | * @param id Component identifier |
234 | 235 | * @return Component if found |
235 | 236 | */ |
236 | | - std::optional<Component> get_component(const std::string & id); |
| 237 | + std::optional<Component> get_component(const std::string & id) override; |
237 | 238 |
|
238 | 239 | /** |
239 | 240 | * @brief Get app by ID |
240 | 241 | * @param id App identifier |
241 | 242 | * @return App if found |
242 | 243 | */ |
243 | | - std::optional<App> get_app(const std::string & id); |
| 244 | + std::optional<App> get_app(const std::string & id) override; |
244 | 245 |
|
245 | 246 | /** |
246 | 247 | * @brief Get function by ID |
247 | 248 | * @param id Function identifier |
248 | 249 | * @return Function if found |
249 | 250 | */ |
250 | | - std::optional<Function> get_function(const std::string & id); |
| 251 | + std::optional<Function> get_function(const std::string & id) override; |
251 | 252 |
|
252 | 253 | // ========================================================================= |
253 | 254 | // Relationship queries |
@@ -390,7 +391,7 @@ class DiscoveryManager : public ServiceActionResolver { |
390 | 391 | * default-constructed ManifestConfig in those cases - the same values the |
391 | 392 | * pipeline itself runs with. |
392 | 393 | */ |
393 | | - discovery::ManifestConfig get_manifest_config() const; |
| 394 | + discovery::ManifestConfig get_manifest_config() const override; |
394 | 395 |
|
395 | 396 | /** |
396 | 397 | * @brief Re-read the manifest configuration into the running pipeline |
@@ -424,27 +425,27 @@ class DiscoveryManager : public ServiceActionResolver { |
424 | 425 | * @brief Get current discovery mode |
425 | 426 | * @return Active discovery mode |
426 | 427 | */ |
427 | | - DiscoveryMode get_mode() const { |
| 428 | + DiscoveryMode get_mode() const override { |
428 | 429 | return config_.mode; |
429 | 430 | } |
430 | 431 |
|
431 | 432 | /** |
432 | 433 | * @brief Get a human-readable name for the active discovery configuration. |
433 | 434 | * @return One of "runtime", "manifest", "hybrid". |
434 | 435 | */ |
435 | | - std::string get_strategy_name() const; |
| 436 | + std::string get_strategy_name() const override; |
436 | 437 |
|
437 | 438 | /** |
438 | 439 | * @brief Get the last merge pipeline report (hybrid mode only) |
439 | 440 | * @return MergeReport if in hybrid mode, nullopt otherwise |
440 | 441 | */ |
441 | | - std::optional<discovery::MergeReport> get_merge_report() const; |
| 442 | + std::optional<discovery::MergeReport> get_merge_report() const override; |
442 | 443 |
|
443 | 444 | /** |
444 | 445 | * @brief Get the last linking result (hybrid mode only) |
445 | 446 | * @return LinkingResult if in hybrid mode, nullopt otherwise |
446 | 447 | */ |
447 | | - std::optional<discovery::LinkingResult> get_linking_result() const; |
| 448 | + std::optional<discovery::LinkingResult> get_linking_result() const override; |
448 | 449 |
|
449 | 450 | private: |
450 | 451 | /** |
|
0 commit comments