Go to the documentation of this file.
7 #ifndef _NIM_SDK_CPP_ROBOT_HELPER_H_
8 #define _NIM_SDK_CPP_ROBOT_HELPER_H_
13 #include "nim_define_include.h"
15 #include "nim_wrapper_util/nim_json_util.h"
16 #include "public_defines.h"
26 void SetAccid(
const std::string& accid) { robot_info_[kNIMRobotInfoKeyAccid] = accid; }
29 std::string
GetAccid()
const {
return robot_info_[kNIMRobotInfoKeyAccid].asString(); }
32 void SetName(
const std::string& name) { robot_info_[kNIMRobotInfoKeyName] = name; }
35 std::string
GetName()
const {
return robot_info_[kNIMRobotInfoKeyName].asString(); }
38 void SetIcon(
const std::string& icon) { robot_info_[kNIMRobotInfoKeyIcon] = icon; }
41 std::string
GetIcon()
const {
return robot_info_[kNIMRobotInfoKeyIcon].asString(); }
44 void SetIntro(
const std::string& intro) { robot_info_[kNIMRobotInfoKeyIntro] = intro; }
47 std::string
GetIntro()
const {
return robot_info_[kNIMRobotInfoKeyIntro].asString(); }
50 void SetRobotID(
const std::string&
id) { robot_info_[kNIMRobotInfoKeyRobotId] = id; }
53 std::string
GetRobotID()
const {
return robot_info_[kNIMRobotInfoKeyRobotId].asString(); }
56 void SetCreateTime(
const uint64_t time) { robot_info_[kNIMRobotInfoKeyCreateTime] = time; }
59 uint64_t
GetCreateTime()
const {
return robot_info_[kNIMRobotInfoKeyCreateTime].asUInt64(); }
62 void SetUpdateTime(
const uint64_t time) { robot_info_[kNIMRobotInfoKeyUpdateTime] = time; }
65 uint64_t
GetUpdateTime()
const {
return robot_info_[kNIMRobotInfoKeyUpdateTime].asUInt64(); }
68 nim_cpp_wrapper_util::Json::Value robot_info_;
71 typedef std::list<RobotInfo> RobotInfos;
91 #endif //_NIM_SDK_CPP_ROBOT_HELPER_H_
std::string GetAccid() const
Definition: nim_robot_helper.h:29
机器人信息
Definition: nim_robot_helper.h:23
std::string GetRobotID() const
Definition: nim_robot_helper.h:53
void SetIcon(const std::string &icon)
Definition: nim_robot_helper.h:38
void SetName(const std::string &name)
Definition: nim_robot_helper.h:32
void SetRobotID(const std::string &id)
Definition: nim_robot_helper.h:50
void SetIntro(const std::string &intro)
Definition: nim_robot_helper.h:44
void SetCreateTime(const uint64_t time)
Definition: nim_robot_helper.h:56
void SetUpdateTime(const uint64_t time)
Definition: nim_robot_helper.h:62
NIM_SDK_CPPWRAPPER_DLL_API bool ParseRobotInfosStringToRobotInfos(const std::string &infos_json, RobotInfos &infos)
解析机器人信息
uint64_t GetCreateTime() const
Definition: nim_robot_helper.h:59
std::string GetName() const
Definition: nim_robot_helper.h:35
void SetAccid(const std::string &accid)
Definition: nim_robot_helper.h:26
uint64_t GetUpdateTime() const
Definition: nim_robot_helper.h:65
NIM_SDK_CPPWRAPPER_DLL_API bool ParseRobotInfoStringToRobotInfo(const std::string &info_json, RobotInfo &info)
解析机器人信息
std::string GetIcon() const
Definition: nim_robot_helper.h:41
std::string GetIntro() const
Definition: nim_robot_helper.h:47