- training_area_telegrams.cpp: Fixed QJsonObject initializer syntax (Qt6 requires {{}} not ({}))
- training_area_telegrams.cpp: Fixed fromJson() methods to access m_* members directly
- training_area_telegrams.cpp: Fixed brace mismatches in multiple toJson() methods
- training_area_telegrams.h: Changed Header struct to public members for consistency
- tx_mixin.cpp: Fixed getEquipmentNumber() template for direct member access
- lts_coordinate.cpp: Added missing #include <iomanip>
- MIGRATION_STATUS.md: Added migration progress tracking document
C++17 constraint enforced due to RTI Connext DDS 7.7.0 incompatibility with C++20+
Build status: BUILD_RTI=OFF successful (0 errors, warnings only)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
64 lines
2.9 KiB
C++
Executable File
64 lines
2.9 KiB
C++
Executable File
/**
|
|
* @RDE_HEADER@
|
|
* ISM Handler Instrumentation Assets
|
|
* $Id$
|
|
* $HeadURL$
|
|
* $Author$
|
|
* Created by Iuliana Ojog, SLSE, 2016-11-26
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <QtCore/QHash>
|
|
|
|
#include "base.h"
|
|
|
|
//-------------------------------------------------------------------------------------------------------------
|
|
namespace InfrastructureManagement
|
|
{
|
|
class ObjectInstrumentationAsset;
|
|
class MainHandler;
|
|
class HandlerInstrumentationAsset final : public Base
|
|
, protected Interface::Fts::InstrumentationAssetModifyRequestHandler
|
|
, protected Interface::Fts::InstrumentationAssetRemoveRequestHandler
|
|
, protected Interface::Fts::InstrumentationAssetSetStateRequestHandler
|
|
, protected Interface::Fts::InstrumentationAssetUnmountRequestHandler
|
|
{
|
|
public:
|
|
explicit HandlerInstrumentationAsset(MainHandler *mainHandler);
|
|
~HandlerInstrumentationAsset();
|
|
|
|
bool init();
|
|
|
|
ObjectInstrumentationAsset *createInstrumentationAssetForMse(int buildingId, int structureElementId);
|
|
bool removeInstrumentationAssetForMse(int assetId);
|
|
bool setAssetState(int assetId, InstrumentationAssetState state);
|
|
bool setAssetAvailableInExercise(int32_t assetId, const std::vector<int32_t> &exercises);
|
|
|
|
QHash<int, ObjectInstrumentationAsset *> getObjectInstrumentationAssetMap() const
|
|
{
|
|
return m_ObjectInstrumentationAssetMap;
|
|
}
|
|
ObjectInstrumentationAsset *getAssetFromBarcode(const QString &barcode) const;
|
|
ObjectInstrumentationAsset *getAssetFromId(int32_t assetId) const ;
|
|
ObjectInstrumentationAsset *getAssetFromBarcodeAndId(const QString &barcode, int32_t assetId) const;
|
|
private:
|
|
void onInstrumentationAssetModifyRequest(const rti::core::SampleIdentity &cookie,
|
|
const InstrumentationAssetModifyRequest &request) override;
|
|
Core::FunctionReplyObject instrumentationAssetCreate(const InstrumentationAssetModifyRequest &request, int *assetId = nullptr);
|
|
Core::FunctionReplyObject instrumentationAssetModify(const InstrumentationAssetModifyRequest &request);
|
|
void onInstrumentationAssetRemoveRequest(const rti::core::SampleIdentity &cookie,
|
|
const Core::RemoveElementRequest &request) override;
|
|
Core::FunctionReplyObject onInstrumentationAssetRemove(const Core::RemoveElementRequest &request);
|
|
void onInstrumentationAssetSetStateRequest(const rti::core::SampleIdentity &cookie,
|
|
const InstrumentationAssetSetStateRequest &request) override;
|
|
Core::FunctionReplyObject instrumentationAssetSetState(const InstrumentationAssetSetStateRequest &request);
|
|
void onInstrumentationAssetUnmountRequest(const rti::core::SampleIdentity &cookie,
|
|
const InstrumentationAssetUnmountRequest &request) override;
|
|
Core::FunctionReplyObject instrumentationAssetUnmount(const InstrumentationAssetUnmountRequest &request);
|
|
|
|
private:
|
|
QHash<int, ObjectInstrumentationAsset *> m_ObjectInstrumentationAssetMap;
|
|
};
|
|
}
|