From 946823215bac2c859df843f7b01636f5fda34ed4 Mon Sep 17 00:00:00 2001 From: cheliequan <liequanche@126.com> Date: 星期五, 13 一月 2023 20:32:23 +0800 Subject: [PATCH] 重构util接口,支持按照key查找json,并转换vector list --- sdk.cpp | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/sdk.cpp b/sdk.cpp index 8a78418..dc4cda9 100644 --- a/sdk.cpp +++ b/sdk.cpp @@ -3,16 +3,18 @@ using namespace protomsg; -bool dbapi_get_sdk_channel_set(void *handle, std::vector<protomsg::SdkChanSet> & list) { +bool dbapi_get_sdk_channel_set(void *handle, std::vector<protomsg::SdkChanSet> &list) { const char *topic = DATA_URL_PREFIX("/sdk/getAllSdkChanSet"); - bool ret = bus_dbapi_get_list(handle, topic, list); + bool ret = bus_dbapi_get_list(handle, topic, list); + return ret; } -bool dbapi_get_sdks(void *handle, std::vector<protomsg::Sdk> & list) { +bool dbapi_get_sdks(void *handle, std::vector<protomsg::Sdk> &list) { const char *topic = DATA_URL_PREFIX("/sdk/findAllSdk"); - bool ret = bus_dbapi_get_list(handle, topic, list); + bool ret = bus_dbapi_get_list(handle, topic, list); + return ret; } -- Gitblit v1.8.0