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
3cdc4d78
Unverified
Commit
3cdc4d78
authored
May 27, 2018
by
Niels Lohmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
📝
added documentation
parent
adf09726
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
0 deletions
+36
-0
include/nlohmann/detail/input/json_sax.hpp
include/nlohmann/detail/input/json_sax.hpp
+18
-0
single_include/nlohmann/json.hpp
single_include/nlohmann/json.hpp
+18
-0
No files found.
include/nlohmann/detail/input/json_sax.hpp
View file @
3cdc4d78
...
...
@@ -122,6 +122,19 @@ struct json_sax
namespace
detail
{
/*!
@brief SAX implementation to create a JSON value from SAX events
This class implements the @ref json_sax interface and processes the SAX events
to create a JSON value which makes it basically a DOM parser. The structure or
hierarchy of the JSON value is managed by the stack `ref_stack` which contains
a pointer to the respective array or object for each recursion depth.
After successful parsing, the value that is passed by reference to the
constructor contains the parsed value.
@tparam BasicJsonType the JSON type
*/
template
<
typename
BasicJsonType
>
class
json_sax_dom_parser
:
public
json_sax
<
BasicJsonType
>
{
...
...
@@ -131,6 +144,11 @@ class json_sax_dom_parser : public json_sax<BasicJsonType>
using
number_float_t
=
typename
BasicJsonType
::
number_float_t
;
using
string_t
=
typename
BasicJsonType
::
string_t
;
/*!
@param[in, out] r reference to a JSON value that is manipulated while
parsing
@param[in] allow_exceptions_ whether parse errors yield exceptions
*/
json_sax_dom_parser
(
BasicJsonType
&
r
,
const
bool
allow_exceptions_
=
true
)
:
root
(
r
),
allow_exceptions
(
allow_exceptions_
)
{}
...
...
single_include/nlohmann/json.hpp
View file @
3cdc4d78
...
...
@@ -3426,6 +3426,19 @@ struct json_sax
namespace
detail
{
/*!
@brief SAX implementation to create a JSON value from SAX events
This class implements the @ref json_sax interface and processes the SAX events
to create a JSON value which makes it basically a DOM parser. The structure or
hierarchy of the JSON value is managed by the stack `ref_stack` which contains
a pointer to the respective array or object for each recursion depth.
After successful parsing, the value that is passed by reference to the
constructor contains the parsed value.
@tparam BasicJsonType the JSON type
*/
template
<
typename
BasicJsonType
>
class
json_sax_dom_parser
:
public
json_sax
<
BasicJsonType
>
{
...
...
@@ -3435,6 +3448,11 @@ class json_sax_dom_parser : public json_sax<BasicJsonType>
using
number_float_t
=
typename
BasicJsonType
::
number_float_t
;
using
string_t
=
typename
BasicJsonType
::
string_t
;
/*!
@param[in, out] r reference to a JSON value that is manipulated while
parsing
@param[in] allow_exceptions_ whether parse errors yield exceptions
*/
json_sax_dom_parser
(
BasicJsonType
&
r
,
const
bool
allow_exceptions_
=
true
)
:
root
(
r
),
allow_exceptions
(
allow_exceptions_
)
{}
...
...
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