Beschreibung, Kommentar oder JSON-String für Variablen und Datentypen angeben
VAR | VAR_INPUT | VAR_OUTPUT | VAR_IN_OUT | VAR_GLOBAL | VAR_EXTERNAL | VAR_TEMP name_1, name_2, ..., name_n : data-type := initial-value { description := "string"; comment := "string"; customDataJson := 'Json-String'; }; ... END_VAR TYPE name_A : <Datentyp-Deklaration> := initial-value { description := "string"; comment := "string"; customDataJson := 'Json-String'; }; ... name_B: STRUCT name_e1 : type := initial-value { description := "string"; comment := "string"; customDataJson := 'Json-String'; }; ... END_STRUCT; END_TYPE
Bedeutung |
---|
Angabe dieser zusätzlichen Daten (= Daten-Elemente) bei einer →Variable, einem →Datentyp oder einem Strukturelement (= Sprach-Element):
Implementierungsabhängige Realisierung Die Angabe der Daten-Elemente ist vor dem abschließenden Zeichen Der Text für die Beschreibung, den Kommentar und den JSON-String muss ein Zeichenfolge-Literal in einem →Pragma sein. Wenn Sie das Zeichen Die Daten-Elemente werden üblicherweise von einem Systemintegrator ausgewertet. In logi.CAD 3 sind Beschreibung und Kommentar der Variable auch im Schnittstellen-Editor einsehbar. |
Die Angabe der Daten-Elemente ist innerhalb dieser Abschnitte möglich:
VAR Var1 : INT {description := "This is the long name for the variable."; comment := "This is the comment for the variable."; customDataJson := '{ "glossary": { "title": "Variable (local)", "ID": "Var1" } }'; }; END_VAR
VAR Inst1 : Control {description := "This is the long name for the function block instance."; comment := "This is the comment for the function block instance."; }; END_VAR
TYPE complex : STRUCT re : REAL {description := "This is the long name for the 1st structure element.";}; im : REAL {comment := "This is the comment for the 2nd structure element.";}; END_STRUCT; END_TYPE