Difference between revisions of "Core.Declarations.GlobalDeclarations"
Line 10: | Line 10: | ||
* Context Variable | * Context Variable | ||
− | can be declared. These elements have a global validity. That is, they can both within the document in which they are declared, as well as in other documents, see [[Imports]] are used. | + | can be declared. These elements have a global validity. That is, they can both within the document in which they are declared, as well as in other documents, see [[OtxImports|Imports]] are used. |
== Semantics == | == Semantics == |
Revision as of 09:59, 14 August 2014
Contents
Classification
Name | Global Declarations |
Short Description | OTX global declarations data model |
Class | OTX Core |
Pre-Conditions | - |
Specified by | ISO 13209-2 |
Introduction
In the global declaration block:
- Global Constant
- Document Variable
- Context Variable
can be declared. These elements have a global validity. That is, they can both within the document in which they are declared, as well as in other documents, see Imports are used.
Semantics
Global Constant
The value of a global constant is set at design time and can not be changed at runtime. For global constants have the following Visibilities:
- Private (default)
- Package
- Public
A constant has a Type and a corresponding type value.
Document Variable
The value of a global variable can be changed at runtime. Global variables can only be used in the same document. They have, therefore only the following Visibilities:
- Private (fix)
A variable has a Type and a corresponding type the initial value (default value).
Context Variable
Context variables behave like global constants. However, they have a special meaning. They represent environment-related data, such as vehicle type, name of workshop, Logged in User, etc., see the Context Concept. Context variables have one of the following visibilities:
- Private (default)
- Package
- Public
A context variable has a Type and a corresponding type the default value.
Checker rules
Core_Chk051 | Immutability of constants, input parameters and context variables |
Core_Chk009 | Mandatory constant initialisation |
See also
Validation (OTX-Checker)
Naming Conventions
Imports
Visibilities
Validities
Signatures
Parameter Declarations
Procedures
Comments