1153 lines
57 KiB
JSON
1153 lines
57 KiB
JSON
{
|
|
"$schema": "http://json-schema.org/draft-04/schema#",
|
|
"type": "object",
|
|
"definitions": {
|
|
"Trigger": {
|
|
"definitions": {
|
|
"action": {
|
|
"anyOf": [
|
|
{
|
|
"title": "Condition",
|
|
"type": "object",
|
|
"description": "IF .. THEN ..ELSE - style condition",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["Condition"]
|
|
},
|
|
"parts": {
|
|
"type": "array",
|
|
"items": {
|
|
"anyOf": [
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"if": {
|
|
"$ref": "#/definitions/Trigger/definitions/expression"
|
|
},
|
|
"then": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"showThenActions": {
|
|
"type": "boolean",
|
|
"description": "Holds the current state of the Trigger GUI. Not used in runtime"
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"elseif": {
|
|
"$ref": "#/definitions/Trigger/definitions/expression"
|
|
},
|
|
"then": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"showThenActions": {
|
|
"type": "boolean",
|
|
"description": "Holds the current state of the Trigger GUI. Not used in runtime"
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"else": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"showThenActions": {
|
|
"type": "boolean",
|
|
"description": "Holds the current state of the Trigger GUI. Not used in runtime"
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"success": {
|
|
"description": "Success callback action list.",
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/action"
|
|
}
|
|
},
|
|
"error": {
|
|
"description": "Error callback action list.",
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/action"
|
|
}
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": ["objectType"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "SwitchCase",
|
|
"type": "object",
|
|
"description": "SWITCH .. CASE ..CASE - style condition",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["SwitchCase"]
|
|
},
|
|
"compare": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
},
|
|
"cases": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/vCase"
|
|
}
|
|
},
|
|
"caseDefault": {
|
|
"$ref": "#/definitions/Trigger/definitions/dCase"
|
|
},
|
|
"success": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"error": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"additionalProperties": false,
|
|
"required": ["objectType", "compare", "cases", "caseDefault"]
|
|
},
|
|
{
|
|
"title": "WriteToSymbol",
|
|
"type": "object",
|
|
"description": "Write to Symbol",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["WriteToSymbol"]
|
|
},
|
|
"symbolExpression": {
|
|
"$ref": "#/definitions/Trigger/definitions/symbolExpression"
|
|
},
|
|
"value": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
},
|
|
"success": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"error": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": ["objectType", "symbolExpression", "value"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "Function",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["Function"]
|
|
},
|
|
"fn": {
|
|
"type": "string"
|
|
},
|
|
"fnParams": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
}
|
|
},
|
|
"success": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"error": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": ["objectType", "fn", "fnParams"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "JavaScript",
|
|
"type": "object",
|
|
"description": "Executes a user-defined JavaScript",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["JavaScript"]
|
|
},
|
|
"sourceLines": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"waitMode": {
|
|
"type": "string",
|
|
"enum": ["Synchronous", "Asynchronous"],
|
|
"description": "Synchronous: Next step will be called after last JavaScript line. Asynchronous: Next step will be called after calling ctx.success() or ctx.error(TcHmi.Errors.ERROR)"
|
|
},
|
|
"success": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/action"
|
|
},
|
|
"description": "Steps which will be called after the call to ctx.success() with Asynchronous or after the last line with Synchronous."
|
|
},
|
|
"error": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/action"
|
|
},
|
|
"description": "Steps which will be called after the call to ctx.error() with Asynchronous or after an exception with Synchronous."
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean",
|
|
"description": "The next step is called after the completion of this step."
|
|
}
|
|
},
|
|
"required": ["objectType", "sourceLines"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "ActionTemplate",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["ActionTemplate"]
|
|
},
|
|
"description": {
|
|
"type": "string",
|
|
"description": "A long description of this control."
|
|
},
|
|
"templateName": {
|
|
"type": "string"
|
|
},
|
|
"fnParams": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
}
|
|
},
|
|
"success": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"error": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": ["objectType", "templateName", "fnParams"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "ControlApiFunction",
|
|
"type": "object",
|
|
"description": "Defines an API of the control.",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["ControlApiFunction"]
|
|
},
|
|
"control": {
|
|
"type": "string"
|
|
},
|
|
"fn": {
|
|
"type": "string"
|
|
},
|
|
"fnParams": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
}
|
|
},
|
|
"success": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"error": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": ["objectType", "control", "fn"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "FunctionExpression",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["FunctionExpression"]
|
|
},
|
|
"functionExpression": {
|
|
"type": "string"
|
|
},
|
|
"success": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"error": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"active": {
|
|
"type": "boolean",
|
|
"description": "Should action be active? Defaults to true.",
|
|
"default": true
|
|
},
|
|
"collapsed": {
|
|
"type": "boolean",
|
|
"description": "Should action be collapsed? Not used in runtime",
|
|
"default": false
|
|
},
|
|
"asyncWait": {
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": ["objectType", "functionExpression"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "Comment",
|
|
"type": "object",
|
|
"description": "Free comment. Will be ignored on runtime.",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["Comment"]
|
|
},
|
|
"comment": {
|
|
"type": "string",
|
|
"description": "Free comment. Will be ignored on runtime."
|
|
}
|
|
},
|
|
"required": ["objectType"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
},
|
|
"actionList": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/action"
|
|
}
|
|
},
|
|
"value": {
|
|
"anyOf": [
|
|
{
|
|
"title": "StaticValue",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["StaticValue"]
|
|
},
|
|
"value": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "number"
|
|
},
|
|
{
|
|
"type": "boolean"
|
|
},
|
|
{
|
|
"type": "array"
|
|
},
|
|
{
|
|
"type": "object"
|
|
}
|
|
]
|
|
},
|
|
"valueType": {
|
|
"type": "string",
|
|
"minLength": 6,
|
|
"pattern": "^tchmi:",
|
|
"description": "Information about the used type as a tchmi reference name for re-edit scenarios while Engineering."
|
|
}
|
|
},
|
|
"required": ["objectType", "value"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "Symbol",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"description": "Value referenced via a Symbol",
|
|
"type": "string",
|
|
"enum": ["Symbol"]
|
|
},
|
|
"valueType": {
|
|
"type": "string",
|
|
"minLength": 6,
|
|
"pattern": "^tchmi:",
|
|
"description": "Information about the expected type as a tchmi reference name."
|
|
},
|
|
"symbolExpression": {
|
|
"$ref": "#/definitions/Trigger/definitions/symbolExpression"
|
|
}
|
|
},
|
|
"required": ["objectType", "symbolExpression"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "EventDataObject",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["EventDataObject"]
|
|
},
|
|
"propertyPath": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": ["objectType", "propertyPath"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"title": "FunctionExpression",
|
|
"type": "object",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["FunctionExpression"]
|
|
},
|
|
"functionExpression": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": ["objectType", "functionExpression"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
},
|
|
"comment": {
|
|
"title": "Comment",
|
|
"type": "string"
|
|
},
|
|
"bindingTarget": {
|
|
"anyOf": [
|
|
{
|
|
"title": "ControlAttributeBindingTarget",
|
|
"type": "object",
|
|
"description": "a ControlAttributeBindingTarget",
|
|
"properties": {
|
|
"objectType": {
|
|
"type": "string",
|
|
"enum": ["ControlAttributeBindingTarget"]
|
|
},
|
|
"attributeExpression": {
|
|
"$ref": "#/definitions/Trigger/definitions/controlAttributeSymbolExpression"
|
|
}
|
|
},
|
|
"required": ["objectType"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
},
|
|
"expression": {
|
|
"title": "Expression",
|
|
"type": "object",
|
|
"properties": {
|
|
"compare1": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
},
|
|
"compare2": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
},
|
|
"compareOperator": {
|
|
"type": "string",
|
|
"enum": ["==", "===", "!=", "!==", "<", "<=", ">", ">="]
|
|
},
|
|
"logic": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"enum": ["AND", "OR"]
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"required": ["compare1", "compare2", "compareOperator"],
|
|
"additionalProperties": false
|
|
},
|
|
"vCase": {
|
|
"title": "VCase",
|
|
"type": "object",
|
|
"properties": {
|
|
"actions": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
},
|
|
"caseValue": {
|
|
"$ref": "#/definitions/Trigger/definitions/value"
|
|
}
|
|
},
|
|
"required": ["actions", "caseValue"],
|
|
"additionalProperties": false
|
|
},
|
|
"dCase": {
|
|
"title": "DCase",
|
|
"type": "object",
|
|
"properties": {
|
|
"actions": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
}
|
|
},
|
|
"required": ["actions"],
|
|
"additionalProperties": false
|
|
},
|
|
"symbolExpression": {
|
|
"title": "SymbolExpression",
|
|
"description": "Reference to a Symbol Expression",
|
|
"type": "string",
|
|
"pattern": "^%(s|i|l|pp|tp|f|ctrl|ctx|tr|t)%.+%\\/\\1%$"
|
|
},
|
|
"controlSymbolExpression": {
|
|
"title": "controlSymbolExpression",
|
|
"description": "Reference to a Control Symbol Expression",
|
|
"type": "string",
|
|
"pattern": "^%(ctrl)%.+%\\1%$"
|
|
},
|
|
"controlAttributeSymbolExpression": {
|
|
"title": "ControlAttributeSymbolExpression",
|
|
"type": "string",
|
|
"pattern": "^%(ctrl)%.+%\\1%$"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"properties": {
|
|
"event": {
|
|
"type": "string",
|
|
"description": "Event name",
|
|
"minLength": 1
|
|
},
|
|
"preventDefault": {
|
|
"type": "boolean",
|
|
"description": "If activated the default action of the event will not be triggered.\nIf set on touch events the corresponding mouse events will not be triggered."
|
|
},
|
|
"displayName": {
|
|
"type": "string",
|
|
"description": "Name which should be presented the user."
|
|
},
|
|
"actions": {
|
|
"type": "array",
|
|
"minItems": 1,
|
|
"description": "List of actions to trigger.",
|
|
"items": {
|
|
"$ref": "#/definitions/Trigger/definitions/action"
|
|
}
|
|
}
|
|
},
|
|
"additionalProperties": false,
|
|
"required": ["event", "actions"]
|
|
}
|
|
},
|
|
"properties": {
|
|
"$schema": {
|
|
"type": "string",
|
|
"description": "URL to a schema file"
|
|
},
|
|
"apiVersion": {
|
|
"type": "integer",
|
|
"description": "API Version"
|
|
},
|
|
"modules": {
|
|
"type": "array",
|
|
"description": "List of modules like controls, functions and additional resources like Cascading Style Sheets or JavaScript files.",
|
|
"items": {
|
|
"anyOf": [
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["Package"],
|
|
"description": "Describes a reference to a package."
|
|
},
|
|
"nugetId": {
|
|
"type": "string",
|
|
"description": "This is the NugetId of the referenced package. The resources of the referenced package are used before the rest of the modules."
|
|
}
|
|
},
|
|
"required": ["type", "nugetId"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["Control"],
|
|
"description": "Describes a tchmi control."
|
|
},
|
|
"basePath": {
|
|
"type": "string",
|
|
"description": "The base path to find all control files."
|
|
},
|
|
"descriptionFile": {
|
|
"type": "string",
|
|
"description": "Name of the description file for the control: Description.json in most cases."
|
|
},
|
|
"toolboxCategory": {
|
|
"type": "string",
|
|
"description": "Defines the category in Engineering toolbox."
|
|
}
|
|
},
|
|
"required": ["type", "descriptionFile"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["Function"],
|
|
"description": "Describes a tchmi function."
|
|
},
|
|
"basePath": {
|
|
"type": "string",
|
|
"description": "The base path to find the function <functionName>.js and <functionName>.function.json files."
|
|
},
|
|
"descriptionFile": {
|
|
"type": "string",
|
|
"pattern": "^[^/]*$",
|
|
"description": "Name of the description file for the function. This is <functionName>.function.json in most cases. A path should be put into basePath."
|
|
}
|
|
},
|
|
"required": ["type", "descriptionFile"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["Resource"],
|
|
"description": "Defines we are refering to a (non-control and non-function) resource. This can be a CSS Stylesheet or a JS file. \nJavascript module files can be import'ed in controls and functions without referencing them here."
|
|
},
|
|
"path": {
|
|
"type": "string",
|
|
"description": "Url of the css or js resource. \nJavascript module files can be import'ed in controls and functions without referencing them here."
|
|
},
|
|
"theme": {
|
|
"type": "string",
|
|
"description": "Restricts the CSS Resource to be used only for one specific theme name. Will be used for all themes if unset. (not valid for JS files)",
|
|
"minLength": 1
|
|
},
|
|
"component": {
|
|
"type": "string",
|
|
"description": "Groups the resource for theme override in project. (not valid for JS files)",
|
|
"minLength": 1
|
|
}
|
|
},
|
|
"required": ["type", "path"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["Language"],
|
|
"description": "Defines we are refering to a language file."
|
|
},
|
|
"locale": {
|
|
"type": "string",
|
|
"description": "Determines the language code of the language file.",
|
|
"minLength": 2
|
|
},
|
|
"files": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"description": "Url of the language file."
|
|
},
|
|
{
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string",
|
|
"description": "Url of the language file."
|
|
}
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"required": ["type", "files", "locale"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["UserControl"],
|
|
"description": "Defines we are refering to a *.usercontrol."
|
|
},
|
|
"path": {
|
|
"type": "string",
|
|
"description": "The path to the *.usercontrol file.",
|
|
"minLength": 1
|
|
}
|
|
},
|
|
"required": ["type", "path"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["Content"],
|
|
"description": "Defines we are refering to a *.content file."
|
|
},
|
|
"path": {
|
|
"type": "string",
|
|
"description": "The path to the *.content file.",
|
|
"minLength": 1
|
|
}
|
|
},
|
|
"required": ["type", "path"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["View"],
|
|
"description": "Defines we are refering to a *.view file."
|
|
},
|
|
"path": {
|
|
"type": "string",
|
|
"description": "The path to the *.view file.",
|
|
"minLength": 1
|
|
}
|
|
},
|
|
"required": ["type", "path"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"provideMetadata": {
|
|
"type": "object",
|
|
"description": "Metadata",
|
|
"properties": {
|
|
"toolbox": {
|
|
"type": "object",
|
|
"description": "Dictionary of category groups.",
|
|
"additionalProperties": {
|
|
"type": "object",
|
|
"description": "Dictionary of category names. Key has to be a number.",
|
|
"patternProperties": {
|
|
"^[0-9]*$": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"description": "Category name."
|
|
},
|
|
{
|
|
"type": "object",
|
|
"description": "Category name by language code.",
|
|
"properties": {
|
|
"default": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"patternProperties": {
|
|
"^[a-z]{2}-[A-Z]{2}$": {
|
|
"type": "string"
|
|
},
|
|
"^[a-z]{2}$": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": ["default"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
}
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
},
|
|
"uiProvider": {
|
|
"description": "This packages provides some system ui implementation.",
|
|
"type": "array",
|
|
"items": {
|
|
"oneOf": [
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["keyboard"],
|
|
"description": "This definition provides a system keyboard implementation."
|
|
},
|
|
"name": {
|
|
"type": "string",
|
|
"description": "Defines the id of this keyboard implementation. Use a namespace string to avoid name collisions."
|
|
},
|
|
"projectBasedKeyboardFiles": {
|
|
"type": "boolean",
|
|
"description": "Defines if the keyboard needs a list of keyboards in the project directory (will be stored in tchmiconfig.json)",
|
|
"default": false
|
|
},
|
|
"projectBasedKeyboardFileExt": {
|
|
"type": "string",
|
|
"description": "Defines the extension of keyboard files in the project.",
|
|
"default": ".keyboard.json"
|
|
}
|
|
},
|
|
"additionalProperties": false,
|
|
"required": ["name", "type", "projectBasedKeyboardFiles"]
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "string",
|
|
"enum": ["popup"],
|
|
"description": "This definition provides a system popup implementation."
|
|
},
|
|
"name": {
|
|
"type": "string",
|
|
"description": "Defines the id of this popup implementation. Use a namespace string to avoid name collisions.",
|
|
"default": "TcHmi.Controls.Beckhoff.TcHmiPopup"
|
|
},
|
|
"popup": {
|
|
"type": "string",
|
|
"description": "Defines the type of the popup. TODO: Needed?"
|
|
}
|
|
},
|
|
"additionalProperties": false,
|
|
"required": ["name", "type"]
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"symbols": {
|
|
"type": "object",
|
|
"description": "Definition of package based symbols.",
|
|
"properties": {
|
|
"internal": {
|
|
"type": "object",
|
|
"description": "Definition of package based internal symbols (available via %i%Package:{PkgId};[SYMBOL_NAME]%/i%). Key is the symbol name.",
|
|
"additionalProperties": {
|
|
"type": "object",
|
|
"description": "Definition of the internal symbol with this name.",
|
|
"properties": {
|
|
"value": {
|
|
"description": "Value for this internal symbol."
|
|
},
|
|
"persist": {
|
|
"type": "boolean",
|
|
"description": "The change of value is saved in the client and available after reload. Defaults to false if not provided.",
|
|
"default": false
|
|
},
|
|
"readonly": {
|
|
"type": "boolean",
|
|
"description": "The symbol can not be changed. Defaults to false if not provided.",
|
|
"default": false
|
|
},
|
|
"type": {
|
|
"type": "string",
|
|
"minLength": 6,
|
|
"pattern": "^tchmi:",
|
|
"description": "Information about the expected type as a tchmi reference name."
|
|
}
|
|
},
|
|
"required": ["type"],
|
|
"additionalProperties": false
|
|
}
|
|
},
|
|
"timer": {
|
|
"type": "object",
|
|
"description": "Definition of package based based timer symbols (available via %t%Package:{PkgId};[SYMBOL_NAME]%/t%). Key is the symbol name.",
|
|
"additionalProperties": {
|
|
"type": "object",
|
|
"description": "Definition of the timer symbol with this name.",
|
|
"properties": {
|
|
"pattern": {
|
|
"type": "array",
|
|
"description": "Value pattern for this timer symbol.",
|
|
"items": {
|
|
"oneOf": [
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"value": {
|
|
"description": "Value for this pattern part. Only used when symbol is not defined."
|
|
},
|
|
"duration": {
|
|
"type": "number",
|
|
"description": "Duration in milliseconds for this timer symbol pattern part."
|
|
}
|
|
},
|
|
"required": ["value", "duration"],
|
|
"additionalProperties": false
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"symbol": {
|
|
"type": "string",
|
|
"pattern": "^%(s|i|l|pp|tp|f|ctrl|ctx|tr|t)%.+%\\/\\1%$",
|
|
"description": "SymbolExpression which represents the value for this timer symbol pattern part. Overrides value when defined. "
|
|
},
|
|
"duration": {
|
|
"type": "number",
|
|
"description": "Duration in milliseconds for this timer symbol pattern part."
|
|
}
|
|
},
|
|
"required": ["symbol", "duration"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"runSymbol": {
|
|
"type": "string",
|
|
"pattern": "^%(s|i|l|pp|tp|f|ctrl|ctx|tr|t)%.+%\\/\\1%$",
|
|
"description": "SymbolExpression (Boolean) which controls the state of the timer."
|
|
},
|
|
"stopValue": {
|
|
"description": "Value which is active when the timer is stopped."
|
|
},
|
|
"type": {
|
|
"type": "string",
|
|
"minLength": 6,
|
|
"pattern": "^tchmi:",
|
|
"description": "Information about the expected type as a tchmi reference name."
|
|
}
|
|
},
|
|
"required": ["type", "pattern"],
|
|
"additionalProperties": false
|
|
}
|
|
},
|
|
"package": {
|
|
"type": "object",
|
|
"description": "Definition of package based symbols (available via %pkg%Package:{PkgId};[SYMBOL_NAME]%/pkg%) that can be mapped to other symbols at runtime. All symbol actions are forwared to the mapped symbol than. Key is the symbol name.",
|
|
"additionalProperties": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"type": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": ["type"]
|
|
}
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
},
|
|
"intervals": {
|
|
"type": "object",
|
|
"description": "Definition of all package based intervals. Key is the interval name.",
|
|
"additionalProperties": {
|
|
"type": "object",
|
|
"description": "Definition of the interval with this name.",
|
|
"properties": {
|
|
"interval": {
|
|
"type": "number",
|
|
"description": "Interval time in milliseconds."
|
|
},
|
|
"actions": {
|
|
"$ref": "#/definitions/Trigger/definitions/actionList"
|
|
}
|
|
},
|
|
"required": ["interval", "actions"],
|
|
"additionalProperties": false
|
|
}
|
|
},
|
|
"actionTemplates": {
|
|
"description": "Definition of package based action templates.",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"description": "Name of the action template.",
|
|
"type": "string"
|
|
},
|
|
"category": {
|
|
"type": "string"
|
|
},
|
|
"actions": {
|
|
"type": "array"
|
|
},
|
|
"parameters": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
},
|
|
"description": {
|
|
"type": "string"
|
|
},
|
|
"structDataType": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
}
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
}
|
|
},
|
|
"esmoduleImports": {
|
|
"description": "Allows mapping of an import keyword, path prefixes or full path to a real path inside this hmi package. \nSee https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap",
|
|
"type": "array",
|
|
"items": {
|
|
"description": "Entry for one import mapping.",
|
|
"type": "object",
|
|
"properties": {
|
|
"moduleScope": {
|
|
"type": "string",
|
|
"description": "Optional base path for this mapping. \nCan be used to restrict an entry to a single control."
|
|
},
|
|
"imports": {
|
|
"type": "object",
|
|
"description": "Mapping of an import keyword, path prefixes or full path to a real path. \nSee https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap",
|
|
"additionalProperties": {
|
|
"type": "string",
|
|
"description": "Path to map this import keyword, path prefixes or full path to. \nThis path is relative to the package root (where this manifest is located)."
|
|
}
|
|
}
|
|
},
|
|
"required": ["imports"],
|
|
"additionalProperties": false
|
|
}
|
|
},
|
|
"dataTypes": {
|
|
"type": "array",
|
|
"description": "List of data type schema definition files.",
|
|
"items": {
|
|
"type": "object",
|
|
"properties": {
|
|
"schema": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"description": "Path to the file."
|
|
}
|
|
},
|
|
"additionalProperties": false,
|
|
"required": ["schema"]
|
|
}
|
|
},
|
|
"features": {
|
|
"type": "array",
|
|
"description": "Provides information about supported features that will toggle specific support in the engineering when also supported by the used engineering version.",
|
|
"items": {
|
|
"type": "string",
|
|
"enum": ["ContentPackages"]
|
|
}
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
}
|