Initial commit

This commit is contained in:
torsten committed 2026-08-13 18:33:10 +02:00
commit b7d90b9afe
16245 files changed
+3396666

No files matched your search

+56
View File
@@ -0,0 +1,56 @@
/**
* @RDE_HEADER@
* MountingPoint
* $Id$
* $HeadURL$
* $Author$
* Created by Christian Fröbel, SLSE, 2017-11-30
*/
#include "mounting_point.h"
#include <InfrastructureManagement/ism.hpp>
#include <QtGlobal>
namespace AudioVideoManagement
{
MountingPoint::MountingPoint(const InfrastructureManagement::StructureElement &mountingPoint)
: m_data(new InfrastructureManagement::StructureElement(mountingPoint))
{
Q_ASSERT(mountingPoint.id() > 0);
}
MountingPoint::~MountingPoint() = default;
void MountingPoint::update(const InfrastructureManagement::StructureElement &data)
{
if (*m_data == data)
return;
*m_data = data;
emit changed(this);
}
Asset *MountingPoint::asset() const
{
Q_ASSERT(m_asset);
return m_asset;
}
void MountingPoint::mount2(Asset *asset)
{
Q_ASSERT(!m_asset);
Q_ASSERT(asset);
m_asset = asset;
}
void MountingPoint::unmount2(Asset *asset)
{
Q_ASSERT(m_asset);
Q_ASSERT(asset == m_asset);
m_asset = nullptr;
return;
}
} // namespace AudioVideoManagement