1
0
Fork 0
mirror of https://github.com/ethauvin/JSON-java.git synced 2025-06-17 07:50:52 -07:00
Commit graph

790 commits

Author SHA1 Message Date
Sean Leary
cbd8b18c4a Update README 2017-05-16 00:29:00 -05:00
Sean Leary
c945b53308 Merge pull request #69 from johnjaylward/TestCleanup
Couple of the files were difficult to identify the changes, but it was worth it to add the new tests. Thanks!!!
2017-04-28 01:04:56 -05:00
John J. Aylward
c233ae709e comment out second unreliable test 2017-04-27 12:52:02 -04:00
John J. Aylward
95da4246a2 fix spelling in comment 2017-04-27 12:48:43 -04:00
John J. Aylward
9df5d34bbe * Update link in the README to the main JSON-Java repo
* Cleans up some warnings
* Adds new test for bug https://github.com/stleary/JSON-java/issues/332
* Adds some resource handling for string writers using pre-java1.7
support. I know StringWriters don't need a close method called, but the
tests should still handle their resources properly.
2017-04-27 12:39:42 -04:00
Sean Leary
f12fa9ba5f Update LICENSE 2017-04-18 08:32:10 -05:00
John J. Aylward
ae1e9e2b6a fix spelling in javadoc comment 2017-04-03 11:59:36 -04:00
Sean Leary
f6ab6d7b27 Merge pull request #68 from stleary/jsonpointer-query
unit tests for query-by-JSONPointer
2017-03-27 20:05:05 -05:00
Sean Leary
80e2ea2a80 Merge pull request #324 from dtalex/JSONPointerOnBeans
Allow user to invoke query and optQuery ,with a JSONPointer
2017-03-27 20:04:18 -05:00
stleary
d1a5f15f0c unit tests for query-by-JSONPointer 2017-03-26 15:03:09 -05:00
Sean Leary
82ff14ed8d Merge pull request #66 from stleary/document-unquoted-strings
add a test for unquoted values
2017-02-26 11:10:38 -06:00
stleary
e41972a574 add a test for unquoted values 2017-02-26 11:09:41 -06:00
alessandro rao
2917104b53 Allow user to invoke query and optQuery ,with a JSONPointer,directly
from JSONArray or JSONObject fix JSONArray
2017-02-25 14:35:02 +01:00
alessandro rao
9e0fc5e680 Allow user to invoke query and optQuery ,with a JSONPointer,directly
from JSONArray or JSONObject
2017-02-25 13:27:50 +01:00
Sean Leary
a66abf22a8 Merge pull request #64 from stleary/locale-tests-for-non-EN-keys
Locale tests for non en keys
2017-02-19 21:34:40 -06:00
Sean Leary
724fb888f7 Merge pull request #317 from johnjaylward/fixLocale
make sure locale independent data is not upper/lowercased incorrectly…
2017-02-19 21:34:17 -06:00
stleary
f41e1d012a tests for locale-independent keys 2017-02-16 20:49:37 -06:00
stleary
928179a1f3 locale tests 2017-02-14 08:30:22 -06:00
John J. Aylward
eb806f4c14 make sure locale independent data is not upper/lowercased incorrectly. See #315 2017-02-10 10:07:28 -05:00
Sean Leary
5ff8b4cb08 Merge pull request #304 from omarzina/master
[FIX] Update README
2016-12-05 08:58:35 -06:00
joumar
5ef4f58ef1 [FIX] Update README
Fixed C&P typo
2016-12-05 11:55:24 -03:00
Sean Leary
413bb53b48 Merge pull request #288 from johnjaylward/XmlEscape
Bug fixes for XML Encoding and Decoding
2016-11-24 10:01:14 -06:00
Sean Leary
df9c27c53f Merge pull request #62 from erosb/master
testcase for stleary/JSON-java#292
2016-10-08 10:07:53 -05:00
Sean Leary
237376eca6 Merge pull request #292 from erosb/master
Provides "#" string evaluation support for JSON Pointer
2016-10-08 10:07:31 -05:00
Bence Erős
97e3d6c7ce testcase for stleary/JSON-java#292 and adding .idea to .gitiignore 2016-10-05 14:59:36 +02:00
Bence Erős
e0616a129e fixing #291 2016-10-05 14:57:42 +02:00
John J. Aylward
93ffca36c3 fixes spacing 2016-09-28 20:23:30 -04:00
John J. Aylward
e477d7002b fixes object comparison 2016-09-28 20:22:12 -04:00
John J. Aylward
fb1db9341e Changes encoding to better match the XML spec section 2.2 2016-09-28 20:15:58 -04:00
John J. Aylward
adb0478f66 properly unescape tokens in JSONML for reversability. 2016-09-22 16:23:09 -04:00
John J. Aylward
f6a00e94c7 adds test for unicode that has surrogate pairs 2016-09-22 16:12:00 -04:00
John J. Aylward
f58a0f4684 fixes code point appends to string builder 2016-09-22 16:10:49 -04:00
John J. Aylward
c11e09959c Fixes code point output when unescaping code points. XML escapes are an entire code point, not surrogate pairs like in JSON. 2016-09-22 15:40:26 -04:00
John J. Aylward
68f92eb395 Adds more javadoc. 2016-09-22 14:40:39 -04:00
John J. Aylward
2b87f334d0 Update test cases to support ISO Control encoding changes. 2016-09-22 14:13:48 -04:00
John J. Aylward
34652a8706 Updates to iterate on code points instead of characters and changes the encoding to only encode control characters as defined by ISO standard. 2016-09-22 14:13:14 -04:00
John J. Aylward
5027a283c1 Adds test for escaping from a JSONObject to XML 2016-09-22 13:09:32 -04:00
John J. Aylward
c8563ff93d new test case for XML changes 2016-09-22 12:38:30 -04:00
John J. Aylward
a2d3b59394 Implements unicode escaping similar to JSONObject.
* Removes deprecation on XML.stringToValue(). It now provides unescaping for strings to convert XML entities back into values.
* New unescape function to handle XML entities -> value conversion.
2016-09-22 12:38:06 -04:00
Sean Leary
474711c4ea Merge pull request #60 from stleary/fix-number-tests
fixed merge issues
2016-09-15 21:38:36 -05:00
stleary
58aebaa14f fixed merge issues 2016-09-15 21:31:28 -05:00
Sean Leary
c24be0e4ea Merge pull request #274 from johnjaylward/NumberOutputFix
Fix for number output bug.
2016-09-09 11:42:35 -05:00
John J. Aylward
88f65c5bea Merge branch 'master' of github.com:stleary/JSON-java into NumberOutputFix
# Conflicts:
#	JSONObject.java
2016-08-26 11:32:35 -04:00
Sean Leary
3570890be7 Merge pull request #57 from johnjaylward/EnumCleanup
test updates to make sure Enums are handled consistently.
2016-08-19 11:43:20 -05:00
Sean Leary
ebe69df8e4 Merge pull request #271 from johnjaylward/EnumCleanup
Update enum support to be more fully featured.
2016-08-19 10:28:04 -05:00
Sean Leary
59761f6f64 Merge pull request #58 from johnjaylward/SimplifyNumberWrap
Adds tests for numbers
2016-08-17 12:12:32 -05:00
John J. Aylward
2f2cd4dfc5 Fix for number output bug.
java.lang.Number is currently output without any validation. For all java.* Numbers, this is fine, but for custom Number implementations like Complex or Fraction, the resulting JSON output may be invalid.

For example: If a Fraction implementation defines its' toString method as `return numerator + "/" + denominator`, then the resulting JSON output would be something like this:

```json
{ "fraction" : 1/2 }
```

This is not valid JSON.

This commit verifies that the string representation of the number is close to a JSON formatted number by use of the BigDecimal constructor. If the constructor throws a NumberFormatException, then the string value is instead quoted as a string. The example above would instead output like the following:

```json
{ "fraction" : "1/2" }
```
2016-08-17 12:54:30 -04:00
John J. Aylward
0b1dbe9369 fixes test to not depend on key order 2016-08-17 12:15:16 -04:00
John J. Aylward
a66b97f60b fix test 2016-08-17 11:31:44 -04:00
johnjaylward
cbd0418704 Update JSONObjectTest.java
fixes test to be applicable
2016-08-16 21:33:54 -04:00