Change $ref to be part of a SchemaObject.
This allows other keyworlds to be used alongside $ref, as allowed in Json Schema 2019-09
This commit is contained in:
parent
7d162a8fb5
commit
5a82498e28
6 changed files with 115 additions and 137 deletions
|
@ -5,9 +5,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -24,25 +21,11 @@
|
|||
"integer"
|
||||
]
|
||||
},
|
||||
"Ref": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"$ref"
|
||||
],
|
||||
"properties": {
|
||||
"$ref": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Schema": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -55,6 +38,10 @@
|
|||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"$ref": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"$schema": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
|
@ -64,9 +51,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -78,9 +62,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -109,9 +90,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -133,9 +111,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -166,9 +141,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -239,9 +211,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -276,9 +245,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
@ -296,9 +262,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/SchemaObject"
|
||||
}
|
||||
|
|
|
@ -5,9 +5,6 @@
|
|||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/definitions/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/definitions/SchemaObject"
|
||||
}
|
||||
|
@ -24,25 +21,11 @@
|
|||
"integer"
|
||||
]
|
||||
},
|
||||
"Ref": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"$ref"
|
||||
],
|
||||
"properties": {
|
||||
"$ref": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Schema": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
"$ref": "#/definitions/Ref"
|
||||
},
|
||||
{
|
||||
"$ref": "#/definitions/SchemaObject"
|
||||
}
|
||||
|
@ -57,6 +40,12 @@
|
|||
"null"
|
||||
]
|
||||
},
|
||||
"$ref": {
|
||||
"type": [
|
||||
"string",
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"$schema": {
|
||||
"type": [
|
||||
"string",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue