Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

Runtime security in procedures

&pagelevel(5)&pagelevel

When working with comprehensive, complex procedures, the speed at which they are generated in the foreground is less important than runtime security, clarity and ease of maintenance. Therefore, SDF-P offers programmers the option of declaring variables explicitly with a fixed data type. In the case of complex variables of the type STRUCTURE, SDF-P permits explicit declaration of variables with a fixed number of variable elements, each with a fixed data type (= static structures).

Explicit variable declaration

“Explicit variable declaration” means that simple and complex variables are declared by means of the appropriate commands (DECLARE-VARIABLE (see "DECLARE-VARIABLE Declare variable "), DECLARE-ELEMENT (see "DECLARE-ELEMENT Declare structure element "), DECLARE-CONSTANT (see "DECLARE-CONSTANT Declare variable with constant value ")). When variables are declared explicitly, unique variable attributes can also be defined at the same time.

The implicit declaration of variables can be disabled in S procedures by means of the SET-PROCEDURE-OPTIONS command in the procedure head (cf. chapter “Creating Sprocedures” (Creating the procedure head )).

Fixed data type

When variables are declared explicitly, a variable can be assigned a specific data type. Later on, this data type cannot be changed dynamically.

“Fixed data type” means that the variable can be assigned values of a specific data type only (for example, integer values only). Assignments of wrong data types are rejected and an error message is issued.

Static structures

Complex variables of the type structure can be declared as static. This means that the number of variable elements is already defined when the variable is declared and cannot subsequently be changed.