• 大小: 2.78MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-09-08
  • 语言: C/C++
  • 标签: qt  c++  webQQ  

资源简介

调用腾讯web接口,实现的高仿QQ。可以和腾讯QQ进行互通互联

资源截图

代码片段和文件信息

// Copyright 2007-2010 Baptiste Lepilleur
// 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(JSON_IS_AMALGAMATION)
# include 
# include 
# include “json_tool.h“
#endif // if !defined(JSON_IS_AMALGAMATION)
#include 
#include 
#include 
#include 
#include 
#include 

#if _MSC_VER >= 1400 // VC++ 8.0
#pragma warning( disable : 4996 )   // disable warning about strdup being deprecated.
#endif

namespace Json {

// Implementation of class Features
// ////////////////////////////////

Features::Features()
   : allowComments_( true )
    strictRoot_( false )
{
}


Features 
Features::all()
{
   return Features();
}


Features 
Features::strictMode()
{
   Features features;
   features.allowComments_ = false;
   features.strictRoot_ = true;
   return features;
}

// Implementation of class Reader
// ////////////////////////////////


static inline bool 
in( Reader::Char c Reader::Char c1 Reader::Char c2 Reader::Char c3 Reader::Char c4 )
{
   return c == c1  ||  c == c2  ||  c == c3  ||  c == c4;
}

static inline bool 
in( Reader::Char c Reader::Char c1 Reader::Char c2 Reader::Char c3 Reader::Char c4 Reader::Char c5 )
{
   return c == c1  ||  c == c2  ||  c == c3  ||  c == c4  ||  c == c5;
}


static bool 
containsNewLine( Reader::Location begin 
                 Reader::Location end )
{
   for ( ;begin < end; ++begin )
      if ( *begin == ‘\n‘  ||  *begin == ‘\r‘ )
         return true;
   return false;
}


// Class Reader
// //////////////////////////////////////////////////////////////////

Reader::Reader()
   : features_( Features::all() )
{
}


Reader::Reader( const Features &features )
   : features_( features )
{
}


bool
Reader::parse( const std::string &document 
               Value &root
               bool collectComments )
{
   document_ = document;
   const char *begin = document_.c_str();
   const char *end = begin + document_.length();
   return parse( begin end root collectComments );
}


bool
Reader::parse( std::istream& sin
               Value &root
               bool collectComments )
{
   //std::istream_iterator begin(sin);
   //std::istream_iterator end;
   // Those would allow streamed input from a file if parse() were a
   // template function.

   // Since std::string is reference-counted this at least does not
   // create an extra copy.
   std::string doc;
   std::getline(sin doc (char)EOF);
   return parse( doc root collectComments );
}

bool 
Reader::parse( const char *beginDoc const char *endDoc 
               Value &root
               bool collectComments )
{
   if ( !features_.allowComments_ )
   {
      collectComments = false;
   }

   begin_ = beginDoc;
   end_ = endDoc;
   collectComments_ = collectComments;
   current_ = begin_;
   lastValueEnd_ = 0

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2013-04-20 10:08  Qtqq-master\
     文件          46  2013-04-20 10:08  Qtqq-master\.gitignore
     目录           0  2013-04-20 10:08  Qtqq-master\3rdparty\
     文件          87  2013-04-20 10:08  Qtqq-master\3rdparty\CMakeLists.txt
     目录           0  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\
     文件          22  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\CMakeLists.txt
     文件        2665  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\LICENSE
     目录           0  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\
     目录           0  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\
     文件         664  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\autolink.h
     文件        3481  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\config.h
     文件        1595  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\features.h
     文件        1001  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\forwards.h
     文件         426  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\json.h
     文件        7475  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\reader.h
     文件       35591  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\value.h
     文件        6679  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\include\json\writer.h
     目录           0  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\
     文件          27  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\CMakeLists.txt
     目录           0  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\
     文件         458  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\CMakeLists.txt
     文件        4155  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_batchallocator.h
     文件       12895  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_internalarray.inl
     文件       16500  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_internalmap.inl
     文件       21184  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_reader.cpp
     文件        2477  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_tool.h
     文件       42038  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_value.cpp
     文件        7592  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_valueiterator.inl
     文件       20689  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\json_writer.cpp
     文件         154  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\src\lib_json\sconscript
     文件           9  2013-04-20 10:08  Qtqq-master\3rdparty\jsoncpp\version
............此处省略918个文件信息

评论

共有 条评论