91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 78KB
    文件類型: .zip
    金幣: 2
    下載: 1 次
    發(fā)布日期: 2021-05-19
  • 語言: 其他
  • 標(biāo)簽: jsoncpp??1.8.??

資源簡介

jsoncpp1.8.4 修改對json項大小寫敏感的比較,可自定義選擇是否需要大小寫敏感 修改json輸出自動排序的規(guī)則,可自定義選擇是否需要自動排序 新增json無格式化輸出方法

資源截圖

代碼片段和文件信息

//?Copyright?2007-2010?Baptiste?Lepilleur?and?The?JsonCpp?Authors
//?Distributed?under?MIT?license?or?public?domain?if?desired?and
//?recognized?in?your?jurisdiction.
//?See?file?LICENSE?for?detail?or?copy?at?http://jsoncpp.sourceforge.net/LICENSE

#if?defined(__GNUC__)
#pragma?GCC?diagnostic?push
#pragma?GCC?diagnostic?ignored?“-Wdeprecated-declarations“
#elif?defined(_MSC_VER)
#pragma?warning(disable?:?4996)
#endif

/*?This?executable?is?used?for?testing?parser/writer?using?real?JSON?files.
?*/

#include??//?sort
#include?
#include?
#include?

struct?Options?{
??JSONCPP_STRING?path;
??Json::Features?features;
??bool?parseOnly;
??typedef?JSONCPP_STRING?(*writeFuncType)(Json::Value?const&);
??writeFuncType?write;
};

static?JSONCPP_STRING?normalizeFloatingPointStr(double?value)?{
??char?buffer[32];
#if?defined(_MSC_VER)?&&?defined(__STDC_SECURE_LIB__)
??sprintf_s(buffer?sizeof(buffer)?“%.16g“?value);
#else
??snprintf(buffer?sizeof(buffer)?“%.16g“?value);
#endif
??buffer[sizeof(buffer)?-?1]?=?0;
??JSONCPP_STRING?s(buffer);
??JSONCPP_STRING::size_type?index?=?s.find_last_of(“eE“);
??if?(index?!=?JSONCPP_STRING::npos)?{
????JSONCPP_STRING::size_type?hasSign?=
????????(s[index?+?1]?==?‘+‘?||?s[index?+?1]?==?‘-‘)???1?:?0;
????JSONCPP_STRING::size_type?exponentStartIndex?=?index?+?1?+?hasSign;
????JSONCPP_STRING?normalized?=?s.substr(0?exponentStartIndex);
????JSONCPP_STRING::size_type?indexDigit?=
????????s.find_first_not_of(‘0‘?exponentStartIndex);
????JSONCPP_STRING?exponent?=?“0“;
????if?(indexDigit?!=?JSONCPP_STRING::npos)?//?There?is?an?exponent?different
????????????????????????????????????????????//?from?0
????{
??????exponent?=?s.substr(indexDigit);
????}
????return?normalized?+?exponent;
??}
??return?s;
}

static?JSONCPP_STRING?readInputTestFile(const?char*?path)?{
??FILE*?file?=?fopen(path?“rb“);
??if?(!file)
????return?JSONCPP_STRING(““);
??fseek(file?0?SEEK_END);
??long?const?size?=?ftell(file);
??unsigned?long?const?usize?=?static_cast(size);
??fseek(file?0?SEEK_SET);
??JSONCPP_STRING?text;
??char*?buffer?=?new?char[size?+?1];
??buffer[size]?=?0;
??if?(fread(buffer?1?usize?file)?==?usize)
????text?=?buffer;
??fclose(file);
??delete[]?buffer;
??return?text;
}

