Skip to content

Remove special case handling of annotation values #986

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
Sep 26, 2020
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
25 changes: 8 additions & 17 deletions jsonschema-core.xml
Original file line number Diff line number Diff line change
Expand Up @@ -770,7 +770,9 @@
</t>
<t>
<xref target="annotations">Annotation</xref> results are
combined according to the rules specified by each annotation keyword.
preserved along with the instance location and the location of
the schema keyword, so that applications can decide how to
interpret multiple values.
</t>
<section title="Referenced and Referencing Schemas" anchor="referenced">
<t>
Expand Down Expand Up @@ -865,8 +867,9 @@
<t>
Annotations are attached to specific locations in an instance.
Since many subschemas can be applied to any single
location, annotation keywords need to specify any unusual handling of
multiple applicable occurrences of the keyword with different values.
location, applications may need to decide how to handle differing
annotation values being attached to the same instance location by
the same schema keyword in different schema objects.
</t>
<t>
Unlike assertion results, annotation data can take a wide variety of forms,
Expand Down Expand Up @@ -919,14 +922,6 @@
</t>
</list>
</t>
<t>
If the same keyword attaches values from multiple schema locations
to the same instance location, and the annotation defines a process
for combining such values, then the combined value MUST also be associated
with the instance location. The <xref target="output">output formats</xref>
described in this specification that include annotation information
meet this requirement.
</t>
<section title="Distinguishing Among Multiple Values">
<t>
Applications MAY make decisions on which of multiple annotation values
Expand Down Expand Up @@ -986,8 +981,7 @@
<t>
In this example, both Feature A and Feature B make use of the re-usable
"enabledToggle" schema. That schema uses the "title", "description",
and "default" annotations, none of which define special behavior for
handling multiple values. Therefore the application has to decide how
and "default" annotations. Therefore the application has to decide how
to handle the additional "default" value for Feature A, and the additional
"description" value for Feature B.
</t>
Expand Down Expand Up @@ -1061,10 +1055,7 @@
<t>
In addition to possibly defining annotation results of their own,
applicator keywords aggregate the annotations collected in their
subschema(s) or referenced schema(s). The rules for aggregating
annotation values are defined by each annotation keyword, and are
not directly affected by the logic used for combining assertion
results.
subschema(s) or referenced schema(s).
</t>
</section>
</section>
Expand Down