Tools, FAQ, Tutorials:
Implicit and Explicit ID of JSON Type
What are differences of the implicit ID and the explicit ID of a JSON type in JSON Schema?
✍: FYIcenter.com
If a JSON type is defined under a "definitions" property,
it could have two identifications:
1. Implicit identification: The implicit identification of a JSON type is an internal bookmark in the form of "#/definitions/xxx", where "xxx" is the type name. For example, the JSON type in the following JSON schema has an implicit identification of "#/definitions/rating":
{ "definitions": { "rating": { "type": "integer", } }, ... }
2. Explicit identification: The explicit identification of a JSON type is the identification assigned by the "$id" property. For example, the JSON type in the following JSON schema has an explicit identification of "#point":
{ "definitions": { "rating": { "$id": "#point", "type": "integer", } }, ... }
Following JSON schema shows a JSON type called "rating" that can be referenced internally with two identifications: "#/definitions/rating" and "#point":
{ "definitions": { "rating": { "$id": "#point", "type": "integer", "minimum": 0, "maximum": 5 } }, "type": "object", "properties": { "clarity": { "$ref": "#/definitions/rating" }, "efficiency": { "$ref": "#point" } } }
Â
⇒Introduction of JSON Schema
⇒⇒JSON Tutorials
2017-08-20, 1192👍, 0💬
Popular Posts:
What Is session_register() in PHP? session_register() is old function that registers global variable...
How to use the "send-request" Policy statement to call an extra web service for an Azure API service...
How To Pass Arrays By References? in PHP? Like normal variables, you can pass an array by reference ...
How to use the Atom Online Validator at w3.org? w3.org feed validation service is provided at http:/...
How to create a new API on the Publisher Portal 2017 version of an Azure API Management Service? If ...