controller types

trunk
HeNine 2 years ago
parent 8d9c81459e
commit 3b55c05df9

@ -1,4 +1,5 @@
local entity = import 'entity.libsonnet'; local entity = import 'entity.libsonnet';
local types = import 'types.libsonnet';
entity entity
{ {
@ -18,19 +19,19 @@ entity
type: 'array', type: 'array',
description: 'Entities this controller controls.', description: 'Entities this controller controls.',
items: items:
$.properties.id, types.id,
}, },
measures: { measures: {
type: 'array', type: 'array',
description: 'List of variables this controller measures.', description: 'List of variables this controller measures.',
items: 'string', items: types.id,
minItems: 1, minItems: 1,
uniqueItems: true, uniqueItems: true,
}, },
controls: { controls: {
type: 'array', type: 'array',
description: 'List of variables this controller controls.', description: 'List of variables this controller controls.',
items: 'string', items: type.id,
minItems: 1, minItems: 1,
uniqueItems: true, uniqueItems: true,
} }

@ -15,7 +15,7 @@ entity
type: 'array', type: 'array',
items: { items: {
type: 'object', type: 'object',
description: 'Relationships that bind other entities to this room.', description: 'Relationships notionally related to this room.',
properties: { properties: {
id: types.id, id: types.id,
args: { args: {

@ -4,7 +4,11 @@ entity
{ {
'$id': 'https://picc.app/schemata/v0.1-dev/relationship', '$id': 'https://picc.app/schemata/v0.1-dev/relationship',
title: 'Relationship', title: 'Relationship',
description: 'Describes a relationship between entities. An arity of 1 is used to describe a property of an entity (a relationship of the entity to itself).', description: |||
Describes a relationship between entities. An arity of 1 is used to describe a property of an entity (a relationship of the entity to itself).
The first argument of a relationship is used as the primary key and should be the main entity of the relationship.
|||,
properties+: { properties+: {
arity: { arity: {

Loading…
Cancel
Save