-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #101 from handealptekin/hande-seventh-tutorial
7th tutorial video review
- Loading branch information
Showing
4 changed files
with
76 additions
and
0 deletions.
There are no files selected for viewing
Binary file added
BIN
+3.28 MB
Tutorials/whatiswot/7-JSON_Schema_in_Practice_2/7-JSON-Schema-Demo.mp4
Binary file not shown.
23 changes: 23 additions & 0 deletions
23
Tutorials/whatiswot/7-JSON_Schema_in_Practice_2/7-JSON-Schema-Demo.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
In the previous video, we talked about JSON Schema Basics, in this video, we will continue with generic keywords, Schema composition, and Schema Conditionality. | ||
|
||
Some of the annotation keywords used in JSON Schema are title, description, and default. None of these annotation words are required but enhance good practice for self-documenting Schemas. | ||
The title and description keywords must be strings. | ||
|
||
The enum keyword is used to restrict a value to a fixed set of values. It must be an array with at least one element, where each element is unique. | ||
|
||
The const keyword is used to restrict a value to a single value. | ||
|
||
JSON Schema includes a few keywords for combining Schemas together, the most used ones are allOf, anyOf, oneOf, and not. | ||
|
||
To validate allOf, the given data must be valid against all of the given sub schemas. | ||
|
||
To validate anyOf, the given data must be valid against any (one or more) of the given sub schemas. | ||
|
||
To validate oneOf, the given data must be valid against exactly one of the given sub schemas. | ||
|
||
The not keyword declares that an instance validates if it doesn’t validate against the given sub schema. | ||
|
||
The if, then and else keywords allow the application of a sub schema based on the outcome of another Schema, as it is in other programming languages. If it is valid, then must also be valid (and else is ignored.) If it is invalid, else must also be valid (and then ignored). | ||
|
||
You can proceed to the next tutorial by clicking on the card or the video description. | ||
|
53 changes: 53 additions & 0 deletions
53
Tutorials/whatiswot/7-JSON_Schema_in_Practice_2/7-JSON-Schema-Demo.vtt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
WEBVTT | ||
00:00:00.000 --> 00:00:06.575 | ||
In the previous video, we talked about JSON Schema Basics, in this | ||
|
||
00:00:06.575 --> 00:00:13.150 | ||
video, we will continue with generic keywords, Schema composition, and Schema Conditionality. | ||
|
||
00:00:13.150 --> 00:00:20.500 | ||
Some of the annotation keywords used in JSON Schema are title, description, and default. | ||
|
||
00:00:20.500 --> 00:00:27.850 | ||
None of these annotation words are required but enhance good practice for self-documenting Schemas. | ||
|
||
00:00:27.850 --> 00:00:32.475 | ||
The title and description keywords must be strings. | ||
|
||
00:00:32.475 --> 00:00:37.737 | ||
The enum keyword is used to restrict a value to a fixed set of values. | ||
|
||
00:00:37.737 --> 00:00:43.000 | ||
It must be an array with at least one element, where each element is unique. | ||
|
||
00:00:43.000 --> 00:00:51.437 | ||
The const keyword is used to restrict a value to a single value. | ||
|
||
00:00:51.437 --> 00:01:04.475 | ||
JSON Schema includes a few keywords for combining Schemas together, the most used ones are allOf, anyOf, oneOf, and not. | ||
|
||
00:01:04.475 --> 00:01:12.584 | ||
To validate allOf, the given data must be valid against all of the given sub schemas. | ||
|
||
00:01:12.584 --> 00:01:21.929 | ||
To validate anyOf, the given data must be valid against any (one or more) of the given sub schemas. | ||
|
||
00:01:21.929 --> 00:01:30.486 | ||
To validate oneOf, the given data must be valid against exactly one of the given sub schemas. | ||
|
||
00:01:30.486 --> 00:01:38.410 | ||
The not keyword declares that an instance validates if it doesn’t validate against the given sub schema. | ||
|
||
00:01:38.410 --> 00:01:45.539 | ||
The if, then and else keywords allow the application of a sub schema based on the outcome of | ||
|
||
00:01:45.539 --> 00:01:52.669 | ||
another Schema, as it is in other programming languages. If it is valid, then must also be valid | ||
|
||
00:01:52.669 --> 00:01:59.798 | ||
(and else is ignored.) If it is invalid, else must also be valid (and then ignored). | ||
|
||
00:01:59.798 --> 00:02:04.973 | ||
You can proceed to the next tutorial by clicking on the card or the video description. | ||
|
Binary file modified
BIN
+4.73 KB
(100%)
Tutorials/whatiswot/7-JSON_Schema_in_Practice_2/7-JSON_Schema_in_Practice_2.pptx
Binary file not shown.