Skip to content

Commit d0f690f

Browse files
author
a-pavlov
committed
2 parents 4a3a80c + e2591bd commit d0f690f

File tree

8 files changed

+426
-1038
lines changed

8 files changed

+426
-1038
lines changed

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# OS X files
2+
.DS_Store
3+
14
# Compiled Object files
25
*.slo
36
*.lo
@@ -26,3 +29,7 @@
2629
*.exe
2730
*.out
2831
*.app
32+
33+
# Generated and working files and directories
34+
tests/run_tests
35+
build

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
language: cpp
2+
before_script: mkdir build
3+
script: cd build && cmake .. && make

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# [Labs64 NetLicensing](http://netlicensing.io) Client (C++)
22

3+
[![Build Status](https://travis-ci.org/Labs64/NetLicensingClient-cpp.svg?branch=master)](https://travis-ci.org/Labs64/NetLicensingClient-cpp)
4+
35
C++ wrapper for Labs64 NetLicensing [RESTful API](http://l64.cc/nl10)
46

57
Visit Labs64 NetLicensing at http://netlicensing.io

include/json/json-forwards.h

Lines changed: 24 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,6 @@ license you like.
9090

9191
#ifndef JSON_CONFIG_H_INCLUDED
9292
#define JSON_CONFIG_H_INCLUDED
93-
#include <stddef.h>
94-
#include <string> //typdef String
9593

9694
/// If defined, indicates that json library is embedded in CppTL library.
9795
//# define JSON_IN_CPPTL 1
@@ -124,12 +122,12 @@ license you like.
124122
#ifdef JSON_IN_CPPTL
125123
#define JSON_API CPPTL_API
126124
#elif defined(JSON_DLL_BUILD)
127-
#if defined(_MSC_VER) || defined(__MINGW32__)
125+
#if defined(_MSC_VER)
128126
#define JSON_API __declspec(dllexport)
129127
#define JSONCPP_DISABLE_DLL_INTERFACE_WARNING
130128
#endif // if defined(_MSC_VER)
131129
#elif defined(JSON_DLL)
132-
#if defined(_MSC_VER) || defined(__MINGW32__)
130+
#if defined(_MSC_VER)
133131
#define JSON_API __declspec(dllimport)
134132
#define JSONCPP_DISABLE_DLL_INTERFACE_WARNING
135133
#endif // if defined(_MSC_VER)
@@ -143,83 +141,34 @@ license you like.
143141
// Storages, and 64 bits integer support is disabled.
144142
// #define JSON_NO_INT64 1
145143

146-
#if defined(_MSC_VER) // MSVC
147-
# if _MSC_VER <= 1200 // MSVC 6
148-
// Microsoft Visual Studio 6 only support conversion from __int64 to double
149-
// (no conversion from unsigned __int64).
150-
# define JSON_USE_INT64_DOUBLE_CONVERSION 1
151-
// Disable warning 4786 for VS6 caused by STL (identifier was truncated to '255'
152-
// characters in the debug information)
153-
// All projects I've ever seen with VS6 were using this globally (not bothering
154-
// with pragma push/pop).
155-
# pragma warning(disable : 4786)
156-
# endif // MSVC 6
157-
158-
# if _MSC_VER >= 1500 // MSVC 2008
159-
/// Indicates that the following function is deprecated.
160-
# define JSONCPP_DEPRECATED(message) __declspec(deprecated(message))
161-
# endif
162-
163-
#endif // defined(_MSC_VER)
164-
165-
#if defined(_MSC_VER) && _MSC_VER <= 1600 // MSVC <= 2010
166-
# define JSONCPP_OVERRIDE
167-
#else
168-
# define JSONCPP_OVERRIDE override
169-
#endif // MSVC <= 2010
170-
171-
172-
#ifndef JSON_HAS_RVALUE_REFERENCES
173-
174-
#if defined(_MSC_VER) && _MSC_VER >= 1600 // MSVC >= 2010
175-
#define JSON_HAS_RVALUE_REFERENCES 1
176-
#endif // MSVC >= 2010
177-
178-
#ifdef __clang__
179-
#if __has_feature(cxx_rvalue_references)
180-
#define JSON_HAS_RVALUE_REFERENCES 1
181-
#endif // has_feature
182-
183-
#elif defined __GNUC__ // not clang (gcc comes later since clang emulates gcc)
184-
#if defined(__GXX_EXPERIMENTAL_CXX0X__) || (__cplusplus >= 201103L)
185-
#define JSON_HAS_RVALUE_REFERENCES 1
186-
#endif // GXX_EXPERIMENTAL
187-
188-
#endif // __clang__ || __GNUC__
189-
190-
#endif // not defined JSON_HAS_RVALUE_REFERENCES
191-
192-
#ifndef JSON_HAS_RVALUE_REFERENCES
193-
#define JSON_HAS_RVALUE_REFERENCES 0
144+
#if defined(_MSC_VER) && _MSC_VER <= 1200 // MSVC 6
145+
// Microsoft Visual Studio 6 only support conversion from __int64 to double
146+
// (no conversion from unsigned __int64).
147+
#define JSON_USE_INT64_DOUBLE_CONVERSION 1
148+
// Disable warning 4786 for VS6 caused by STL (identifier was truncated to '255'
149+
// characters in the debug information)
150+
// All projects I've ever seen with VS6 were using this globally (not bothering
151+
// with pragma push/pop).
152+
#pragma warning(disable : 4786)
153+
#endif // if defined(_MSC_VER) && _MSC_VER < 1200 // MSVC 6
154+
155+
#if defined(_MSC_VER) && _MSC_VER >= 1500 // MSVC 2008
156+
/// Indicates that the following function is deprecated.
157+
#define JSONCPP_DEPRECATED(message) __declspec(deprecated(message))
158+
#elif defined(__clang__) && defined(__has_feature)
159+
#if __has_feature(attribute_deprecated_with_message)
160+
#define JSONCPP_DEPRECATED(message) __attribute__ ((deprecated(message)))
161+
#endif
162+
#elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 5))
163+
#define JSONCPP_DEPRECATED(message) __attribute__ ((deprecated(message)))
164+
#elif defined(__GNUC__) && (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1))
165+
#define JSONCPP_DEPRECATED(message) __attribute__((__deprecated__))
194166
#endif
195-
196-
#ifdef __clang__
197-
#elif defined __GNUC__ // not clang (gcc comes later since clang emulates gcc)
198-
# if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 5))
199-
# define JSONCPP_DEPRECATED(message) __attribute__ ((deprecated(message)))
200-
# elif (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1))
201-
# define JSONCPP_DEPRECATED(message) __attribute__((__deprecated__))
202-
# endif // GNUC version
203-
#endif // __clang__ || __GNUC__
204167

205168
#if !defined(JSONCPP_DEPRECATED)
206169
#define JSONCPP_DEPRECATED(message)
207170
#endif // if !defined(JSONCPP_DEPRECATED)
208171

209-
#if __GNUC__ >= 6
210-
# define JSON_USE_INT64_DOUBLE_CONVERSION 1
211-
#endif
212-
213-
#if !defined(JSON_IS_AMALGAMATION)
214-
215-
# include "version.h"
216-
217-
# if JSONCPP_USING_SECURE_MEMORY
218-
# include "allocator.h" //typedef Allocator
219-
# endif
220-
221-
#endif // if !defined(JSON_IS_AMALGAMATION)
222-
223172
namespace Json {
224173
typedef int Int;
225174
typedef unsigned int UInt;
@@ -240,19 +189,6 @@ typedef Int64 LargestInt;
240189
typedef UInt64 LargestUInt;
241190
#define JSON_HAS_INT64
242191
#endif // if defined(JSON_NO_INT64)
243-
#if JSONCPP_USING_SECURE_MEMORY
244-
#define JSONCPP_STRING std::basic_string<char, std::char_traits<char>, Json::SecureAllocator<char> >
245-
#define JSONCPP_OSTRINGSTREAM std::basic_ostringstream<char, std::char_traits<char>, Json::SecureAllocator<char> >
246-
#define JSONCPP_OSTREAM std::basic_ostream<char, std::char_traits<char>>
247-
#define JSONCPP_ISTRINGSTREAM std::basic_istringstream<char, std::char_traits<char>, Json::SecureAllocator<char> >
248-
#define JSONCPP_ISTREAM std::istream
249-
#else
250-
#define JSONCPP_STRING std::string
251-
#define JSONCPP_OSTRINGSTREAM std::ostringstream
252-
#define JSONCPP_OSTREAM std::ostream
253-
#define JSONCPP_ISTRINGSTREAM std::istringstream
254-
#define JSONCPP_ISTREAM std::istream
255-
#endif // if JSONCPP_USING_SECURE_MEMORY
256192
} // end namespace Json
257193

258194
#endif // JSON_CONFIG_H_INCLUDED

0 commit comments

Comments
 (0)