2. Variables are locations in memory that can hold
data
Variables
Hold data of a particular data type
●
Can be any data type
●
2
3. Variables are defined and exist in a particular
scope
Variables
Variables are locations in memory that can hold
data
Hold data of a particular data type
●
Can be any data type
●
Values can be accessed and modified in that scope
●
If execution leaves that scope, the variable is
destroyed
●
3
10. Passes a value from the outside scope
Input Parameter
10
11. Can be set as Mandatory
Input Parameter
Passes a value from the outside scope
Requires that the parameter must have
a value assigned to it
●
11
12. The variable is destroyed when execution
leaves the scope of the parent element
Input Parameter
Passes a value from the outside scope
Can be set as Mandatory
Requires that the parameter must have
a value assigned to it
●
12
14. A value should be assigned to the Output
Parameter inside its scope
The variable continues to exist in the
outside scope even after its parent
element's scope is gone
Output Parameter
Returns a value to the outside scope
14
15. The variable continues to exist in the
outside scope even after its parent
element's scope is gone
Output Parameter
Returns a value to the outside scope
A value should be assigned to the Output
Parameter inside its scope
15
17. Can be assigned and used "locally" inside
that scope
Local Variable
Exists exclusively within the scope of its
element
17
18. The variable is destroyed when execution
leaves the scope of the parent element
Local Variable
Exists exclusively within the scope of its
element
Can be assigned and used "locally" inside
that scope
18
19. OutSystems language is Strongly Typed
OutSystems Data Types
Every variable must declare its data type
●
That data type can not change
●
19
20. OutSystems supports:
OutSystems Data Types
OutSystems language is Strongly Typed
Every variable must declare its data type
●
That data type can not change
●
Basic Types
●
Compound Types
●
Lists
●
20
21. OutSystems supports:
OutSystems Data Types
OutSystems language is Strongly Typed
Every variable must declare its data type
●
That data type can not change
●
Basic Types: Integer, Text, Date, ...
●
Compound Types: Entities, Structures
●
Lists
●
21
22. OutSystems supports:
OutSystems Data Types
OutSystems language is Strongly Typed
Every variable must declare its data type
●
That data type can not change
●
Basic Types: Integer, Text, Date, ...
●
Compound Types: Entities, Structures
●
Lists
●
22
23. OutSystems supports:
OutSystems Data Types
OutSystems language is Strongly Typed
Every variable must declare its data type
●
That data type can not change
●
Basic Types: Integer, Text, Date, ...
●
Compound Types: Entities, Structures
●
Lists
●
23
24. Structures are custom compound data types
Structures
Defined by attributes of any data type
●
Including other Structures, Entities and Lists
●
Collection of other simple and compound data types
that are grouped together
●
24
25. Used to store compound data in memory
Structures
Structures are custom compound data types
Defined by attributes of any data type
●
Including other Structures, Entities and Lists
●
Collection of other simple and compound data types
that are grouped together
●
A Structure is the definition of a data type
●
The Structure itself does not hold any value
●
Structures are not variables
○
25
27. Add Structure Attributes
Creating Structures
Add Structure
Set its Name
●
Can be public
●
Set their Names and Data Types
●
Can be mandatory
●
Can have a default value
●
27
28. A List is a collection of elements of the same data
type (e.g. List of Integers)
Lists
28
29. Elements of OutSystems Lists can be:
Lists
A List is a collection of elements of the same data
type (e.g. List of Integers)
Basic types (e.g. Integer)
●
Compound types (e.g. Entities or Structures)
●
A union record between different types
●
e.g. Integer + Text
○
e.g. Booking + GuestName
○
29
30. Lists can be defined in the Data Type Editor
Lists
A List is a collection of elements of the same data
type (e.g. List of Integers)
Elements of OutSystems Lists can be:
Basic types (e.g. Integer)
●
Compound types (e.g. Entities or Structures)
●
A union record between different types
●
e.g. Integer + Text
○
e.g. Booking + GuestName
○
30