Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
@@ -0,0 +1,59 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* ISM Handler Sound Areas
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Filip Biedziak, NLE, 2020-08-05
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <QHash>
|
||||
|
||||
#include "base.h"
|
||||
|
||||
|
||||
namespace InfrastructureManagement
|
||||
{
|
||||
|
||||
class ObjectEffectArea;
|
||||
class MainHandler;
|
||||
|
||||
|
||||
class HandlerEffectArea final : public Base
|
||||
{
|
||||
|
||||
public:
|
||||
explicit HandlerEffectArea(MainHandler *mainHandler);
|
||||
~HandlerEffectArea();
|
||||
|
||||
bool init();
|
||||
|
||||
|
||||
ObjectEffectArea *createEffectAreaForMse(const InfrastructureManagement::MainStructureElement &mse);
|
||||
|
||||
QHash<int, ObjectEffectArea *> getObjectEffectAreaMap() const { return m_objectEffectAreaMap; }
|
||||
ObjectEffectArea *getEffectAreaFromId(int32_t id) const { return m_objectEffectAreaMap.value(id, nullptr); }
|
||||
|
||||
private:
|
||||
int getSeId(const int mountPointId, const InfrastructureManagement::MainStructureElement &mse) const;
|
||||
/**
|
||||
* @brief assetIdsFromJsonArray reads the EGCU IDs of the sound area from a Json object.
|
||||
* @param jsonObj Json object with an entry 'egcuMountpoints'
|
||||
* @return vector with EGCU IDs
|
||||
*/
|
||||
std::vector<int32_t> egcuIdsFromJsonObject(const QJsonObject &jsonObj, const MainStructureElement &mse) const;
|
||||
/**
|
||||
* @brief geometryFromJsonArray reads the vertices of the sound area from a Json object.
|
||||
* @param jsonObj Json object with an entry 'geometry'
|
||||
* @return vector with 2D geo coordinates
|
||||
*/
|
||||
std::vector<Core::GeoPosition2D> geometryFromJsonObject(const QJsonObject &jsonObj) const;
|
||||
|
||||
private:
|
||||
QHash<int32_t, ObjectEffectArea *> m_objectEffectAreaMap;
|
||||
|
||||
};
|
||||
|
||||
} // namespace InfrastructureManagement
|
||||
Reference in new issue
Block a user