JSON message: lists
[
{"id":1, "name":"File"},
{"id":2, "name":"Edit"},
{ "name":""}
]
SEQUENCE OF SEQUENCE {
name UTF8String,
id INTEGER OPTIONAL
}
JSON message: a collection of related objects
{
"shapes" :
[
{"area":3.14,"radius":1},
{"area":1,"x":1,"y":1},
{"area":2,"b":1,"h":2},
]
}
shapes SEQUENCE OF SEQUENCE {
area INTEGER,
y INTEGER OPTIONAL,
x INTEGER OPTIONAL,
radius INTEGER OPTIONAL,
h INTEGER OPTIONAL,
b INTEGER OPTIONAL
}
JSON message: tuples
{
"location" :
[
“New York”,
8550405,
790,
{"x":-74.96778,"y":49.6743}
]
}
location [ARRAY] SEQUENCE {
item0 UTF8String,
item1 INTEGER,
item2 INTEGER,
item3 SEQUENCE {
y REAL,
x REAL }
}
JSON message: an unordered collection of various objects
{
"everything" :
[
{
"model":"Toyota",
"passengers":5,
"auto":true
},
{
"brand":"Absolut",
"proof":80
},
{
"material":"wood",
"country":"USA",
"year":2017
}
]
}
everything SEQUENCE OF [JER: UNWRAPPED] CHOICE {
alternative0 SEQUENCE {
passengers INTEGER,
model UTF8String,
auto BOOLEAN
},
alternative1 SEQUENCE {
proof INTEGER,
brand UTF8String
},
alternative2 SEQUENCE {
year INTEGER,
material UTF8String,
country UTF8String
}
}
JSON Schema: oneOf
{
"oneOf": [
{ "type": "string", "maxLength": 5 },
{ "type": "number", "minimum": 0 }
]
}
CHOICE {
alt1 UTF8String(SIZE(MIN..5)),
alt2 REAL(0.0..MAX)
}