OTX-Runtime for Java
|
|
The OTX-Runtime API has the following different categories of configuration:
The following settings are global settings, see RuntimeConfig.
Setting | Data Type | Get | Set | Default Value | Description |
---|---|---|---|---|---|
MinBinVersion | String | x | Gets the minimum version (Major.Minor.Branch.Revision) of the binary file that the OTX Runtime can handle | ||
Version | String | x | Gets the version of the API (Major.Minor.Branch.Revision) | ||
OutputFolder | String | x | x | Windows: "[Current User]/AppData/Roaming/OpenTestSystem/OTX-Runtime/", Linux: "[home]/OpenTestSystem/OTX-Runtime API/" | Gets or sets the folder where all temporary files which are created by the OTX-Runtime are stored |
TraceFolder | String | x | x | Windows: "[Current User]/AppData/Roaming/OpenTestSystem/OTX-Runtime/Tracing/", Linux: "[home]/OpenTestSystem/[API Short Version]/OTX-Runtime API/Tracing/" | Gets or sets the OTX-Runtime trace file folder |
TraceLevel | TraceLevels | x | x | ERROR | Gets or sets the OTX-Runtime trace Level. The Tracing is the internal logging of the API. |
TraceFileMaxCount | Integer | x | x | 10 | Gets or sets the OTX-Runtime max number of trace files. |
TraceFileMaxSize | Integer | x | x | 100 | Gets or sets the OTX-Runtime max size of a trace file (in MB). |
The following settings are valid for each runtime manager instance, see RuntimeManager.
Setting | Data Type | Get | Set | Default Value | Description |
---|---|---|---|---|---|
SearchPath | String | x | x | [ProjectDir];[ProjectDir]/.. | Gets or sets the search path which all relative path specifications inside OTX refer |
After a Project was loaded from an PTX file, see LoadPtx, the following content of the project will be updated.
Setting | Data Type | Get | Set | Description |
---|---|---|---|---|
Name | String | x | Gets the name of the project | |
Version | String | x | Gets the version of the project | |
Packages | Package | x | Gets all root packages of the project, see also OTX Browsing | |
StartupDocument | Document | x | Gets the startup document of the project, see also OTX Browsing | |
MainProcedure | Procedure | x | Gets the main procedure of the project, see also OTX Browsing |
Each project has ProjectSettings. The project settings are grouped into the following categories:
Note: Dependent how an PTX was exported inside the OTX Development Environment, the project settings can be transported via a PTX or PPX file.
The value of the project settings will be overwritten in the following order:
4. Setting set via the OTX-Runtime API, see ProjectSettingsNote: A PPX file contains one or more PTX files, see Projects.
The project settings can be get or set as single values, see ProjectSettings e.g. ExternalAppPath or LoggingOn or as a block of settings inside a map via
or in C++ and Java
Note: The key of the map is the full name of the related project setting, see table below.
Note: The block handling of project settings is a little bit faster then the handling of single values.
The project settings can also contains Settings of Custom Implementations. Each customer implementation can extent this list by new settings. The settings can be distinguished be the full name. The full name contains the Path
and the Name
of the setting concatenate with a dot ('.').
The following table gives an overview about the project settings, see also ProjectSettings.
Full Name | Extension | Data Type | Get | Set | Default Value | Description |
---|---|---|---|---|---|---|
Settings.Logging.Directory | Logging | String | x | x | Null | Name of the directory where the log files stored |
Settings.Logging.FileName | Logging | String | x | x | Name of logging file | |
Settings.Logging.FileSize | Logging | Integer | x | x | 10 | Size of logging file |
Settings.Logging.MaxFileNumber | Logging | Integer | x | x | 3 | Maximum number of total files |
Settings.Logging.HeaderFormat | Logging | String | x | x | Within Header and Message format placeholders can be used. These will be replaced at runtime with the current values. | |
Settings.Logging.MessageFormat | Logging | String | x | x | Within Header and Message format placeholders can be used. These will be replaced at runtime with the current values. | |
Settings.Logging.LogCommunicationTrace | Logging | Boolean | x | x | FALSE | State of Logging Communication Trace at Runtime |
Settings.Logging.LogVariableTrace | Logging | Boolean | x | x | FALSE | State of Logging Variable at Runtime |
Settings.Logging.LogOtxException | Logging | Boolean | x | x | FALSE | State of Logging Otx Exception at Runtime |
Settings.Logging.LogCommunicationTraceSeverityLevel | Logging | TraceLevels | x | x | TRACE | Log level of LogCommunitionTrace |
Settings.Logging.LogVariableTraceSeverityLevel | Logging | TraceLevels | x | x | TRACE | Log level of LogVariableTrace |
Settings.Logging.LogOtxExceptionSeverityLevel | Logging | TraceLevels | x | x | TRACE | Log level of LogOtxException |
Settings.Logging.WriteId | Logging | Boolean | x | x | FALSE | State of Logging Otx Id at Runtime |
Settings.Logging.WriteIdSeverityLevel | Logging | TraceLevels | x | x | TRACE | State of Logging OtxID at Runtime |
Settings.Logging.LoggingTargetResolving | Logging | Boolean | x | x | FALSE | This is useful only for exchange of PTX-containers with other tool environments |
Settings.Logging.LoggingLevelDefault | Logging | TraceLevels | x | x | ALL | Log level of Logging Extension |
Settings.Logging.LoggingOn | Logging | Boolean | x | x | TRUE | State of Logging Runtime |
Settings.I18n.Folder | I18n | String | x | x | Null | Directory where the language files stored |
Settings.I18n.DefaultLanguage | I18n | String | x | x | Null | Default language of i18n |
Settings.Quantity.UnitSpecFiles | Quantities | String | x | Null | The path of .odx file | |
Settings.DiagCom.Project | DiagCom | String | x | Null | The project name of DiagCom | |
Settings.DiagCom.Vehicle | DiagCom | String | x | Null | The vehicleInfo of DiagCom | |
Settings.TestResultHandling.DataModelFile | TestResultHandling | String | x | x | Null | Data model file |
Settings.TestResultHandling.TestResultHandlingFileName | TestResultHandling | String | x | x | "TestResults_???.xml" | Test result file name |
Settings.TestResultHandling.TestResultHandlingDirectory | TestResultHandling | String | x | x | Null | Directory name |
Settings.TestResultHandling.TestResultHandlingLevel | TestResultHandling | TestResultHandlingLevels | x | x | TRACK | The result handling level of the OTX-Runtime |
Settings.TestResultHandling.TestResultHandlingOn | TestResultHandling | Boolean | x | x | TRUE | The test result status |
Settings.Runtime.ExternalAppPath | Runtime | Boolean | x | x | TRUE | Gets or sets external application path is used |
Settings.Runtime.OtxMappings | Runtime | List<String> | x | Empty | Gets all OTX mapping files, which contained in the project | |
Settings.Runtime.OtxMapping | Runtime | String | x | x | Empty | Gets or sets the OTX-Mapping filename |
Settings.Runtime.ResourceMappings | Runtime | List<String> | x | Empty | Gets all resource mapping files, which contained in the project | |
Settings.Runtime.ResourceMapping | Runtime | String | x | x | Empty | Gets or sets the Resource-Mapping filename |
The settings for diagnostic communication must be set via the DiagManager. To set the settings for diagnostic communication the McdProject
and after that the DbVehicleInformation
of that project must be selected. This can be done in two ways:
See DiagRuntimeSystem constructor. For this way no DiagManager Client is needed.
See DiagConfiguration OTX extension. For this way a DiagManager Client is needed.
Note: Please note, that an exception will be thrown, if the DiagRuntimeSystem is not in the right state, e.g. it is connected to the VCI.
Note: Please note, that the change of the settings can have an influence to other clients which are maybe connected.
The settings of all custom implementations are handled via the Project Settings.
In certain situations values with complex data types, e.g. Map<Enumeration>
must be handled, e.g. project settings or parameter values. To simplify this, the following two conversion methods are provided.
Note for all settings: To convert an arbitrary complex value to and from a string literal, the following methods can be used: