生成并返回 json 结果文件

#region 生成并返回 json 结果文件

/// <summary>

/// 生成并返回 json 结果文件

/// </summary>

/// <param name="json">主内容</param>

/// <param name="argus">其它参数</param>

/// <param name="flag">标志</param>

/// <param name="mess">结果</param>

/// <returns></returns>

public static string BackJson(string flag, string json, string mess)

{

    StringBuilder strback = new StringBuilder();

    strback.Append("{\"flag\":\"" + flag + "\",\"msg\":\"" + mess + "\"");

    strback.Append(json);

    strback.Append("}");

    return strback.ToString();

}

#endregion

你可能感兴趣的:(json)