Skip to content

how std::string and a Json::Value string convert, each other? #1530

@xinsuinizhuan

Description

@xinsuinizhuan

I read a json string,and convert to a Json::Value:
void xxx_json_param(const char* _jsondata, const char* _savepath)
{
Json::Value root;
Json::Reader reader;
reader.parse((const std::string)_jsondata, root);

    Json::Value applicationjson_j = root["Application"];
    //applicationjson_j  is also a json,but when i asString(), it broke 
    string applicationjson = root["Application"].asString();

}

图片

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions