Skip to content

Commit 0850a56

Browse files
IsmaeelAlNajarGitHub Enterprise
authored andcommitted
SKA-1016: Document multi-dimensional arrays (#200)
1 parent f09aecd commit 0850a56

1 file changed

Lines changed: 3 additions & 9 deletions

File tree

README.md

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -535,7 +535,7 @@ Each entry of the list must have the following attributes:
535535
The `Value` attribute may be one of the following:
536536
* A string (with single (`'`) or double (`"`) quotes) even if the content of the string is a numeric value;
537537
* A numeric value (example: `42`, `3.14`). If it's not representable by an integer type of size 64 bits or a double-precision floating point due to overflow, it'll be considered a string;
538-
* A list of the above (lists nesting is not supported).
538+
* A list of the above. Nested lists (for multi-dimensional arrays) are supported; see the syntax example below.
539539

540540
If the `VariableName` designates a variable whose type is an enumeration, integer values are interpreted as the the enumerator's underlying value. If it is a string, it is interpreted as an enumerator's name and the value is taken from the Model Description.
541541

@@ -549,10 +549,7 @@ Parameters:
549549
- VariableName: <enum-typed-variable-name-in-model-description>
550550
Value: "<name-of-enumerator-used-as-start-value>"
551551
- VariableName: <array-name-in-model-description>
552-
Value:
553-
- <first-item-of-the-start-value>
554-
- <second-item-of-the-start-value>
555-
- ...
552+
Value: [[<row-1-item-1>, <row-1-item-2>, ...], [<row-2-item-1>, <row-2-item-2>, ...], ...]
556553
- ...
557554
```
558555

@@ -636,10 +633,7 @@ Enumerators are not convertible.
636633
* In FMI 3.0, variables may also be (multi-dimensional) arrays.
637634
These are declared as lists in the FMU Importer (e.g., `List<Double>`).
638635
* Non-convertible data types cannot be used in type transformations.
639-
640-
>Note: Currently, the FMU Importer does not support nested lists.
641-
Therefore, multi-dimensional FMI arrays are handled as their flattened counterparts as defined in [the FMI 3.0 standard](https://fmi-standard.org/docs/3.0.1/#serialization-of-variables).
642-
This information is primarily important for other SIL Kit applications that want to exchange array data with the FMU Importer.
636+
* Multi-dimensional arrays are supported. In that case, `TransmissionType` can be nested lists, example: `List<List<T>>`
643637

644638
Members of structures that are not always available when the structure is distributed must be declared to be `optional`.
645639
This is done by appending a question mark (`?`) at the end of the data type.

0 commit comments

Comments
 (0)