#include <adtf_filtersdk.h>
#include "demo_calculator_client_filter.h"
cCalculationClientFilter::cCalculationClientFilter()
{
m_oInterfaceClient = CreateInterfaceClient<ICalculator>("calculator_client");
SetDescription("calculator_client", "Interface client to call a calculator function from a server");
SetDescription("trigger", "Runner to periodically trigger the function which prints the timestamp of the trigger");
SetDescription("Use this filter to provide a client which accesses the printer interface from Demo Interface Printer (see Streaming Sources).");
SetHelpLink("$(ADTF_DIR)/doc/adtf_html/page_demo_rpc.html");
m_oServerDelay.SetDescription("To construct an example that should show how you can make a server call with an error return, you can set an artificial delay on the server here");
RegisterPropertyVariable("server_delay", m_oServerDelay);
}
tResult cCalculationClientFilter::Process(tNanoSeconds , IRunner * )
{
LOG_INFO(
"Sum: %d", m_oInterfaceClient->Add(2, 1));
}
tResult cCalculationClientFilter::Init(tInitStage eStage)
{
if (eStage == tInitStage::StageGraphReady)
{
}
};
#define LOG_INFO(...)
Logs an info message.
std::chrono::seconds seconds
Compatibility to C++11 std::chrono::seconds