Migrates EffectShow and AssetManagement to generated rtiddsgen API
Converts accessor calls to plain member access across esc and asm services.
This commit is contained in:
39 files changed
+818
-818
No files matched your search
@@ -70,11 +70,11 @@ void HandlerAsset::onAssetModifyRequest(const rti::core::SampleIdentity &cookie,
|
||||
Core::FunctionReplyObject HandlerAsset::assetModifyRequest(const Asset &request)
|
||||
{
|
||||
// modify
|
||||
if (request.id() > 0)
|
||||
if (request.id > 0)
|
||||
{
|
||||
ObjectAsset *ifs = m_objectAssetMap.value(request.id());
|
||||
ObjectAsset *ifs = m_objectAssetMap.value(request.id);
|
||||
if (!ifs)
|
||||
return Core::FunctionReplyObject(request.id(), tr_lts("dds", "Asset with id %1 not found")).arg(request.id());
|
||||
return Core::FunctionReplyObject(request.id, tr_lts("dds", "Asset with id %1 not found")).arg(request.id);
|
||||
return ifs->updateObject(request);
|
||||
}
|
||||
// create
|
||||
@@ -96,18 +96,18 @@ void HandlerAsset::onAssetRemoveRequest(const rti::core::SampleIdentity &cookie,
|
||||
const Core::RemoveElementRequest &request)
|
||||
{
|
||||
Core::FunctionReplyObject ret;
|
||||
ObjectAsset *ifs = m_objectAssetMap.value(request.id());
|
||||
ObjectAsset *ifs = m_objectAssetMap.value(request.id);
|
||||
|
||||
if (ifs == nullptr)
|
||||
{
|
||||
ret = Core::FunctionReplyObject(request.id(), tr_lts("dds", "Asset with id %1 not found")).arg(request.id());
|
||||
ret = Core::FunctionReplyObject(request.id, tr_lts("dds", "Asset with id %1 not found")).arg(request.id);
|
||||
m_mainHandler->dds()->fts()->assetRemoveReply(cookie, ret);
|
||||
return;
|
||||
}
|
||||
|
||||
if (m_mainHandler->dds()->topicLockMaster()->isLocked(ifs->getData(), m_mainHandler->exerciseId()))
|
||||
{
|
||||
ret = Core::FunctionReplyObject(request.id(), tr_lts("dds", "Asset '%1' is used by another user!")).arg(ifs->getName());
|
||||
ret = Core::FunctionReplyObject(request.id, tr_lts("dds", "Asset '%1' is used by another user!")).arg(ifs->getName());
|
||||
m_mainHandler->dds()->fts()->assetRemoveReply(cookie, ret);
|
||||
return;
|
||||
}
|
||||
@@ -120,7 +120,7 @@ void HandlerAsset::onAssetRemoveRequest(const rti::core::SampleIdentity &cookie,
|
||||
{
|
||||
// delete ObjectAsset
|
||||
delete ifs;
|
||||
m_objectAssetMap.remove(request.id());
|
||||
m_objectAssetMap.remove(request.id);
|
||||
}
|
||||
|
||||
m_mainHandler->dds()->fts()->assetRemoveReply(cookie, ret);
|
||||
|
||||
Reference in new issue
Block a user