static?void?printValueTree(FILE*?fout
???????????????????????????Json::Value&?value
???????????????????????????const?JSONCPP_STRING&?path?=?“.“)?{
??if?(value.hasComment(Json::commentBefore))?{
????fprintf(fout?“%s\n“?value.getComment(Json::commentBefore).c_str());
??}
??switch?(value.type())?{
??case?Json::nullValue:
????fprintf(fout?“%s=null\n“?path.c_str());
????break;
??case?Json::intValue:
????fprintf(fout?“%s=%s\n“?path.c_str()
????????????Json::valueToString(value.asLargestInt()).c_str());
????break;
??case?Json::uintValue:
????fprintf(fout?“%s=%s\n“?path.c_str()
????????????Json::valueToString(value.asLargestUInt()).c_str());
????break;
??case?Json::realValue:
????fprintf(fout?“%s=%s\n“?pa

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-11-13?10:46??jsoncpp\1.8.4\
?????目錄???????????0??2018-11-13?10:46??jsoncpp\1.8.4\include\
?????文件?????????113??2018-11-13?10:46??jsoncpp\1.8.4\include\CMakeLists.txt
?????目錄???????????0??2018-12-12?13:17??jsoncpp\1.8.4\include\json\
?????文件????????2499??2018-11-13?10:46??jsoncpp\1.8.4\include\json\allocator.h
?????文件????????2644??2018-11-13?10:46??jsoncpp\1.8.4\include\json\assertions.h
?????文件?????????686??2018-11-13?10:46??jsoncpp\1.8.4\include\json\autolink.h
?????文件????????6820??2018-11-13?10:46??jsoncpp\1.8.4\include\json\config.h
?????文件????????1784??2018-11-13?10:46??jsoncpp\1.8.4\include\json\features.h
?????文件?????????782??2018-11-13?10:46??jsoncpp\1.8.4\include\json\forwards.h
?????文件?????????444??2018-11-13?10:46??jsoncpp\1.8.4\include\json\json.h
?????文件???????13977??2018-11-13?10:46??jsoncpp\1.8.4\include\json\reader.h
?????文件???????29382??2018-12-12?13:17??jsoncpp\1.8.4\include\json\value.h
?????文件?????????786??2018-11-13?10:46??jsoncpp\1.8.4\include\json\version.h
?????文件???????12398??2018-11-13?10:54??jsoncpp\1.8.4\include\json\writer.h
?????目錄???????????0??2018-11-13?09:25??jsoncpp\1.8.4\src\
?????目錄???????????0??2018-11-13?09:29??jsoncpp\1.8.4\src\jsontestrunner\
?????文件????????9871??2018-11-13?09:25??jsoncpp\1.8.4\src\jsontestrunner\main.cpp
?????目錄???????????0??2018-12-12?14:01??jsoncpp\1.8.4\src\lib_json\
?????文件???????59211??2018-11-13?09:25??jsoncpp\1.8.4\src\lib_json\json_reader.cpp
?????文件????????3828??2018-11-13?09:25??jsoncpp\1.8.4\src\lib_json\json_tool.h
?????文件???????52100??2018-12-12?14:01??jsoncpp\1.8.4\src\lib_json\json_value.cpp
?????文件????????5272??2018-11-13?09:25??jsoncpp\1.8.4\src\lib_json\json_valueiterator.inl
?????文件???????38028??2018-12-11?13:01??jsoncpp\1.8.4\src\lib_json\json_writer.cpp
?????文件????????2646??2018-12-12?14:34??jsoncpp\1.8.4\src\lib_json\test.cpp
?????文件?????????826??2018-11-13?09:25??jsoncpp\1.8.4\src\lib_json\version.h.in
?????目錄???????????0??2018-11-13?09:29??jsoncpp\1.8.4\src\test_lib_json\
?????文件???????12767??2018-11-13?09:25??jsoncpp\1.8.4\src\test_lib_json\jsontest.cpp
?????文件???????10819??2018-11-13?09:25??jsoncpp\1.8.4\src\test_lib_json\jsontest.h
?????文件???????93546??2018-11-13?09:25??jsoncpp\1.8.4\src\test_lib_json\main.cpp
?????文件??????????76??2018-12-12?14:38??jsoncpp\編譯說明.txt
............此處省略0個文件信息

評論

共有 條評論