You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
573 B
C++
20 lines
573 B
C++
4 months ago
|
//
|
||
|
// Created by Matthew on 2025/3/4.
|
||
|
//
|
||
|
#include "VendorCtrl.h"
|
||
|
|
||
|
VendorCtrl::VendorCtrl(const std::string& ip, const std::string& userName, const std::string& password) :
|
||
|
m_ip(ip), m_userName(userName), m_password(password), m_channel(channel)
|
||
|
{
|
||
|
}
|
||
|
std::string VendorCtrl::CvtJSONToString(const Json::Value& data)
|
||
|
{
|
||
|
Json::StreamWriterBuilder builder;
|
||
|
#ifndef NDEBUG
|
||
|
builder["indentation"] = "\t"; // assume default for comments is None
|
||
|
builder["emitUTF8"] = true;
|
||
|
#else
|
||
|
builder["indentation"] = "";
|
||
|
#endif
|
||
|
return Json::writeString(builder, data);
|
||
|
}
|