Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
json
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
json
Commits
22127a4b
Commit
22127a4b
authored
Jan 30, 2016
by
Niels
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
moved documentation to index markdown file
parent
740239ce
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
65 additions
and
95 deletions
+65
-95
doc/Doxyfile
doc/Doxyfile
+2
-2
doc/index.md
doc/index.md
+21
-0
src/json.hpp
src/json.hpp
+17
-43
src/json.hpp.re2c
src/json.hpp.re2c
+17
-43
test/unit.cpp
test/unit.cpp
+8
-7
No files found.
doc/Doxyfile
View file @
22127a4b
...
@@ -101,7 +101,7 @@ WARN_LOGFILE =
...
@@ -101,7 +101,7 @@ WARN_LOGFILE =
#---------------------------------------------------------------------------
#---------------------------------------------------------------------------
# Configuration options related to the input files
# Configuration options related to the input files
#---------------------------------------------------------------------------
#---------------------------------------------------------------------------
INPUT = ../src/json.hpp
INPUT = ../src/json.hpp
index.md
INPUT_ENCODING = UTF-8
INPUT_ENCODING = UTF-8
FILE_PATTERNS =
FILE_PATTERNS =
RECURSIVE = NO
RECURSIVE = NO
...
@@ -117,7 +117,7 @@ INPUT_FILTER =
...
@@ -117,7 +117,7 @@ INPUT_FILTER =
FILTER_PATTERNS =
FILTER_PATTERNS =
FILTER_SOURCE_FILES = NO
FILTER_SOURCE_FILES = NO
FILTER_SOURCE_PATTERNS =
FILTER_SOURCE_PATTERNS =
USE_MDFILE_AS_MAINPAGE =
USE_MDFILE_AS_MAINPAGE =
index.md
#---------------------------------------------------------------------------
#---------------------------------------------------------------------------
# Configuration options related to source browsing
# Configuration options related to source browsing
#---------------------------------------------------------------------------
#---------------------------------------------------------------------------
...
...
doc/index.md
0 → 100644
View file @
22127a4b
# JSON for Modern C++
These pages contain the API documentation of JSON for Modern C++, a C++11 header-only JSON class.
-
@link nlohmann::basic_json
`basic_json`
class @endlink
-
Types
-
@link nlohmann::basic_json::array_t arrays @endlink
-
@link nlohmann::basic_json::object_t objects @endlink
-
@link nlohmann::basic_json::string_t strings @endlink
-
@link nlohmann::basic_json::boolean_t booleans @endlink
-
numbers
-
@link nlohmann::basic_json::number_integer_t signed integers @endlink
-
@link nlohmann::basic_json::number_unsigned_t unsigned integers @endlink
-
@link nlohmann::basic_json::number_float_t floating-point @endlink
@copyright Copyright
©
2013-2016 Niels Lohmann. The code is licensed under the
[
MIT License
](
http://opensource.org/licenses/MIT
)
.
@author
[
Niels Lohmann
](
http://nlohmann.me
)
@see https://github.com/nlohmann/json to download the source code
@version 2.0.0
src/json.hpp
View file @
22127a4b
/*!
/*
@mainpage
__ _____ _____ _____
__| | __| | | | JSON for Modern C++
These pages contain the API documentation of JSON for Modern C++, a C++11
| | |__ | | | | | | version 2.0.0
header-only JSON class.
|_____|_____|_____|_|___| https://github.com/nlohmann/json
Class @ref nlohmann::basic_json is a good entry point for the documentation.
Copyright (c) 2013-2016 Niels Lohmann <http://nlohmann.me>.
Licensed under the MIT License <http://opensource.org/licenses/MIT>.
@copyright The code is licensed under the [MIT
License](http://opensource.org/licenses/MIT):
<br>
Copyright © 2013-2016 Niels Lohmann.
<br>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
<br>
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
<br>
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@author [Niels Lohmann](http://nlohmann.me)
@see https://github.com/nlohmann/json to download the source code
@version 2.0.0
*/
*/
#ifndef NLOHMANN_JSON_HPP
#ifndef NLOHMANN_JSON_HPP
...
@@ -175,7 +148,8 @@ default)
...
@@ -175,7 +148,8 @@ default)
@note ObjectType trick from http://stackoverflow.com/a/9860911
@note ObjectType trick from http://stackoverflow.com/a/9860911
@endinternal
@endinternal
@see RFC 7159 <http://rfc7159.net/rfc7159>
@see [RFC 7159: The JavaScript Object Notation (JSON) Data Interchange
Format](http://rfc7159.net/rfc7159)
@since version 1.0.0
@since version 1.0.0
...
@@ -1405,7 +1379,7 @@ class basic_json
...
@@ -1405,7 +1379,7 @@ class basic_json
@param[in] val a floating-point value to create a JSON number from
@param[in] val a floating-point value to create a JSON number from
@note
RFC 7159 <http://www.rfc-editor.org/rfc/rfc7159.txt>
, section 6
@note
[RFC 7159](http://www.rfc-editor.org/rfc/rfc7159.txt)
, section 6
disallows NaN values:
disallows NaN values:
> Numeric values that cannot be represented in the grammar below (such
> Numeric values that cannot be represented in the grammar below (such
> as Infinity and NaN) are not permitted.
> as Infinity and NaN) are not permitted.
...
@@ -1445,7 +1419,7 @@ class basic_json
...
@@ -1445,7 +1419,7 @@ class basic_json
@param[in] val a floating-point to create a JSON number from
@param[in] val a floating-point to create a JSON number from
@note
RFC 7159 <http://www.rfc-editor.org/rfc/rfc7159.txt>
, section 6
@note
[RFC 7159](http://www.rfc-editor.org/rfc/rfc7159.txt)
, section 6
disallows NaN values:
disallows NaN values:
> Numeric values that cannot be represented in the grammar below (such
> Numeric values that cannot be represented in the grammar below (such
> as Infinity and NaN) are not permitted.
> as Infinity and NaN) are not permitted.
...
@@ -6910,7 +6884,7 @@ class basic_json
...
@@ -6910,7 +6884,7 @@ class basic_json
@brief lexical analysis
@brief lexical analysis
This class organizes the lexical analysis during JSON deserialization. The
This class organizes the lexical analysis during JSON deserialization. The
core of it is a scanner generated by
re2c <http://re2c.org>
that processes
core of it is a scanner generated by
[re2c](http://re2c.org)
that processes
a buffer and recognizes tokens according to RFC 7159.
a buffer and recognizes tokens according to RFC 7159.
*/
*/
class
lexer
class
lexer
...
@@ -7090,10 +7064,10 @@ class basic_json
...
@@ -7090,10 +7064,10 @@ class basic_json
/*!
/*!
This function implements a scanner for JSON. It is specified using
This function implements a scanner for JSON. It is specified using
regular expressions that try to follow RFC 7159 as close as possible.
regular expressions that try to follow RFC 7159 as close as possible.
These regular expressions are then translated into a
deterministic
These regular expressions are then translated into a
minimized
finite automaton (DFA) by the tool re2c <http://re2c.org>. As a result,
deterministic finite automaton (DFA) by the tool
the translated code for this function consists of a large block of code
[re2c](http://re2c.org). As a result, the translated code for this
with goto
jumps.
function consists of a large block of code with `goto`
jumps.
@return the class of the next token read from the buffer
@return the class of the next token read from the buffer
*/
*/
...
...
src/json.hpp.re2c
View file @
22127a4b
/*!
/*
@mainpage
__ _____ _____ _____
__| | __| | | | JSON for Modern C++
These pages contain the API documentation of JSON for Modern C++, a C++11
| | |__ | | | | | | version 2.0.0
header-only JSON class.
|_____|_____|_____|_|___| https://github.com/nlohmann/json
Class @ref nlohmann::basic_json is a good entry point for the documentation.
Copyright (c) 2013-2016 Niels Lohmann <http://nlohmann.me>.
Licensed under the MIT License <http://opensource.org/licenses/MIT>.
@copyright The code is licensed under the [MIT
License](http://opensource.org/licenses/MIT):
<br>
Copyright © 2013-2016 Niels Lohmann.
<br>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
<br>
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
<br>
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@author [Niels Lohmann](http://nlohmann.me)
@see https://github.com/nlohmann/json to download the source code
@version 2.0.0
*/
*/
#ifndef NLOHMANN_JSON_HPP
#ifndef NLOHMANN_JSON_HPP
...
@@ -175,7 +148,8 @@ default)
...
@@ -175,7 +148,8 @@ default)
@note ObjectType trick from http://stackoverflow.com/a/9860911
@note ObjectType trick from http://stackoverflow.com/a/9860911
@endinternal
@endinternal
@see RFC 7159 <http://rfc7159.net/rfc7159>
@see [RFC 7159: The JavaScript Object Notation (JSON) Data Interchange
Format](http://rfc7159.net/rfc7159)
@since version 1.0.0
@since version 1.0.0
...
@@ -1405,7 +1379,7 @@ class basic_json
...
@@ -1405,7 +1379,7 @@ class basic_json
@param[in] val a floating-point value to create a JSON number from
@param[in] val a floating-point value to create a JSON number from
@note
RFC 7159 <http://www.rfc-editor.org/rfc/rfc7159.txt>
, section 6
@note
[RFC 7159](http://www.rfc-editor.org/rfc/rfc7159.txt)
, section 6
disallows NaN values:
disallows NaN values:
> Numeric values that cannot be represented in the grammar below (such
> Numeric values that cannot be represented in the grammar below (such
> as Infinity and NaN) are not permitted.
> as Infinity and NaN) are not permitted.
...
@@ -1445,7 +1419,7 @@ class basic_json
...
@@ -1445,7 +1419,7 @@ class basic_json
@param[in] val a floating-point to create a JSON number from
@param[in] val a floating-point to create a JSON number from
@note
RFC 7159 <http://www.rfc-editor.org/rfc/rfc7159.txt>
, section 6
@note
[RFC 7159](http://www.rfc-editor.org/rfc/rfc7159.txt)
, section 6
disallows NaN values:
disallows NaN values:
> Numeric values that cannot be represented in the grammar below (such
> Numeric values that cannot be represented in the grammar below (such
> as Infinity and NaN) are not permitted.
> as Infinity and NaN) are not permitted.
...
@@ -6910,7 +6884,7 @@ class basic_json
...
@@ -6910,7 +6884,7 @@ class basic_json
@brief lexical analysis
@brief lexical analysis
This class organizes the lexical analysis during JSON deserialization. The
This class organizes the lexical analysis during JSON deserialization. The
core of it is a scanner generated by
re2c <http://re2c.org>
that processes
core of it is a scanner generated by
[re2c](http://re2c.org)
that processes
a buffer and recognizes tokens according to RFC 7159.
a buffer and recognizes tokens according to RFC 7159.
*/
*/
class lexer
class lexer
...
@@ -7090,10 +7064,10 @@ class basic_json
...
@@ -7090,10 +7064,10 @@ class basic_json
/*!
/*!
This function implements a scanner for JSON. It is specified using
This function implements a scanner for JSON. It is specified using
regular expressions that try to follow RFC 7159 as close as possible.
regular expressions that try to follow RFC 7159 as close as possible.
These regular expressions are then translated into a
deterministic
These regular expressions are then translated into a
minimized
finite automaton (DFA) by the tool re2c <http://re2c.org>. As a result,
deterministic finite automaton (DFA) by the tool
the translated code for this function consists of a large block of code
[re2c](http://re2c.org). As a result, the translated code for this
with goto
jumps.
function consists of a large block of code with `goto`
jumps.
@return the class of the next token read from the buffer
@return the class of the next token read from the buffer
*/
*/
...
...
test/unit.cpp
View file @
22127a4b
/*!
/*
@file
__ _____ _____ _____
@copyright The code is licensed under the MIT License
__| | __| | | | JSON for Modern C++ (test suite)
<http://opensource.org/licenses/MIT>,
| | |__ | | | | | | version 2.0.0
Copyright (c) 2013-2015 Niels Lohmann.
|_____|_____|_____|_|___| https://github.com/nlohmann/json
@author Niels Lohmann <http://nlohmann.me>
@see https://github.com/nlohmann/json
Copyright (c) 2013-2016 Niels Lohmann <http://nlohmann.me>.
Licensed under the MIT License <http://opensource.org/licenses/MIT>.
*/
*/
#define CATCH_CONFIG_MAIN
#define CATCH_CONFIG_MAIN
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment