Migrates remaining services and plugins to generated rtiddsgen API
Converts accessor calls to plain member access across the residual service set.
This commit is contained in:
104 files changed
+2424
-2430
No files matched your search
+1
-1
@@ -56,7 +56,7 @@ void AvsInterface::doConnect()
|
||||
this, &AvsInterface::onConnected);
|
||||
connect(m_socket, &QTcpSocket::disconnected,
|
||||
this, &AvsInterface::onDisonnected);
|
||||
connect(m_socket, QOverload<QAbstractSocket::SocketError>::of(&QTcpSocket::error),
|
||||
connect(m_socket, &QTcpSocket::errorOccurred,
|
||||
this, &AvsInterface::onError);
|
||||
connect(m_socket, &QTcpSocket::readyRead,
|
||||
this, &AvsInterface::onReadyRead);
|
||||
|
||||
+18
-18
@@ -55,7 +55,7 @@ bool HandlerInfrastructureData::init(int exerciseId)
|
||||
auto predicate =
|
||||
[](const InfrastructureManagement::InstrumentationAsset & a)
|
||||
{
|
||||
return a.mountingPointTypeId() == InfrastructureManagement::MountingPointType::IndoorCamera;
|
||||
return a.mountingPointTypeId == InfrastructureManagement::MountingPointType::IndoorCamera;
|
||||
};
|
||||
if (!m_dtc->getAllAssetsPerRoom(predicate, assetsMap))
|
||||
{
|
||||
@@ -68,21 +68,21 @@ bool HandlerInfrastructureData::init(int exerciseId)
|
||||
const int roomId = i.key();
|
||||
for (const InfrastructureManagement::InstrumentationAsset &asset : i.value())
|
||||
{
|
||||
auto it = std::find(asset.availableInExercise().begin(),
|
||||
asset.availableInExercise().end(), m_exerciseId);
|
||||
if (it == asset.availableInExercise().end())
|
||||
auto it = std::find(asset.availableInExercise.begin(),
|
||||
asset.availableInExercise.end(), m_exerciseId);
|
||||
if (it == asset.availableInExercise.end())
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "Asset " << asset.id()
|
||||
DEBUG_LOG(m_logger) << "Asset " << asset.id
|
||||
<< " is not available in current exercise - skipping";
|
||||
continue;
|
||||
}
|
||||
// in interne m_roomId2CameraNameMap eintragen, zur Zeit nur eine Kamera pro Raum möglich
|
||||
m_roomId2CameraNameMap.insert(roomId, QString::fromStdString(asset.name()));
|
||||
m_roomId2CameraNameMap.insert(roomId, QString::fromStdString(asset.name));
|
||||
// und fuer subscribe in m_assetId2RoomIdMap eintragen
|
||||
m_assetId2RoomIdMap.insert(asset.id(), roomId);
|
||||
DEBUG_LOG(m_logger) << " assetId: " << asset.id()
|
||||
<< " mountingPointTypeId: " << asset.mountingPointTypeId()
|
||||
<< " name: " << asset.name();
|
||||
m_assetId2RoomIdMap.insert(asset.id, roomId);
|
||||
DEBUG_LOG(m_logger) << " assetId: " << asset.id
|
||||
<< " mountingPointTypeId: " << asset.mountingPointTypeId
|
||||
<< " name: " << asset.name;
|
||||
}
|
||||
} // for(auto i = assetMap...
|
||||
|
||||
@@ -126,24 +126,24 @@ QString HandlerInfrastructureData::getStreamNameFromRoomId(int roomId) const
|
||||
void HandlerInfrastructureData::onAssetChanged(const InfrastructureManagement::InstrumentationAsset &data, DataModification modType)
|
||||
{
|
||||
Q_UNUSED(modType);
|
||||
if (data.mountingPointTypeId() != InfrastructureManagement::MountingPointType::IndoorCamera)
|
||||
if (data.mountingPointTypeId != InfrastructureManagement::MountingPointType::IndoorCamera)
|
||||
return;
|
||||
|
||||
INFO_LOG(m_logger) << "onAssetChanged()"
|
||||
<< " assetId: " << data.id()
|
||||
<< " name: " << data.name();
|
||||
<< " assetId: " << data.id
|
||||
<< " name: " << data.name;
|
||||
|
||||
auto it = std::find(data.availableInExercise().begin(),
|
||||
data.availableInExercise().end(), m_exerciseId);
|
||||
if (it == data.availableInExercise().end())
|
||||
auto it = std::find(data.availableInExercise.begin(),
|
||||
data.availableInExercise.end(), m_exerciseId);
|
||||
if (it == data.availableInExercise.end())
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "Asset " << data.id()
|
||||
DEBUG_LOG(m_logger) << "Asset " << data.id
|
||||
<< " is not available in current exercise - skipping";
|
||||
return;
|
||||
}
|
||||
|
||||
// Hier muss aus der AssetId die zugehoerige roomid verwendet werden !!
|
||||
m_roomId2CameraNameMap.insert(getRoomIdFromAssetId(data.id()), QString::fromStdString(data.name()));
|
||||
m_roomId2CameraNameMap.insert(getRoomIdFromAssetId(data.id), QString::fromStdString(data.name));
|
||||
|
||||
for (auto i = m_roomId2CameraNameMap.begin(); i != m_roomId2CameraNameMap.end(); ++i)
|
||||
{
|
||||
|
||||
+10
-10
@@ -57,7 +57,7 @@ bool HandlerParticipantData::init()
|
||||
// Position in ParticipantsPositionMap eintragen
|
||||
auto cbParticipantPos = [this](const ParticipantManagement::ParticipantPosition &participantPos)
|
||||
{
|
||||
m_participantsPositionMap.insert(participantPos.participantId(), participantPos.roomId());
|
||||
m_participantsPositionMap.insert(participantPos.participantId, participantPos.roomId);
|
||||
};
|
||||
m_dtc->participantPositions(cbParticipantPos);
|
||||
|
||||
@@ -88,12 +88,12 @@ QMap<int, int> HandlerParticipantData::getAllAssignedParticipants() const
|
||||
|
||||
void HandlerParticipantData::onParticipantChanged(const ParticipantManagement::Participant &data, DataModification modType)
|
||||
{
|
||||
INFO_LOG(m_logger) << "onParticipantChanged() participantId:" << data.id();
|
||||
INFO_LOG(m_logger) << "onParticipantChanged() participantId:" << data.id;
|
||||
|
||||
if (modType != DataModification::eRemoved && data.equipmentNumber().is_set())
|
||||
m_partId2EquipNoMap.insert(data.id(), data.equipmentNumber().get());
|
||||
if (modType != DataModification::eRemoved && data.equipmentNumber.is_set())
|
||||
m_partId2EquipNoMap.insert(data.id, data.equipmentNumber.get());
|
||||
else
|
||||
m_partId2EquipNoMap.remove(data.id());
|
||||
m_partId2EquipNoMap.remove(data.id);
|
||||
|
||||
if (m_logger.isDebugEnabled())
|
||||
{
|
||||
@@ -107,23 +107,23 @@ void HandlerParticipantData::onParticipantChanged(const ParticipantManagement::P
|
||||
|
||||
void HandlerParticipantData::onParticipantPositionChanged(const ParticipantManagement::ParticipantPosition &data, DataModification modType)
|
||||
{
|
||||
const int newRoomId = data.roomId();
|
||||
const int newRoomId = data.roomId;
|
||||
// get reference to room (will be created if not exist)
|
||||
int &roomId = m_participantsPositionMap[data.participantId()];
|
||||
int &roomId = m_participantsPositionMap[data.participantId];
|
||||
// remember old room
|
||||
const int oldRoomId = roomId;
|
||||
// assing new room
|
||||
roomId = modType == DataModification::eRemoved ? 0 : newRoomId;
|
||||
if (newRoomId != oldRoomId)
|
||||
emit participantPositionChanged(oldRoomId, newRoomId, data.participantId());
|
||||
emit participantPositionChanged(oldRoomId, newRoomId, data.participantId);
|
||||
|
||||
INFO_LOG(m_logger) << "onParticipantPositionChanged()"
|
||||
<< " oldRoomId: " << oldRoomId
|
||||
<< " newRoomId: " << newRoomId
|
||||
<< " participantId: " << data.participantId();
|
||||
<< " participantId: " << data.participantId;
|
||||
|
||||
if (modType == DataModification::eRemoved)
|
||||
m_participantsPositionMap.remove(data.participantId());
|
||||
m_participantsPositionMap.remove(data.participantId);
|
||||
|
||||
} // end of onParticipantPositionChanged()
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
Reference in new issue
Block a user