M_Thread *thread_process= new M_Thread(s);
QThreadPool::globalInstance()->start(thread_process);
#ifndef M_RESULT_H
#define M_RESULT_H
#include <QObject>
#include <QList>
#include "data_structures.h"
#include <QDebug>
class M_RESULT : public QObject
{
Q_OBJECT
public:
explicit M_RESULT(QObject *parent = nullptr,QList<sens> &a);
signals:
public slots:
};
#endif // M_RESULT_H
#include "m_result.h"
M_RESULT::M_RESULT(QObject *parent, QList<sens> &a) : QObject(parent)
{
}
QList<sens> s;
M_RESULT *m_r = new M_RESULT(s);
struct sens
{
QString ip="";
int port=0;
QString community="";
QString oid= "";
QString name= "";
QString result="null";
};
std::string SNMPObject::getSyntaxAsString() const {
static char * _syntaxStrMap[12] = {
"Integer",
"Octets",
"Opaque",
"Bits",
"Counter64",
"Counter32",
"Gauge32",
"UnsignedInteger32",
"TimeTicks",
"ObjectIdentifier",
"IPAddr",
"Null" };
return _syntaxStrMap[getSyntax()];
}
C:\Users\stgmt\Desktop\best\SNMPObject.cpp:547: ошибка: C2440: инициализация: невозможно преобразовать "const char [8]" в "char *"