Add new API for querying the sample logs of PTS debug plan.

This commit is contained in:
sdk-team
2023-03-28 01:57:01 +00:00
parent bfe14f3d0f
commit 077d8093c7
3 changed files with 17 additions and 1 deletions

View File

@@ -1 +1 @@
1.36.1514
1.36.1515

View File

@@ -146,12 +146,18 @@ namespace AlibabaCloud
std::string paramValue;
std::string paramName;
};
struct Header1
{
std::string value;
std::string name;
};
std::string status;
std::string sceneId;
AdvanceSetting advanceSetting;
std::vector<Relation> relationList;
std::string modifiedTime;
std::string sceneName;
std::vector<Header1> headers;
LoadConfig loadConfig;
std::string createTime;
std::vector<GlobalParameter> globalParameterList;

View File

@@ -155,6 +155,16 @@ void GetPtsSceneResult::parse(const std::string &payload)
globalParameterObject.paramValue = sceneNodeGlobalParameterListGlobalParameter["ParamValue"].asString();
scene_.globalParameterList.push_back(globalParameterObject);
}
auto allHeadersNode = sceneNode["Headers"]["Header"];
for (auto sceneNodeHeadersHeader : allHeadersNode)
{
Scene::Header1 header1Object;
if(!sceneNodeHeadersHeader["Name"].isNull())
header1Object.name = sceneNodeHeadersHeader["Name"].asString();
if(!sceneNodeHeadersHeader["Value"].isNull())
header1Object.value = sceneNodeHeadersHeader["Value"].asString();
scene_.headers.push_back(header1Object);
}
auto loadConfigNode = sceneNode["LoadConfig"];
if(!loadConfigNode["MaxRunningTime"].isNull())
scene_.loadConfig.maxRunningTime = std::stoi(loadConfigNode["MaxRunningTime"].asString());