summaryrefslogtreecommitdiffstats
path: root/src/corelib/json/qjsonparser.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Doc: Add \inmodule QtCore to all QtCore class doc bodiesThiago Macieira2012-08-231-0/+1
| | | | | Change-Id: I19100755c97cc155c76a859e19940e9f9222d34e Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* Fixed most qdoc errors for the json classes.Lars Knoll2012-07-201-0/+20
| | | | | | Change-Id: Ibbbdd7212f6c5e25422bbaa9ccaf4822db52222a Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com> Reviewed-by: Richard J. Moore <rich@kde.org>
* Fix some spelling errorsSergio Ahumada2012-07-111-1/+1
| | | | | | Change-Id: I19d3b2e9a5180b13deb828b55195404ef20be295 Reviewed-by: Daniel Teske <daniel.teske@nokia.com> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Limit the nesting depth of the Json parserLars Knoll2012-05-161-2/+43
| | | | | | | | | | | | | | | The parser is recursive and too deeply nested json would cause it to exhaust the available stack space leading to crashes. We now abort parsing with a DeepNesting parse error if the document is too deeply nested. The current nesting limit is set to 1024, which should be more then enough for any real JSON data set. Change-Id: I4adea3fd727149f7342536d73cf4530361a0a3a1 Reviewed-by: Jamey Hicks <jamey.hicks@nokia.com> Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
* QChar: add isSurrogate() and isNonCharacter() to the public APIKonstantin Ritt2012-05-161-3/+2
| | | | | | | | + QChar::LastValidCodePoint enum value that supercede the UNICODE_LAST_CODEPOINT macro replace uses of hardcoded values with the new API; remove leftovers Change-Id: I1395c9840b85fcb6b08e241b131794a98773c952 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Correctly parse json documents with a leading BOMLars Knoll2012-05-101-2/+14
| | | | | | | | A leading byte order mark is valid in utf-8 and we should parse documents starting with those correctly. Change-Id: Id85398ff6e05b93ceefbaf4a6de5571d5e61ca13 Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
* add some useful methods to QUnicodeTables::Konstantin Ritt2012-05-101-14/+2
| | | | | | | in order to reduce code duplication and prepare the ground for upcoming changes Change-Id: I980244149f65384c9484bbec4682de8b7b848b08 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* replace hardcoded values with a surrogate handling methodsKonstantin Ritt2012-04-131-3/+4
| | | | | | Change-Id: Ib41e08d835f2e8ca2e32b4025c6f5a99840f2e27 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* fix QUtf8 codec to disallow codes in range [U+fdd0..U+fdef]Konstantin Ritt2012-04-111-1/+1
| | | | | | | | | 0xfdef-0xfdd0 is definitely 31 and not 15 :) also fix all copy-pastes of this code (greping for '0xfdd0' helps ;) Change-Id: I8f3bd4fd9d85f9de066f0f5df378b9188c12bd48 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
* Fix warnings about truncations in constants.Friedemann Kleint2012-04-031-1/+1
| | | | | Change-Id: I46872c5b2866454112092c1ec5efbfe15db5af33 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QJsonParseError improvementsAlexei Rousskikh2012-03-271-7/+84
| | | | | | | | - added human-readable error message - improved enum value names Change-Id: I86d4bb419f9581f85d61b6e090048f1943017f9e Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Trailing comma should result in an error during JSON parsingAlexei Rousskikh2012-03-121-0/+7
| | | | | | | | | 1. QJsonParseError::MissingObject defined 2. QJsonDocument::fromJson() will result in defined error after parsing of something like "{ 'key':1 , }" or "[ {'key':1}, ]" Change-Id: I8e6234a03b8aca4e5ad6180f273f91066b86d7a1 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fix parsing of unicode escape sequencesLars Knoll2012-03-071-2/+2
| | | | | Change-Id: I63a7cd3a571fb47c97157bcb2ca29c4239c600ba Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Added error reporting to QJsonParserAndrew Christian2012-02-181-19/+61
| | | | | Change-Id: Ib2390c0faf1ed7ada3fc185abce83740ad112929 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Update contact address in license headers.Jason McDonald2012-01-311-1/+1
| | | | | Change-Id: I35bf916087511f26bfeb49ceb3256d9a20fbc1c0 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Import json support from playground/qtbinaryjsonLars Knoll2012-01-241-0/+752
This imports the JSON support for Qt 5 from playground/qtbinaryjson. It adds a fast, fully compliant json parser, a convenient C++ API, conversion to and from QVariants and a binary format for JSON that is extremely fast to use together with the C++ API. Change-Id: If9e3a21a4241d388d0abaa446b6824f9cc6edb1c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>