Data Type Editor

The editor-datatype Data Type Editor supports you in creating Data Types.

Open Data Type Editor

CTRL+SHIFT+D, T

Open Editor

To open the Data Type Editor, expand your DaVinci Adaptive project in the DaVinci Project Explorer and double click on da-vinci-developer-adaptive Open Project Dashboard. The Project Frame opens showing the Project Home. You can then open the Data Type Editor as follows:

  • Open the editorsEditor menu on the top right of the Project Frame and click the editor-datatype Data Type Editor command.

  • Alternatively, use the context menu command editor-datatype Open Data Type Editor of the da-vinci-developer-adaptive Open Project Dashboard node in the DaVinci Project Explorer.

  • Alternatively, on the Dashboard page of the Project Home, click editor-datatype Data Type Editor in the Comfort Editors area.

The Data Type Editor opens in a new tab of the Project Frame.

Editor Toolbar

Besides the general editor functionalities (see Editor Concept ), the toolbar on the left side of the Data Type Editor provides the following feature:

add-multiple Clone Data Type: Clones an already available Data Type. A wizard will be opened where the name, package, and file can be adapted.

Data Types

The Data Type editor is used to manage the following CPP Implementation Data Types supported by AUTOSAR Adaptive:

  • value Value types (for example, bool, float, double, int, uint)

  • string Strings

  • array Arrays

  • vector Vectors

  • map-value Maps

  • struct Structs

  • enum Enums

  • reference Type Refs

  • application-error Application Errors

CPP Implementation Data Types are used to model abstractions of C++ Data Types. In AUTOSAR modeling, this is most commonly used to define what kind of information is expected to be consumed or provided in a Service Interface, for example, what type of data (uint8, string, array, etc.).

Functionality

The Data Type Editor provides the functionalities listed below. If not otherwise mentioned, the functionalities available in the details-mode-form-mode Form mode are described. If you want to manage the properties of an element textually, switch to the dml-editor DML mode via the toolbar and refer to DaVinci Modeling Language Editor for more information.

Table 1. Data Type Editor Functionality
Tree View Structure Description of Functionalities

value <Value types>

Select a Value type in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

string <Strings>

Select a String in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

array <Arrays>

Select an Array in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

Array Parameters Area

  • Array size: Enter the size of the Array.

  • Array content type: Specify the Data Type content of the Array.

  • Inplace: Specify whether the shortName of the referenced templateType is used in the code generation and the type declaration is defined outside of the enclosing CppImplementationDataType (true) or whether the type definition is embedded inside of the enclosing CppImplementationDataType and the shortName is ignored (false).

vector <Vectors>

Select a Vector in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

Vector Parameters Area

  • Max size: Enter the maximum size of the Vector.

  • Vector content type: Specify the Data Type content of the Vector.

  • Inplace: Specify whether the shortName of the referenced templateType is used in the code generation and the type declaration is defined outside of the enclosing CppImplementationDataType (true) or whether the type definition is embedded inside of the enclosing CppImplementationDataType and the shortName is ignored (false).

map-value <Maps>

Select a Map in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

Map Parameters Area

  • Key type: Type of the keys.

  • Inplace: Specify whether the shortName of the referenced templateType is used in the code generation and the type declaration is defined outside of the enclosing CppImplementationDataType (true) or whether the type definition is embedded inside of the enclosing CppImplementationDataType and the shortName is ignored (false).

  • Value type: Type of the mapped values.

  • Inplace: Specify whether the shortName of the referenced templateType is used in the code generation and the type declaration is defined outside of the enclosing CppImplementationDataType (true) or whether the type definition is embedded inside of the enclosing CppImplementationDataType and the shortName is ignored (false).

struct <Structs>

Select a Struct in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

Struct Parameters Area

  • Members Table: Displays each member of the Struct, along with its Data Type and whether it has attributes Inplace and Optional. Edit the columns to modify the values.

  • add Add Member: Click this icon to add a member.

  • delete Delete Member: Click this icon to delete a selected member.

  • arrow-up Move up: Click this icon to move a selected member up in the table.

  • arrow-down Move down: Click this icon to move a selected member down in the table.

enum <Enums>

Select an Enum in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the Data Type. Edit the field to change the name.

  • Description: Displays the description of the Data Type. Edit the field to change the description.

  • Namespace: Displays the namespace of the Data Type. Edit the field to change the namespace.

Enum Parameters Area

  • Enumerators Table: Displays the elements in the Enumeration, each consisting of a Label and a Value. Edit the columns to modify the values.

  • add Add Value: Click this icon to add a value.

  • delete Delete Value: Click this icon to delete a selected value.

  • arrow-up Move up: Click this icon to move a selected value up in the table.

  • arrow-down Move down: Click this icon to move a selected value down in the table.

application-error-name-space <ApApplicationErrorDomains>

Select an ApApplicationErrorDomain in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the ApApplicationErrorDomain. Edit the field to change the name.

  • Description: Displays the description of the ApApplicationErrorDomain. Edit the field to change the description.

  • Namespace: Displays the namespace of the ApApplicationErrorDomain. Edit the field to change the namespace.

  • Value: Displays the value representing the category of the Application Errors contained in the Domain. Edit the field to change the value.

  • Available Application Errors: Displays the Application Errors not already belonging to an Application Error Domain. Highlight an available Application Error and click map Map to Error Domain to add it to the Application Error Domain.

  • Application Errors of the Domain: Displays the Application Errors belonging to the Application Error Domain. Highlight an Application Error and click unmap Remove Error from Domain to remove it from the Application Error Domain.

tree-view-structure-child-elementapplication-error-name-space <ApApplicationErrorSets>

Select an ApApplicationErrorSet in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the ApApplicationErrorSet. Edit the field to change the name.

  • Description: Displays the description of the ApApplicationErrorDomains. Edit the field to change the description.

  • Available Application Errors: Displays the Application Errors not already belonging to an Application Error Set. Highlight an available Application Error and click map Map to Error Set to add it to the Application Error Set.

  • Application Errors of the Domain: Displays the Application Errors belonging to the Application Error Domain. Highlight an Application Error and click unmap Remove Error from Set to remove it from the Application Error Set.

tree-view-structure-child-elementtree-view-structure-child-elementapplication-error-name-space <ApApplicationErrors>

Select an ApApplicationError in the tree view on the left side of the editor.

The form page provides the following options:

  • Name: Displays the name of the ApApplicationError. Edit the field to change the name.

  • Description: Displays the description of the ApApplicationError. Edit the field to change the description.

  • Error Domain: Displays the Application Error Domain that the Application Error belongs to.

    • reference Select Reference Target of the Application Error Domain.

    • skeleton-model-wizard Create Reference Target of the Application Error Domain with the Skeleton Model Wizard.

  • Error Code: Displays the error code of the Application Error. Edit the field to change the value.