Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Example code on README.md please plus links to examples in src #364

Open
davidmoten opened this issue Feb 11, 2021 · 0 comments
Open

Example code on README.md please plus links to examples in src #364

davidmoten opened this issue Feb 11, 2021 · 0 comments

Comments

@davidmoten
Copy link

davidmoten commented Feb 11, 2021

I wasted a number of minutes looking for the simplest example on the README.md and in the wiki but didn't find one. Please put a simple example on the README.md like:

JsonSchemaFactory factory = JsonSchemaFactory.byDefault();
ObjectMapper m = new ObjectMapper();
JsonSchema jsonSchema = factory
        .getJsonSchema(m.readTree(schemaFile));
JsonNode json = m.readTree(jsonFile);
ProcessingReport report = jsonSchema.validate(json);
System.out.println(report);

Plus please put links to the src examples.

Thanks for the very useful library!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant