Skip to content

Commit 7fae0d4

Browse files
committed
Merge branch 'otherProperties' of git://github.com/garycourt/json-schema
2 parents 300bf9d + 36c25b7 commit 7fae0d4

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

draft-zyp-json-schema-03.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,9 @@ If the property is not defined or is not in this list, than any type of value is
325325
<section title="properties">
326326
<t>This attribute is an object with property definitions that define the valid values of instance object property values. When the instance value is an object, the property values of the instance object MUST conform to the property definitions in this object. In this object, each property definition's value MUST be a schema or URI referring to a schema, and the property's name MUST be the name of the instance property that it defines. The instance property value MUST be valid according to the schema from the property definition. Properties are considered unordered, the order of the instance properties MAY be in any order.</t>
327327
</section>
328+
<section title="patternProperties">
329+
<t>This attribute is an object that defines the schema for a set of property names of an object instance. The name of each property of this attribute's object is a regular expression pattern in the ECMA 262/Perl 5 format, while the value is a schema or URI reference to a schema. If the pattern matches the name of a property on the instance object, the value of the instance's property MUST be valid against the pattern name's schema value.</t>
330+
</section>
328331
<section title="additionalProperties">
329332
<t>This attribute defines a schema for all properties that are not explicitly defined in an object type definition. If specified, the value MUST be a schema, a URI referencing a schema, or a boolean. If false is provided, no additional properties are allowed beyond the properties defined in the schema. The default value is an empty schema which allows any value for additional properties.</t>
330333
</section>
@@ -932,7 +935,7 @@ instead of numbers</t>
932935
<t>Added "additionalItems" attribute.</t>
933936
<t>Added "id" attribute.</t>
934937
<t>Switched self-referencing variable substitution from "-this" to "@" to align with reserved characters in URI template.</t>
935-
938+
<t>Added "patternProperties" attribute.</t>
936939
</list>
937940
</t>
938941
<t hangText="draft-02">

schema

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,12 @@
3030
"default" : false
3131
},
3232

33+
"patternProperties" : {
34+
"type" : "object",
35+
"additionalProperties" : "#",
36+
"default" : {}
37+
},
38+
3339
"additionalProperties" : {
3440
"type" : ["#", "boolean"],
3541
"default" : {}

0 commit comments

Comments
 (0)