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
@@ -67,7 +67,7 @@ void HandlerSnapshot::onSnapshotModifyRequest(const rti::core::SampleIdentity &c
|
||||
const Snapshot &request)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "SnapshotModifyRequest: " << request;
|
||||
auto ret = request.id() > 0 ? snapshotModifyRequest(request) : snapshotCreateRequest(request);
|
||||
auto ret = request.id > 0 ? snapshotModifyRequest(request) : snapshotCreateRequest(request);
|
||||
if (ret.error())
|
||||
WARNING_LOG(m_logger) << ret();
|
||||
m_ddsHandler->fts()->snapshotModifyReply(cookie, ret);
|
||||
@@ -91,26 +91,26 @@ Core::FunctionReplyObject HandlerSnapshot::snapshotCreateRequest(const Snapshot
|
||||
|
||||
Core::FunctionReplyObject HandlerSnapshot::snapshotModifyRequest(const Snapshot &request)
|
||||
{
|
||||
ObjectSnapshot *ifs = m_objectSnapshotMap.value(request.id());
|
||||
ObjectSnapshot *ifs = m_objectSnapshotMap.value(request.id);
|
||||
if (ifs == nullptr)
|
||||
return Core::FunctionReplyObject(request.id(), tr_lts("dds", "Snapshot with id %1 not found")).arg(request.id());
|
||||
return Core::FunctionReplyObject(request.id, tr_lts("dds", "Snapshot with id %1 not found")).arg(request.id);
|
||||
|
||||
Snapshot ddsData = ifs->getData();
|
||||
ddsData.name(request.name());
|
||||
ddsData.description(request.description());
|
||||
ddsData.fileContentId(request.fileContentId());
|
||||
ddsData.name = request.name;
|
||||
ddsData.description = request.description;
|
||||
ddsData.fileContentId = request.fileContentId;
|
||||
|
||||
if (request.mapSettings().size() > 0)
|
||||
ddsData.mapSettings(request.mapSettings());
|
||||
if (request.mapSettings.size() > 0)
|
||||
ddsData.mapSettings = request.mapSettings;
|
||||
|
||||
if (request.movementTracks().size() > 0)
|
||||
ddsData.movementTracks(request.movementTracks());
|
||||
if (request.movementTracks.size() > 0)
|
||||
ddsData.movementTracks = request.movementTracks;
|
||||
|
||||
if (request.planOverlay().size() > 0)
|
||||
ddsData.planOverlay(request.planOverlay());
|
||||
if (request.planOverlay.size() > 0)
|
||||
ddsData.planOverlay = request.planOverlay;
|
||||
|
||||
if (request.filter().size() > 0)
|
||||
ddsData.filter(request.filter());
|
||||
if (request.filter.size() > 0)
|
||||
ddsData.filter = request.filter;
|
||||
|
||||
return ifs->updateObject(ddsData);
|
||||
} // end of onSnapshotModifyRequest()
|
||||
@@ -119,17 +119,17 @@ Core::FunctionReplyObject HandlerSnapshot::snapshotModifyRequest(const Snapshot
|
||||
void HandlerSnapshot::onSnapshotRemoveRequest(const rti::core::SampleIdentity &cookie,
|
||||
const Core::RemoveElementRequest &request)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "onSnapshotRemoveRequest() id:" << request.id();
|
||||
DEBUG_LOG(m_logger) << "onSnapshotRemoveRequest() id:" << request.id;
|
||||
|
||||
Core::FunctionReplyObject ret;
|
||||
ObjectSnapshot *ifs = m_objectSnapshotMap.value(request.id());
|
||||
ObjectSnapshot *ifs = m_objectSnapshotMap.value(request.id);
|
||||
if (ifs == nullptr)
|
||||
ret = Core::FunctionReplyObject(request.id(), tr_lts("dds", "Snapshot with id %1 not found")).arg(request.id());
|
||||
ret = Core::FunctionReplyObject(request.id, tr_lts("dds", "Snapshot with id %1 not found")).arg(request.id);
|
||||
else
|
||||
{
|
||||
if (m_ddsHandler->topicLockMaster()->isLocked(ifs->getData(), m_ddsHandler->ddsConnector()->getPartitionId()))
|
||||
{
|
||||
ret = Core::FunctionReplyObject(request.id(), tr_lts("dds", "Snapshot '%1' is used by another user!")).arg(ifs->getName());
|
||||
ret = Core::FunctionReplyObject(request.id, tr_lts("dds", "Snapshot '%1' is used by another user!")).arg(ifs->getName());
|
||||
m_ddsHandler->fts()->snapshotRemoveReply(cookie, ret);
|
||||
return;
|
||||
}
|
||||
@@ -142,7 +142,7 @@ void HandlerSnapshot::onSnapshotRemoveRequest(const rti::core::SampleIdentity &c
|
||||
{
|
||||
// delete ObjectSnapshot
|
||||
delete ifs;
|
||||
m_objectSnapshotMap.remove(request.id());
|
||||
m_objectSnapshotMap.remove(request.id);
|
||||
}
|
||||
|
||||
m_ddsHandler->fts()->snapshotRemoveReply(cookie, ret);
|
||||
|
||||
Reference in new issue
Block a user