Skip to content

Parsing a sequence of JSON values that are not enclosed in a JSON array #308

Open
@bergtwvd

Description

@bergtwvd

Parsing a sequence of JSON objects is not possible, but the standard says:

 JsonParser can be used to parse sequence of JSON values that are not enclosed in a JSON array, e.g. { } { }. The following code demonstrates how to parse such sequence.


 JsonParser parser = Json.createParser(...);
 while (parser.hasNext) {
     parser.next(); // advance parser state
     JsonValue value = parser.getValue();
 }

See also: leadpony/joy#14

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions