{"action":"published","release":{"url":"https://api.github.com/repos/arcticicestudio/icecore-json/releases/4423370","assets_url":"https://api.github.com/repos/arcticicestudio/icecore-json/releases/4423370/assets","upload_url":"https://uploads.github.com/repos/arcticicestudio/icecore-json/releases/4423370/assets{?name,label}","html_url":"https://github.com/arcticicestudio/icecore-json/releases/tag/v0.8.0-frost.0","id":4423370,"tag_name":"v0.8.0-frost.0","target_commitish":"develop","name":"0.8.0-frost.1","draft":false,"author":{"login":"arcticicestudio","id":7836623,"avatar_url":"https://avatars.githubusercontent.com/u/7836623?v=3","gravatar_id":"","url":"https://api.github.com/users/arcticicestudio","html_url":"https://github.com/arcticicestudio","followers_url":"https://api.github.com/users/arcticicestudio/followers","following_url":"https://api.github.com/users/arcticicestudio/following{/other_user}","gists_url":"https://api.github.com/users/arcticicestudio/gists{/gist_id}","starred_url":"https://api.github.com/users/arcticicestudio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/arcticicestudio/subscriptions","organizations_url":"https://api.github.com/users/arcticicestudio/orgs","repos_url":"https://api.github.com/users/arcticicestudio/repos","events_url":"https://api.github.com/users/arcticicestudio/events{/privacy}","received_events_url":"https://api.github.com/users/arcticicestudio/received_events","type":"User","site_admin":false},"prerelease":true,"created_at":"2016-06-04T09:11:09Z","published_at":"2016-10-18T21:33:11Z","assets":[],"tarball_url":"https://api.github.com/repos/arcticicestudio/icecore-json/tarball/v0.8.0-frost.0","zipball_url":"https://api.github.com/repos/arcticicestudio/icecore-json/zipball/v0.8.0-frost.0","body":"<p align=\"center\"><img src=\"https://cdn.rawgit.com/arcticicestudio/icecore-json/develop/src/main/assets/icecore-json-logo-banner.svg\"/></p>\r\n\r\n<p align=\"center\"><img src=\"https://assets-cdn.github.com/favicon.ico\" width=24 height=24/> <a href=\"https://github.com/arcticicestudio/icecore-json/releases/latest\"><img src=\"https://img.shields.io/github/release/arcticicestudio/icecore-json.svg\"/></a> <img src=\"http://central.sonatype.org/favicon.ico\" width=24 height=24/> <a href=\"http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22com.arcticicestudio%22%20AND%20a%3A%22icecore-json%22\"><img src=\"https://img.shields.io/maven-central/v/com.arcticicestudio/icecore-json.svg\"/></a> <img src=\"https://oss.sonatype.org/favicon.ico\"/> <a href=\"https://oss.sonatype.org/content/repositories/snapshots/com/arcticicestudio/icecore-json\"><img src=\"https://img.shields.io/badge/oss--sonatype---_-blue.svg\"/></a> <img src=\"https://bintray.com/favicon.ico\" width=24 height=24/> <a href='https://bintray.com/arcticicestudio/IceCore/icecore-json/_latestVersion'><img src='https://api.bintray.com/packages/arcticicestudio/IceCore/icecore-json/images/download.svg'></a> <a href=\"https://oss.jfrog.org/webapp/#/artifacts/browse/tree/General/oss-snapshot-local/com/arcticicestudio/icecore-json\"><img src=\"https://img.shields.io/badge/artifactory---_-green.svg\"/></a></p>\r\n\r\n---\r\n\r\n## Features\r\n### Streaming API\r\nThe new streaming API allows processing with events to a given JSON handler while reading input.\r\nIt makes it possible to\r\n  - register a handler that receives callbacks during parsing\r\n  - avoid creating an object representation of the entire input in this mode\r\n  - interrupt the parsing at any point\r\n\r\nThe `JsonParser` now issues events to a given `JsonHandler` instead of creating a `JsonValue` itself.\r\n\r\n#### Use cases\r\n##### Reading without creating data\r\n**Example: Syntax highlighting in an editor**  \r\nFor this case you don't care about the content, only about the text positions where syntactical elements begin and end.\r\n\r\n**Example: Analyzing/Verifying the structure of a JSON**  \r\nIn this case, the content would matter (e.g. object names and value types), but you would not build up a structure.\r\n\r\n##### Creating a custom data structure without intermediate `JsonValue`\r\nThis could be useful because\r\n  - the application requires a custom data types type anyway and it's faster to create the right structure right away\r\n  - a custom data structure could be more lightweight by immediately transforming or even skipping values\r\n\r\nExample:  \r\nA custom document handler would know that the value for an object member named \"time\" is a string representing a time.\r\nInstead of storing the string in a `JsonValue`, it could store it in a `Date` field of the object being created.\r\nThere should be no `JsonValue` involved unless this type is part of the custom data structure.\r\n\r\n##### Skipping parts of the inputs\r\nThe application wants to skip parts of a long document.\r\nThis could be useful because\r\n  - the document is too large to fit in memory\r\n  - skipping parts of the document could improve reading performance\r\n\r\nThe parser still needs to read every single character, but by telling it to skip a part, it could avoid filling the capture buffer and save CPU cycles.\r\n\r\n| Class | Description |\r\n| ----- | ----------- |\r\n| `com.arcticicestudio.icecore.json.JsonHandler` | A handler for parser events. Instances of this class can be given to `JsonParser`. The parser will then call the methods of the given handler while reading the input. |\r\n| `com.arcticicestudio.icecore.json.Location` | An immutable object that represents a location in the parsed text. |\r\n\r\n## Tests\r\n### Streaming API\r\n  - Implemented new unit tests and adjusted existing for the streaming API:\r\n\r\n| Class | Method | Description |\r\n| ----- | ------ | ----------- |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ setUp():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ constructorRejectsNullHandler():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseStringRejectsNull():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseReaderRejectsNull():void {exceptions=IOException}` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseReaderRejectsNegativeBufferSize():void {exceptions=IOException}` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseNull():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseTrue():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseFalse():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseString():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseStringEmpty():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseNumber():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseArray():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseArrayEmpty():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseObjectEmpty():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonParserTest` | `+ parseCanBeCalledTwice():void` | - |\r\n\r\n### JSON Object\r\n  - Implemented test methods for `JsonObject` with repeated properties names:\r\n\r\n| Class | Method | Description |\r\n| ----- | ------ | ----------- |\r\n| `com.arcticicestudio.icecore.json.JsonObjectTest` | `+ keyRepetitionAllowsMultipleEntries():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonObjectTest` | `+ keyRepetitionGetsLastEntry():void` | - |\r\n| `com.arcticicestudio.icecore.json.JsonObjectTest` | `+ keyRepetitionEqualityConsidersRepetitions():void` | - |\r\n\r\n## Improvements\r\n### JSON Parser\r\n  - The start column numbers now start at `1`\r\n    Most editors regard the first character position of a text as `1:1`.\r\n    This seems more logical than `1:0` which is currently returned for the first position by `icecore-json`.\r\n    Adapt this established pattern and let column numbers start at `1`, as line numbers do.\r\n\r\n    With this change, there is an easy rule:\r\n      - `offset` is for programs, it starts at `0`\r\n      - `line` and `column` are for humans, they start at `1`\r\n\r\n    This leads to a slight API change in ParseException.\r\n    However, since the effect can only be seen in the case of an error, it seems acceptable.\r\n  - The `readArray():void` method now increments before comparing to the `MAX_NESTING_LEVEL` constant to make the condition more expressive\r\n\r\n## Bug Fixes\r\n### JSON Parser\r\n  - Replaced a fixed number for the maximal nesting level with the corresponding constant `MAX_NESTING_LEVEL`\r\n\r\n### Unit Tests\r\n  - Fixed invalid test data where values are not matching the specified statements\r\n\r\n---\r\n\r\nThe full changelog ist available [here](https://github.com/arcticicestudio/icecore-json/blob/master/CHANGELOG.md)"}}
{"actor":{"display_login":"arcticicestudio"}}