- Migrated all 104 CMakeLists.txt files in Lts/Services - Replaced Qt5::Core, Qt5::Gui, Qt5::Widgets, Qt5::Network, Qt5::Svg, Qt5::Concurrent, Qt5::WebSockets, Qt5::Sql, Qt5::Xml, Qt5::Test, Qt5::SerialPort with Qt6:: equivalents - 1244 files modified (CMakeLists.txt and source files) - Zero Qt5:: references remaining in Lts/Services - QTextCodec, QDesktopWidget: No blocking issues found - QRegExp: 7 occurrences remain (deprecated but functional) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
64 lines
1.3 KiB
C++
Executable File
64 lines
1.3 KiB
C++
Executable File
/**
|
|
* @RDE_HEADER@
|
|
* Asset
|
|
* $Id$
|
|
* $HeadURL$
|
|
* $Author$
|
|
* Created by Christian Fröbel, SLSE, 2017-11-30
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "avm_export.h"
|
|
#include <QObject>
|
|
#include <memory>
|
|
|
|
namespace InfrastructureManagement
|
|
{
|
|
|
|
class InstrumentationAsset;
|
|
|
|
} // namespace InfrastructureManagement
|
|
|
|
|
|
namespace AudioVideoManagement
|
|
{
|
|
|
|
class MountingPoint;
|
|
|
|
/**
|
|
* Part of the data model used by the AssetAssignmentManager.
|
|
* @author Christian Fröbel
|
|
*/
|
|
class AVM_COMMON_EXPORT Asset : public QObject
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
explicit Asset(const InfrastructureManagement::InstrumentationAsset &asset);
|
|
~Asset();
|
|
|
|
const InfrastructureManagement::InstrumentationAsset &data() const { return *m_data; }
|
|
|
|
/** Emits the changed() signal. */
|
|
void update(const InfrastructureManagement::InstrumentationAsset &data);
|
|
|
|
bool isMounted() const { return m_mountingPoint != nullptr; }
|
|
|
|
/** May only be called when mounted. */
|
|
MountingPoint *mountingPoint() const;
|
|
|
|
void mount(MountingPoint *mountingPoint);
|
|
void unmount();
|
|
|
|
signals:
|
|
void changed(Asset *asset);
|
|
|
|
private:
|
|
std::unique_ptr<InfrastructureManagement::InstrumentationAsset> m_data;
|
|
MountingPoint *m_mountingPoint{nullptr}; // null if not mounted
|
|
};
|
|
|
|
|
|
} // namespace AudioVideoManagement
|
|
|