Skip to content

Provide guidance on hyperschema and validation #251

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

Merged
merged 1 commit into from
Feb 19, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions jsonschema-hyperschema.xml
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,27 @@
<postamble>The base-64 data has been abbreviated for readability.</postamble>
</figure>

<section title="Interaction with validation">
<t>
Hyper-schemas MUST NOT be applied to an instance if the instance fails
to validate against the validation keywords within or containing the hyper-schema.
Hyper-schema keywords in branches of an "anyOf" or "oneOf" that do not
validate, or in a "dependencies" subschema that is not relevant
to the instance, MUST be ignored.
</t>
<t>
Hyper-schema keywords in a subschema contained within
a "not", at any depth, including any number of intervening
additional "not" subschemas, MUST be ignored.
</t>
<t>
If the subschema for a "contains" keyword contains hyper-schema
keywords they MUST be applied to all array elements that validate
against the schema. While finding a single validating element
is sufficient to determine the validation outcome, when hyper-schema
keywords are present, the subschema MUST be evaluated against all array elements.
</t>
</section>
</section>

<section title="Meta-schema">
Expand Down