Skip to content

GsonBuilder.setLenient(false) #372

@GoogleCodeExporter

Description

@GoogleCodeExporter
The gson JsonParser is final and it's #parse(JsonReader json) does this:
json.setLenient(true); 

In my unit tests I validate the output of my json rest api and I would like to 
have a parser with strict parsing. Creating my own StrictJsonReader also is not 
possible unless I put it in the com.google.gson package.

Maybe you could add a setter or constructor param for lenient or strict parsing?

Original issue reported on code.google.com by [email protected] on 26 Oct 2011 at 2:11

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