ADTF  3.18.2
Source Code for Deserializer Support Service Plugin
Location
./src/examples/src/adtf/deserializer/deserializer_support_service/
Namespace for entire ADTF SDK.
Build Environment
To see how to set up the build environment have a look at ADTF CMake Environment
this implementation shows:
Remarks
  • you can add more then one adtffileplugin to load additional deserializer adtffileplugins
Header
#pragma once
#include <adtf_systemsdk.h>
class cDemoDeserializerSupportSrv : public adtf::system::cADTFService
{
public:
ADTF_CLASS_ID_NAME(cDemoDeserializerSupportSrv,
"demo_deserializer_support.service.adtf.cid",
"ADTF 2.x Compressed Video Deserializer Support Service");
public: // Overrides cService
cDemoDeserializerSupportSrv();
tResult ServiceInit() override;
};
Copyright © Audi Electronics Venture GmbH.
#define REQUIRE_INTERFACE(_interface)
Macro usable with ADTF_CLASS_DEPENDENCIES() to require mandatory interfaces.
#define ADTF_CLASS_DEPENDENCIES(...)
Add interface ids (string literals,.
#define ADTF_CLASS_ID_NAME(_class, _strcid, _strclabel)
Common macro to enable correct treatment of class identifier AND Class Name by IClassInfo.
Definition: class_id.h:33
Default implementation of a ADTF Service can be used for convinience.
Definition: adtf_service.h:27
Implementation
#include "demo_deserializer_support_srv.h"
using namespace adtf::util;
using namespace adtf::base;
using namespace adtf::ucom;
using namespace adtf::services;
ADTF_PLUGIN("Deserializer Support Service", cDemoDeserializerSupportSrv);
cDemoDeserializerSupportSrv::cDemoDeserializerSupportSrv()
{
// sets a short description for the component
SetDescription("Use this System Service to extend the ADTF System with deserialization support for sample data created with ADTF 2 Video Compression Toolbox.");
// set help link to jump to documentation from ADTF Configuration Editor
SetHelpLink("$(ADTF_DIR)/doc/adtf_html/page_demo_deserializer_support_service.html");
}
tResult cDemoDeserializerSupportSrv::ServiceInit()
{
RETURN_IF_FAILED(cADTFService::ServiceInit());
object_ptr<IADTFFileSupport> pFileSupport;
RETURN_IF_FAILED_DESC(_runtime->GetObject(pFileSupport), "Unable to get ADTFFileSupport-Interface: check if adtf_file_support plugin is loaded");
return pFileSupport->LoadADTFFilePlugin(cFileSystem::GetOwnModuleDirectory().AppendPath("demo_adtf2_compressed_video_deserializer.adtffileplugin"));
}
#define ADTF_PLUGIN(__plugin_identifier,...)
The ADTF Plugin Macro will add the code of a adtf::ucom::ant::IPlugin implementation.
Definition: adtf_plugin.h:22
#define RETURN_IF_FAILED(s)
Return if expression is failed, which requires the calling function's return type to be tResult.
virtual tResult GetObject(iobject_ptr< IObject > &pObject, const char *strNameOID) const =0
Get registered object from object registry.
Namespace for the ADTF Base SDK.
Namespace for a summary of all service interfaces (System Service) provided by ADTF.
Namespace for the ADTF uCOM3 SDK.
alias namespace for the A_UTILS Library.
adtf::ucom::IRuntime * _runtime
Global Runtime Pointer to reference to the current runtime.
#define RETURN_IF_FAILED_DESC(s,...)
returns if the expression returns a failed tResult and ammends the error message.