• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            專職C++

            不能停止的腳步

              C++博客 :: 首頁 :: 聯(lián)系 :: 聚合  :: 管理
              163 Posts :: 7 Stories :: 135 Comments :: 0 Trackbacks

            常用鏈接

            留言簿(28)

            我參與的團隊

            搜索

            •  

            最新評論

            閱讀排行榜

            評論排行榜

            因為要用到調(diào)試json的解析結(jié)果,所以在這里寫了一個,結(jié)果近似json格式

            void PrintJsonList(const string & paramPre, Json::Value & paramValue)
            {
                Json::Value::Members mem = paramValue.getMemberNames();  
                for (auto iter = mem.begin(); iter != mem.end(); iter++)  
                {  
                    cout<<paramPre<<"\""<<*iter<<"\":";  
                    if (paramValue[*iter].type() == Json::objectValue)  
                    {  
                        cout<<paramPre<<"{"<<endl;  
                        PrintJsonList(paramPre + "   ", paramValue[*iter]);  
                        cout<<paramPre<<"},"<<endl;
                    }  
                    else if (paramValue[*iter].type() == Json::arrayValue)  
                    {  
                        cout<<paramPre<<"["<<endl;  
                        auto cnt = paramValue[*iter].size();  
                        for (auto i = 0; i < cnt; i++)  
                        {  
                            Json::Value & pElem = paramValue[*iter][i];
                            if (pElem.type() == Json::arrayValue)
                            {
                                cout <<paramPre<< "["<<endl;
                                PrintJsonList(paramPre + "   ", pElem);  
                                cout <<paramPre<< "],"<<endl;
                            }
                            else if (pElem.type() == Json::objectValue)
                            {
                                cout <<paramPre<< "{"<<endl;
                                PrintJsonList(paramPre + "   ", pElem);  
                                cout <<paramPre<< "},"<<endl;
                            }
                            else PrintJsonList(paramPre + "   ", pElem);  
                        }  
                        cout<<paramPre<<"]"<<endl;  
                    }  
                    else if (paramValue[*iter].type() == Json::stringValue)  
                    {  
                        cout<<"\""<<paramValue[*iter].asString()<<"\""<<endl;  
                    }  
                    else if (paramValue[*iter].type() == Json::realValue)  
                    {  
                        cout<<paramValue[*iter].asDouble()<<endl;  
                    }  
                    else if (paramValue[*iter].type() == Json::uintValue)  
                    {  
                        cout<<paramValue[*iter].asUInt()<<endl;  
                    }  
                    else
                    {  
                        cout<<paramValue[*iter].asInt()<<endl;  
                    }  
                }  
                return;  
            }
            posted on 2014-04-29 16:30 冬瓜 閱讀(2267) 評論(0)  編輯 收藏 引用 所屬分類: 原創(chuàng)
            久久九九青青国产精品| 一级a性色生活片久久无少妇一级婬片免费放 | 91精品国产高清久久久久久91| 国内精品伊人久久久久影院对白| 久久国产精品77777| 亚洲一本综合久久| 久久久久久午夜精品| 日本一区精品久久久久影院| 久久精品国产欧美日韩99热| 777米奇久久最新地址| 亚洲色欲久久久久综合网| 久久国产精品一国产精品金尊| 国产精品99久久不卡| 亚洲色婷婷综合久久| 老司机午夜网站国内精品久久久久久久久 | 人妻无码久久精品| 亚洲国产精品无码久久| 久久激情五月丁香伊人| 久久久久人妻一区精品性色av| 久久97精品久久久久久久不卡| 久久天天躁狠狠躁夜夜avapp| 青青草国产精品久久久久| 蜜臀av性久久久久蜜臀aⅴ麻豆| 精品人妻伦九区久久AAA片69| 国产亚洲色婷婷久久99精品| 无码八A片人妻少妇久久| 久久久久无码精品| 久久九九免费高清视频| 中文字幕久久欲求不满| 青青国产成人久久91网| 国产精品久久久久久一区二区三区 | 久久精品欧美日韩精品| 久久久久久亚洲精品无码| 日本久久久精品中文字幕| 精品久久久久香蕉网| 老色鬼久久亚洲AV综合| 久久Av无码精品人妻系列| 狠狠色丁香久久婷婷综合五月 | 国产精品欧美久久久久天天影视| 国产成人精品免费久久久久| 国产精品久久久久久久久|