Skip to content

Commit 850d772

Browse files
committed
add default value
1 parent d3801e8 commit 850d772

File tree

1 file changed

+64
-0
lines changed

1 file changed

+64
-0
lines changed

specification/typeschema.json

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,10 @@
3333
"target": "DefinitionType"
3434
},
3535
"properties": {
36+
"type": {
37+
"type": "string",
38+
"default": "struct"
39+
},
3640
"parent": {
3741
"description": "Defines a parent type, all properties from the parent type are inherited",
3842
"type": "reference",
@@ -94,6 +98,12 @@
9498
"parent": {
9599
"type": "reference",
96100
"target": "CollectionDefinitionType"
101+
},
102+
"properties": {
103+
"type": {
104+
"type": "string",
105+
"default": "map"
106+
}
97107
}
98108
},
99109
"ArrayDefinitionType": {
@@ -102,6 +112,12 @@
102112
"parent": {
103113
"type": "reference",
104114
"target": "CollectionDefinitionType"
115+
},
116+
"properties": {
117+
"type": {
118+
"type": "string",
119+
"default": "array"
120+
}
105121
}
106122
},
107123
"PropertyType": {
@@ -169,6 +185,10 @@
169185
"target": "ScalarPropertyType"
170186
},
171187
"properties": {
188+
"type": {
189+
"type": "string",
190+
"default": "string"
191+
},
172192
"format": {
173193
"description": "Optional describes the format of the string. Supported are the following types: date, date-time and time. A code generator may use a fitting data type to represent such a format, if not supported it should fallback to a string",
174194
"type": "string"
@@ -185,6 +205,12 @@
185205
"parent": {
186206
"type": "reference",
187207
"target": "ScalarPropertyType"
208+
},
209+
"properties": {
210+
"type": {
211+
"type": "string",
212+
"default": "integer"
213+
}
188214
}
189215
},
190216
"NumberPropertyType": {
@@ -193,6 +219,12 @@
193219
"parent": {
194220
"type": "reference",
195221
"target": "ScalarPropertyType"
222+
},
223+
"properties": {
224+
"type": {
225+
"type": "string",
226+
"default": "number"
227+
}
196228
}
197229
},
198230
"BooleanPropertyType": {
@@ -201,6 +233,12 @@
201233
"parent": {
202234
"type": "reference",
203235
"target": "ScalarPropertyType"
236+
},
237+
"properties": {
238+
"type": {
239+
"type": "string",
240+
"default": "boolean"
241+
}
204242
}
205243
},
206244
"CollectionPropertyType": {
@@ -234,6 +272,12 @@
234272
"parent": {
235273
"type": "reference",
236274
"target": "CollectionPropertyType"
275+
},
276+
"properties": {
277+
"type": {
278+
"type": "string",
279+
"default": "map"
280+
}
237281
}
238282
},
239283
"ArrayPropertyType": {
@@ -242,6 +286,12 @@
242286
"parent": {
243287
"type": "reference",
244288
"target": "CollectionPropertyType"
289+
},
290+
"properties": {
291+
"type": {
292+
"type": "string",
293+
"default": "array"
294+
}
245295
}
246296
},
247297
"AnyPropertyType": {
@@ -250,6 +300,12 @@
250300
"parent": {
251301
"type": "reference",
252302
"target": "PropertyType"
303+
},
304+
"properties": {
305+
"type": {
306+
"type": "string",
307+
"default": "any"
308+
}
253309
}
254310
},
255311
"GenericPropertyType": {
@@ -260,6 +316,10 @@
260316
"target": "PropertyType"
261317
},
262318
"properties": {
319+
"type": {
320+
"type": "string",
321+
"default": "generic"
322+
},
263323
"name": {
264324
"description": "The name of the generic, it is recommended to use common generic names like T or TValue. These generics can then be replaced on usage with a concrete type through the template property at a reference",
265325
"type": "string"
@@ -274,6 +334,10 @@
274334
"target": "PropertyType"
275335
},
276336
"properties": {
337+
"type": {
338+
"type": "string",
339+
"default": "reference"
340+
},
277341
"target": {
278342
"description": "The target type, this must be a key which is available at the definitions map",
279343
"type": "string"

0 commit comments

Comments
 (0)