Native JSON schema support

Native JSON schema type tree is created automatically when a valid JSON schema is entered in the type tree field of a card.

The JSON document is determined to be a JSON schema when a field called $schema is found in outermost group. If this element is not found in the JSON document will be treated as a template.

When you use native JSON to define the main input or output card, always select the main Type as the first JSON type.

Note: The main input or output card is the card that has the file or other source that defines how to parse or create the document.

This restriction does not apply to functional maps.

A card property called Data Language is present for output cards which use native JSON. This card property allows the text encoding of the JSON output to be selected. The following encodings are supported: UTF-8, UTF-16BE, UTF-16LE, UTF-32BE, UTF-32LE. Previously, an item type in a native JSON type tree named encoding was used for this purpose. The encoding item remains valid for type trees and maps which use it. Conversion of a rule on an encoding item is necessary if the rule becomes invalid due to the absence of an encoding item in a native JSON type tree.

The encoding field on input always returns the value NONE. On output, this field can be set to any valid JSON encoding and the JSON document is produced that uses that encoding. If you do not configure the encoding, the default encoding used is UTF-8.

Restrictions with JSON Schema:
  • Tuple validation is not supported.
  • Elements will be loaded into a string array, but not validated.

The target of "if" statement must appear in the data stream before fields in the Then or the Else. Out of order data will cause the "if" to fail.

Dependencies that alter the initial type is not be supported. Data will be loaded into fields but not validated.

For example: Field B is defined as string.

A dependency where if field A is present then field B now must be a date.

ITX will handle this, but no validation will be done.