#include "myplugin.h"
#include <QLoggingCategory>

static QLoggingCategory lc {"myplugin.plugin"};

MyPlugin::MyPlugin(int &argc, char **argv)
    : IDS::NXT::Plugin{argc, argv},
      _sink1("sink1",IDS::NXT::ResultType::String)
{
    connect(&_sink1, &IDS::NXT::ResultSink::newPartResult, this, &MyPlugin::newResult);
}

void MyPlugin::newResult(const QString &imagekey,const QString &part, const QVariant &result)
{
    qCDebug(lc) << "new result: Image:" <<imagekey<< "Part" << part<< "Result" << result;
}