Files
qt5-legatus-legacy/Lts/Viewer/SituationMap/MapObjectsImpl/virtual_mine_impl.h
T
2026-08-13 18:33:10 +02:00

103 lines
2.7 KiB
C++
Executable File

/**
* @RDE_HEADER@
* Interface-Implementation of VirtualMine
* $Id$
* $HeadURL$
* $Author$
*/
#pragma once
// Own
#include "abstract_multi_point_map_object_impl.h"
#include "basic_path_object_impl.h"
#include <MapObjects/virtual_mine.h> // Interface
// Qt
#include <QString>
//----------------------------------------------------------------------------
namespace SituationMap
{
/**
* @brief The VirtualMineImpl class displays a nuclear area. The outline is displayed as well a subsidiary lines.
*
* A class instance consists of the following logical elements:
* - mainGraphicalObject (GraphicalObjectPath displaying the main techn. Appearance / outline)
* - mainGraphicalObjectText (displaying the text/name)
* - tacticalAppearance (displaying the tact. Appearance)
* - Container of BasicPathObjectImpl's to display the subsidiary lines.
*/
// inherent 'public', to get that implementation
// inherent 'public virtual' to get that interface
class SITUATIONMAPOBJECTS_EXPORT VirtualMineImpl : public BasicPathObjectImpl, public virtual VirtualMine
{
using BaseClass = BasicPathObjectImpl;
template <typename> friend class GenericObjectFactory;
protected:
explicit VirtualMineImpl(const QString &debugInfo = QString());
virtual ~VirtualMineImpl();
public:
VirtualMineImpl(const VirtualMineImpl &other) = delete;
VirtualMineImpl &operator=(VirtualMineImpl &other) = delete;
void setUniqueId(const UniqueMapId &uniqueId) override;
/*! \name Subsidiary polylines, identified by an arbitrary choose key.*/
//@{
PositionCont subsidiaryLine(int key) const override;
void setSubsidiaryLine(int key, const PositionCont &positions, const OptionalData &optData = OptionalData()) override;
QList<int> subsidiaryKeysInUse() override;
void removeSubsidiaryLine(int key) override;
void removeSubsidiaryLines() override;
//@}
/*! \name 3D marker / SimpleMarkerSceneSymbol (via renderer) */
//@{
bool has3DMarkerRenderer() const override;
void set3DMarkerRenderer(const Point3D &markerOrigin, const QVariantMap &attribMap) override;
//@}
bool has3DMarkerSceneSymbol() const override;
void set3DMarkerSceneSymbol(const Point3D &markerOrigin, const SceneSymbolData &sceneSymbolData) override;
protected:
bool updateViewImpl() override;
bool updateViewImpl3DMarkerRenderer();
bool updateViewImpl3DMarkerSceneSymbol();
friend class MapImpl;
bool init(MapImpl *mapImpl, const QString &logicalLayerName) override;
// internal/admin
// logical
private:
class Private;
/**
* The private d->pointer to not break BC when changing internals of this class
*/
Private *d = nullptr;
LOGGER_T m_logger; ///< Interface of the Logging-Facility
};
} // namespace SituationMap