tag:github.com,2008:https://github.com/billdavidson/JSONUtil/releases Release notes from JSONUtil 2016-10-05T11:03:36Z tag:github.com,2008:Repository/38781549/JSONUtil-1.10.4 2016-10-05T22:18:19Z JSONUtil-1.10.4 <p>The main change in this release is that the default for undefined code points is now JSONConfig.PASS. I was confused by a document that was primarily concerned with display. This package isn't really doing display so replace isn't really an appropriate default. Unmatched surrogates remain as default to be replaced. Replace is still available as an option. It just isn't the default for undefined code points anymore.</p> <p>There is also a small optimization for the toJSON methods that return a string. It probably won't matter unless you use those a lot and have a lot of strings that need escaping.</p> <p>If you're using Java 7 or earlier, download the jars with your Java version number. Otherwise just get the regular jars that don't have a Java version in their name. They require a minimum of Java 8.</p> <p>The binaries will also be available at the <a href="http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.kopitubruk.util%22%20AND%20a%3A%22JSONUtil%22" rel="nofollow">Maven Central Repository</a> shortly.</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.4-java7 2016-10-05T10:55:58Z JSONUtil-1.10.4-java7 <p>Version</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.4-java6 2016-10-05T10:47:33Z JSONUtil-1.10.4-java6 <p>Version</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.4-java5 2016-10-05T10:41:40Z JSONUtil-1.10.4-java5 <p>Version</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.2 2016-09-27T19:42:58Z JSONUtil 1.10.2 Released <p>This release changes the way that bad character data is handled. There are two types of bad character data. One is unmatched surrogates. The other is code points that are undefined by the Unicode standard (which JSONUtil uses the JDK to recognize). Previously, these were both escaped. It turns out that was the wrong behavior. The correct behavior is to replace such characters or code points with the Unicode replacement character U+FFFD. I apologize for changing default behavior but when default behavior is wrong, it's a bug. I have created options (described below) for those that want the old behavior back.</p> <p>In reality, most applications don't encounter bad character data so this probably isn't critical but I want it to be correct and I also want flexibility so JSONUtil now offers a choice of 5 different behaviors for bad character data. You can select these behaviors via JSONConfig/JSONConfigDefaults using the methods setUnmatchedSurrogatePolicy(int) and setUndefinedCodePointPolicy(int). There is also a setBadCharacterPolicy(int) method which just calls both of those two with the same value. These policies can also be set in JNDI and read/modified by the JMX Mbean</p> <p>The 5 behaviors are:<br> 0. JSONConfig.REPLACE (default) - replace the bad character(s) with the Unicode replacement character U+FFFD</p> <ol> <li>JSONConfig.DISCARD - discard bad characters.</li> <li>JSONConfig.EXCEPTION - throw an exception when bad character data is encountered.</li> <li>JSONConfig.ESCAPE - escape bad characters</li> <li>JSONConfig.PASS - pass bad characters through as if they are OK</li> </ol> <p>If you're using Java 7 or earlier, download the jars with your Java version number. Otherwise just get the regular jars that don't have a Java version in their name. They require a minimum of Java 8.</p> <p>The binaries will also be available at the <a href="http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.kopitubruk.util%22%20AND%20a%3A%22JSONUtil%22" rel="nofollow">Maven Central Repository</a> shortly.</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.2-java7 2016-09-26T21:51:37Z JSONUtil-1.10.2-java7 <p>Version.</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.2-java6 2016-09-26T21:46:31Z JSONUtil-1.10.2-java6 <p>Version.</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.2-java5 2016-09-26T20:07:18Z JSONUtil-1.10.2-java5 <p>Version.</p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.1 2016-09-20T03:09:26Z JSONUtil 1.10.1 Released <p>1.10.0 improved performance for string values that did not contain code points that needed to be escaped. This release improves performance for strings that do need escaping. If your strings need a lot of escaping then it dramatically improves performance. Generation of a single escape is roughly 30-50 times faster than before due to using a custom escape generator.</p> <p>JSONUtil now provides a boolean property name validator if you want to validate property names.</p> <p>JsonObject has been enhanced to take a reference to a JSONConfig object which can be passed to the constructor or to a setter. When its toString or toJSON methods that don't take a JSONConfig as a parameter are called, it will use that as its configuration object. If you pass a null config to the other ones, it will also use the one it has stored.</p> <p>All of the public methods in JSONConfig which had a void return type now return the JSONConfig object itself. This is so that you can call such methods in series as with JsonObject.add().</p> <p>If you're using Java 7 or earlier, download the jars with your Java version number. Otherwise just get the regular jars that don't have a Java version in their name. They require a minimum of Java 8.</p> <p>The binaries are also available at the <a href="http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.kopitubruk.util%22%20AND%20a%3A%22JSONUtil%22" rel="nofollow">Maven Central Repository</a></p> billdavidson tag:github.com,2008:Repository/38781549/JSONUtil-1.10.1-java7 2016-09-19T18:49:00Z JSONUtil-1.10.1-java7 <p>Version</p> billdavidson