Skip to content
Snippets Groups Projects
Commit 3727d808 authored by Patrick Dular's avatar Patrick Dular
Browse files

Added: members of structures being lists of strings and functions to get their...

Added: members of structures being lists of strings and functions to get their elements or the full lists; also added: function to get full lists of strings (was not available)
parent 7a601dbb
No related branches found
No related tags found
No related merge requests found
......@@ -12,7 +12,8 @@ Struct struct_identifier [
struct_member_real_2 22.,
struct_member_string_1 "string1",
struct_member_string_2 "string2",
struct_member_list_of_real_1 { 111., 222., 333. }
struct_member_list_of_real_1 { 111., 222., 333. },
struct_member_list_of_string_1 Str[ {"string_l_1", "string_l_2"} ]
];
// Look at the Current Workspace for checking the structure content.
......@@ -40,8 +41,14 @@ Struct NS1::St3 [ Type 3 ];
val_Type_of_Struct_St2 = St2.Type;
val_Type_of_Struct_St2_in_NS1 = NS1::St2.Type;
// Access to list members
one_element_from_a_list_member = struct_identifier.struct_member_list_of_real_1(1);
full_list_from_a_list_member() = struct_identifier.struct_member_list_of_real_1();
dim_list_member = #struct_identifier.struct_member_list_of_real_1();
one_string_from_a_list_member = Str[struct_identifier.struct_member_list_of_string_1(1)];
full_string_list_from_a_list_member() = Str[struct_identifier.struct_member_list_of_string_1()];
dim_string_list_member = #struct_identifier.struct_member_list_of_string_1();
// The function DimNameSpace(.) returns the number of structures in a given namespace:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment