WSF
WsfSensorCoverage.hpp
Go to the documentation of this file.
1// ****************************************************************************
2// CUI
3//
4// The Advanced Framework for Simulation, Integration, and Modeling (AFSIM)
5//
6// Copyright 2020 Infoscitex, a DCS Company. All rights reserved.
7//
8// The use, dissemination or disclosure of data in this file is subject to
9// limitation or restriction. See accompanying README and LICENSE for details.
10// ****************************************************************************
11
12#ifndef WSFSENSORCOVERAGE_HPP
13#define WSFSENSORCOVERAGE_HPP
14
15#include "WsfCoverage.hpp"
16
17class WsfSensor;
18class WsfSensorResult;
19
20namespace wsf
21{
22namespace coverage
23{
24
27{
28public:
29 explicit SensorCoverage(const WsfScenario& aScenario)
30 : Coverage(aScenario)
31 {
33 }
34
35 SensorCoverage(const SensorCoverage& aOther) = default;
36 ~SensorCoverage() override = default;
37
38 // WsfObject overrides
39 SensorCoverage* Clone() const override { return new SensorCoverage{*this}; }
40
41 constexpr static const char* cTYPE{"WSF_SENSOR_COVERAGE"};
42
43private:
44 bool InitializeP(WsfSimulation& aSimulation) override;
45 bool AreNullDevicesAllowed(bool aGridAssetNull,
46 bool aAllGridAssetsNull,
47 bool aFreeAssetNull,
48 bool aAllFreeAssetsNull) const override;
49 bool VerifyDeviceP(const WsfPlatform& aPlatform, const std::string& aDeviceName) const override;
50 bool VerifyDeviceAndType(const WsfPlatform& aPlatform,
51 const std::string& aDeviceName,
52 const std::string& aDeviceType) const override;
53 void PendingStartP(WsfSimulation& aSimulation) override;
54
55 void OnSensorDetectionChanged(double aSimTime, WsfSensor* aDetectorPtr, std::size_t aDetectedIndex, WsfSensorResult& aResult);
56 void ProcessInterval(bool aIntervalStart,
57 double aSimTime,
58 const std::string& aFreeAssetPlatformName,
59 const std::string& aFreeAssetDeviceName,
60 const std::string& aGridAssetPlatformName,
61 const std::string& aGridAssetDeviceName);
62};
63
64} // namespace coverage
65} // namespace wsf
66
67#endif // WSFSENSORCOVERAGE_HPP
void SetType(WsfStringId aType)
Definition WsfObject.cpp:172
Platforms represent a entity within the simulation.
Definition WsfPlatform.hpp:115
Contains the data required to create a simulation, and acts as the entry point for input file process...
Definition WsfScenario.hpp:111
Definition WsfSensorResult.hpp:27
Definition WsfSensor.hpp:92
The main controller for a simulation.
Definition WsfSimulation.hpp:109
Coverage(const WsfScenario &aScenario)
Definition WsfCoverage.hpp:59
~SensorCoverage() override=default
SensorCoverage * Clone() const override
Definition WsfSensorCoverage.hpp:39
static constexpr const char * cTYPE
Definition WsfSensorCoverage.hpp:41
SensorCoverage(const WsfScenario &aScenario)
Definition WsfSensorCoverage.hpp:29
SensorCoverage(const SensorCoverage &aOther)=default
Definition WsfCoverage.cpp:35
Function definitions for those who need run-time access to the version.
Definition WsfComm.cpp:32
Copyrights Multiple, All Rights Reserved