Commit 5bc4393a authored by canterafonsj's avatar canterafonsj
Browse files

Temporal Values

parent 4852d800
{
"$schema": "http://json-schema.org/schema#",
"id": "https://uri.etsi.org/ngsi-ld/schema/Entity_temporalValues.json",
"title": "NGSI-LD Entity Temporal Values",
"description": "NGSI-LD Simplified Temporal Representation of Entities",
"definitions": {
"TimestampOrEmpty": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "string",
"minLength": 0,
"maxLength": 0
}
]
},
"TemporalValue": {
"type": "array",
"items": [
{
"type": [
"string",
"number",
"boolean",
"object",
"array"
]
},
{
"$ref": "#/definitions/TimestampOrEmpty"
}
],
"minTems": 2,
"maxItems": 2
},
"TemporalObject": {
"type": "array",
"items": [
{
"type": "string",
"format": "uri"
},
{
"$ref": "#/definitions/TimestampOrEmpty"
}
],
"minTems": 2,
"maxItems": 2
},
"PropertyTemporalValues": {
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "Property"
},
"values": {
"type": "array",
"items": {
"$ref": "#/definitions/TemporalValue"
}
}
}
},
"RelationshipTemporalValues": {
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "Relationship"
},
"objects": {
"type": "array",
"items": {
"$ref": "#/definitions/TemporalObject"
}
}
}
}
},
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uri"
},
"type": {
"$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/Name"
},
"@context": {
"$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/LdContext"
},
"createdAt": {
"$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/createdAt"
},
"modifiedAt": {
"$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/modifiedAt"
}
},
"required": [
"type",
"id"
],
"additionalProperties": {
"anyOf": [
{
"$ref": "#/definitions/PropertyTemporalValues"
},
{
"$ref": "#/definitions/RelationshipTemporalValues"
}
]
},
"propertyNames": {
"type": "string",
"pattern": "^((\\d|[a-zA-Z]|_)+(#\\d+)?)$"
}
}
......@@ -20,4 +20,7 @@ ajv compile -s $SCHEMAS/BatchOperationResult.json -r $SCHEMAS/common.json
ajv compile -s $SCHEMAS/UpdateResult.json
ajv compile -s $SCHEMAS/Entity_keyValues.json -r $SCHEMAS/common.json -r $SCHEMAS/geometry-schema.json -r $SCHEMAS/Entity.json
ajv compile -s $SCHEMAS/Entity_keyValues.json -r $SCHEMAS/common.json -r $SCHEMAS/geometry-schema.json
ajv compile -s $SCHEMAS/Entity_temporalValues.json -r $SCHEMAS/common.json -r $SCHEMAS/geometry-schema.json -r $SCHEMAS/Entity.json
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment