ian@0: // Copyright 2007-2010 Baptiste Lepilleur ian@0: // Distributed under MIT license, or public domain if desired and ian@0: // recognized in your jurisdiction. ian@0: // See file LICENSE for detail or copy at http://jsoncpp.sourceforge.net/LICENSE ian@0: ian@0: #ifndef JSON_CONFIG_H_INCLUDED ian@0: # define JSON_CONFIG_H_INCLUDED ian@0: ian@0: /// If defined, indicates that json library is embedded in CppTL library. ian@0: //# define JSON_IN_CPPTL 1 ian@0: ian@0: /// If defined, indicates that json may leverage CppTL library ian@0: //# define JSON_USE_CPPTL 1 ian@0: /// If defined, indicates that cpptl vector based map should be used instead of std::map ian@0: /// as Value container. ian@0: //# define JSON_USE_CPPTL_SMALLMAP 1 ian@0: /// If defined, indicates that Json specific container should be used ian@0: /// (hash table & simple deque container with customizable allocator). ian@0: /// THIS FEATURE IS STILL EXPERIMENTAL! There is know bugs: See #3177332 ian@0: //# define JSON_VALUE_USE_INTERNAL_MAP 1 ian@0: /// Force usage of standard new/malloc based allocator instead of memory pool based allocator. ian@0: /// The memory pools allocator used optimization (initializing Value and ValueInternalLink ian@0: /// as if it was a POD) that may cause some validation tool to report errors. ian@0: /// Only has effects if JSON_VALUE_USE_INTERNAL_MAP is defined. ian@0: //# define JSON_USE_SIMPLE_INTERNAL_ALLOCATOR 1 ian@0: ian@0: /// If defined, indicates that Json use exception to report invalid type manipulation ian@0: /// instead of C assert macro. ian@0: # define JSON_USE_EXCEPTION 1 ian@0: ian@0: /// If defined, indicates that the source file is amalgated ian@0: /// to prevent private header inclusion. ian@0: /// Remarks: it is automatically defined in the generated amalgated header. ian@0: // #define JSON_IS_AMALGAMATION ian@0: ian@0: ian@0: # ifdef JSON_IN_CPPTL ian@0: # include ian@0: # ifndef JSON_USE_CPPTL ian@0: # define JSON_USE_CPPTL 1 ian@0: # endif ian@0: # endif ian@0: ian@0: # ifdef JSON_IN_CPPTL ian@0: # define JSON_API CPPTL_API ian@0: # elif defined(JSON_DLL_BUILD) ian@0: # define JSON_API __declspec(dllexport) ian@0: # elif defined(JSON_DLL) ian@0: # define JSON_API __declspec(dllimport) ian@0: # else ian@0: # define JSON_API ian@0: # endif ian@0: ian@0: // If JSON_NO_INT64 is defined, then Json only support C++ "int" type for integer ian@0: // Storages, and 64 bits integer support is disabled. ian@0: // #define JSON_NO_INT64 1 ian@0: ian@0: #if defined(_MSC_VER) && _MSC_VER <= 1200 // MSVC 6 ian@0: // Microsoft Visual Studio 6 only support conversion from __int64 to double ian@0: // (no conversion from unsigned __int64). ian@0: #define JSON_USE_INT64_DOUBLE_CONVERSION 1 ian@0: #endif // if defined(_MSC_VER) && _MSC_VER < 1200 // MSVC 6 ian@0: ian@0: #if defined(_MSC_VER) && _MSC_VER >= 1500 // MSVC 2008 ian@0: /// Indicates that the following function is deprecated. ian@0: # define JSONCPP_DEPRECATED(message) __declspec(deprecated(message)) ian@0: #endif ian@0: ian@0: #if !defined(JSONCPP_DEPRECATED) ian@0: # define JSONCPP_DEPRECATED(message) ian@0: #endif // if !defined(JSONCPP_DEPRECATED) ian@0: ian@0: namespace Json { ian@0: typedef int Int; ian@0: typedef unsigned int UInt; ian@0: # if defined(JSON_NO_INT64) ian@0: typedef int LargestInt; ian@0: typedef unsigned int LargestUInt; ian@0: # undef JSON_HAS_INT64 ian@0: # else // if defined(JSON_NO_INT64) ian@0: // For Microsoft Visual use specific types as long long is not supported ian@0: # if defined(_MSC_VER) // Microsoft Visual Studio ian@0: typedef __int64 Int64; ian@0: typedef unsigned __int64 UInt64; ian@0: # else // if defined(_MSC_VER) // Other platforms, use long long ian@0: typedef long long int Int64; ian@0: typedef unsigned long long int UInt64; ian@0: # endif // if defined(_MSC_VER) ian@0: typedef Int64 LargestInt; ian@0: typedef UInt64 LargestUInt; ian@0: # define JSON_HAS_INT64 ian@0: # endif // if defined(JSON_NO_INT64) ian@0: } // end namespace Json ian@0: ian@0: ian@0: #endif // JSON_CONFIG_H_INCLUDED