API for Mappings¶
Part of the Object based program API.
- class MappingApi¶
Returned by
-
CreateAnalysisPackageMappingItem(pkgPath, referenceName=
None, namespace=None, checkTarget=True)¶ Creates an analysis package mapping item that references an analysis package (e.g. MyAnalysisPackage.ta). This mapping item can be used for analysis package mapping steps in a project, an analysis package reference in a test case or a referenced trace analysis. These steps do not reference a concrete analysis package. Instead, the implemented analysis label is resolved in the global mapping to get this reference.
- Parameters:
- pkgPath : str¶
Path to the referenced package, either absolute or relative to the packages directory of the current workspace or given namespace, e.g. ‘MyPackage.pkg’. An absolute path located in the current workspace will also be resolved to a relative workspace reference.
- referenceName : str¶
Name of the mapping item
- namespace : str¶
Identifier of the workspace to which a relative pkgPath is resolved. If not present or None, the namespace is determined automatically. It is also possible to reference a library workspace using its namespace. A relative pkgPath is resolved relative to the packages directory of the given namespace. For example, the namespace parameter ‘myLibrary’ results in ‘<libraries.myLibrary.packages>/MyPackage.pkg’.
- checkTarget : boolean¶
Selects if path should be checked
- Returns:
The just created mapping item.
- Return type:
-
CreateAudioChannelMappingItem(systemIdentifier, channel=
1, output=False, referenceName=None, checkTarget=None)¶ Creates a mapping item pointing at a certain audio channel.
- Parameters:
- systemIdentifier : str¶
Name of the system according to the test configuration.
- channel : int¶
Number of channel (optional). Uses channel 1 if ommitted.
- output : boolean¶
True if this is an output channel
- referenceName : str¶
Name of the mapping item (optional).
- checkTarget : boolean¶
Determines if the target path should be checked (optional).
- Returns:
The new mapping item
- Return type:
-
CreateAudioDeviceMappingItem(systemIdentifier, referenceName=
None, checkTarget=True)¶ Creates a mapping item pointing at a certain audio device.
- Parameters:
- Returns:
The new mapping item
- Return type:
-
CreateBusMonitoringMappingItem(systemIdentifier, nodeName, frameName, referenceName=
None, checkTarget=True)¶ Creates a bus monitoring mapping item of the desired variable type.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateBusSignalGroupMappingItem(systemIdentifier, nodeName=
'', frameName='', pduName='', referenceName=None, checkTarget=True, switchCode=None)¶ Creates a bus signal group mapping item of the desired variable type.
- Parameters:
- systemIdentifier : str¶
Name of Bus system according to the test configuration
- nodeName : str¶
Name of sending ECU (optional)
- frameName : str¶
Name of the frame containing the signal (optional)
- pduName : str¶
Name of the PDU containing the signal (optional)
- referenceName : str¶
Name of the mapping item (optional)
- checkTarget : boolean¶
Selects if target path should be checked (optional)
- switchCode : int¶
In case the underlying bus database does not support PDU names, switch code can be specified to disambiguate between multiplexed PDUs
- Returns:
The just created mapping item
- Return type:
-
CreateBusSignalWithPduMappingItem(systemIdentifier, signalName, nodeName=
'', frameName='', pduName='', referenceName=None, checkTarget=True)¶ Creates a bus signal mapping item of the desired variable type.
- Parameters:
- systemIdentifier : str¶
Name of Bus system according to the test configuration
- signalName : str¶
Name of the signal
- nodeName : str¶
Name of sending ECU (optional)
- frameName : str¶
Name of the frame containing the signal (optional)
- pduName : str¶
Name of the PDU containing the signal (optional)
- referenceName : str¶
Name of the mapping item
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreateCalibrationMappingItem(systemIdentifier, targetPath, variableType=
None, referenceName=None, xElement=None, yElement=None, checkTarget=True)¶ Creates a calibration mapping item of the desired variable type.
- Parameters:
- systemIdentifier : str¶
Name of ECU according to the test configuration
- targetPath : str¶
Name of calibration variable to be accessed
- variableType : str¶
Type of variable to be mapped (VALUE, VECTOR, MATRIX, CURVE, MAP, VECTOR-ELEMENT, MATRIX-ELEMENT)
- referenceName : str¶
Name of the mapping item
- xElement : integer¶
Index on x axis if single element of VECTOR or MATRIX should be accessed
- yElement : integer¶
Index on y axis if single item of MATRIX should be accessed
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreateDebugMappingItem(ecuKey, targetPath, variableType=
None, referenceName=None, checkTarget=True)¶ Creates a debug mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateDebugRegisterMappingItem(ecuKey, targetPath, referenceName=
None, checkTarget=True)¶ Creates a debug register mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateDiagDidMappingItem(systemIdentifier, name, referenceName=
None, checkTarget=True)¶ Creates DIAG DID mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateDiagFaultMemoryMappingItem(ecuKey, referenceName=
None)¶ Creates a fault memory mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateDiagObdOnUdsServiceMappingItem(systemIdentifier, name, referenceName=
None, checkTarget=True)¶ Creates a OBD Service mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateDiagRoutineMappingItem(systemIdentifier, name, referenceName=
None, checkTarget=True)¶ Creates DIAG RoutineControl mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateDiagServiceMappingItem(systemIdentifier, name, protocol=
0, referenceName=None, checkTarget=True)¶ Creates a DIAG Service mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateEdiabasVariableMappingItem(ecuKey, job, referenceName=
None, checkTarget=True)¶ Creates an ediabas variable mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateEesPinVariableMappingItem(systemIdentifier, name, referenceName=
None, checkTarget=True)¶ Creates an ees pin variable mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateEnvSimMappingItem(systemIdentifier, targetPath, variableType=
None, isSignal=False, referenceName=None, checkTarget=True)¶ Creates a mapping item of the desired variable type pointing at a certain envsim variable. The envsim has to be loaded in order to create a envsim mapping item.
- Parameters:
- systemIdentifier : str¶
Name of system according to the test configuration, e.g. “Plant model”
- targetPath : str¶
Path to the model variable to be accessed, e.g. “Model Root/varName”.
- variableType : str¶
Type of variable to be mapped (VALUE, VECTOR, MATRIX)
- isSignal : boolean¶
Selects if the mapping item should point to a model signal instead of variable
- referenceName : str¶
Name of the mapping item
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreateGenericMappingItem(variableType=
None, referenceName=None)¶ Creates a generic mapping item of the desired variable type.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateImageMappingItem(systemIdentifier, targetPath, maskPath=
'', referenceName=None, checkTarget=True)¶ Creates a mapping item pointing at a certain image variable.
- Parameters:
- systemIdentifier : str¶
Name of system according to the test configuration, e.g. “CAM”
- targetPath : str¶
Path to the image variable to be accessed, e.g. “Image” to read the whole image. To access a mask in a subfolder, the path to that folder must also be specified here, e.g. “Image/mymasks/moremasks/”. The actual name of the mask (and submask) however is specified in the parameter
maskPath.- maskPath : str¶
The name of the mask, submask and index to use, e.g. “MyMask[1, 1]/icon” would refer to the submask “icon” of index [1, 1] of the mask “MyMask”.
- referenceName : str¶
Name of the mapping item
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreateJobMappingItem(toolId, jobName, portId=
None, checkTarget=True, referenceName=None)¶ Creates a tool job or port job mapping item.
-
CreateLogFilterMessageMappingItem(ecuKey, messageName, referenceName=
None, checkTarget=True)¶ Creates a DLT log filter mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateLoggingArgumentMappingItem(systemIdentifier, messageName, argumentName, referenceName=
None, checkTarget=True)¶ Creates a logging argument mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateMappingItem(systemIdentifier, targetPath, referenceName=
None)¶ Creates a mapping item with automatically determined type.
The desired mapping target needs to exist in the currently loaded/activated configuration!
- Parameters:
- systemIdentifier : str¶
Name of system according to the test configuration
- targetPath : str¶
Name of bus, model, calibration or measure variable to be accessed (Needs indices if datatype is VECTOR-ELEMENT label[idx_X] or if datatype is MATRIX-ELEMENT label[idx_X][idx_Y])
Bus signals need a target path of the following form: “<nodeName>/<frameName>/<pduName>/<signalName>” Note: <nodeName>, <frameName> and <pduName> are optional, that means ///<signalName> is also valid. Logging arguments need a target path of the form: “/<messageName>/<argumentName>/”
- referenceName : str¶
Name of the mapping item
- Returns:
The just created mapping item
- Return type:
-
CreateMeasurementMappingItem(systemIdentifier, targetPath, variableType=
None, referenceName=None, xElement=None, yElement=None, zElement=None, checkTarget=True)¶ Creates a measurement mapping item of the desired variable type.
- Parameters:
- systemIdentifier : str¶
Name of ECU according to the test configuration
- targetPath : str¶
Name of measurement variable to be accessed
- variableType : str¶
Type of variable to be mapped (VALUE, VECTOR, MATRIX, VECTOR-ELEMENT, MATRIX-ELEMENT)
- referenceName : str¶
Name of the mapping item
- xElement : integer¶
Index on x axis if single element of VECTOR or MATRIX should be accessed
- yElement : integer¶
Index on y axis if single element of MATRIX should be accessed
- zElement : integer¶
Index on z axis if single element of MATRIX should be accessed
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreateModelMappingItem(systemIdentifier, targetPath, variableType=
None, isSignal=False, referenceName=None, checkTarget=True)¶ Creates a mapping item of the desired variable type pointing at a certain model variable. The model has to be loaded in order to create a model mapping item.
- Parameters:
- systemIdentifier : str¶
Name of system according to the test configuration, e.g. “Plant model”
- targetPath : str¶
Path to the model variable to be accessed, e.g. “Model Root/varName”.
- variableType : str¶
Type of variable to be mapped (VALUE, VECTOR, MATRIX)
- isSignal : boolean¶
Selects if the mapping item should point to a model signal instead of variable
- referenceName : str¶
Name of the mapping item
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreatePackageMappingItem(pkgPath, referenceName=
None, namespace=None, checkTarget=True)¶ Creates a package mapping item referencing the given package path. For example, CreatePackageMappingItem(‘MyPackage.pkg’) results in a reference to ‘<workspace.packages>/MyPackage.pkg’.
- Parameters:
- pkgPath : str¶
Path to the referenced package, either absolute or relative to the packages directory of the current workspace or given namespace, e.g. ‘MyPackage.pkg’. An absolute path located in the current workspace will also be resolved to a relative workspace reference.
- referenceName : str¶
Name of the mapping item
- namespace : str¶
Identifier of the workspace to which a relative pkgPath is resolved. If not present or None, the namespace is determined automatically. It is also possible to reference a library workspace using its namespace. A relative pkgPath is resolved relative to the packages directory of the given namespace. For example, the namespace parameter ‘myLibrary’ results in ‘<libraries.myLibrary.packages>/MyPackage.pkg’.
- checkTarget : boolean¶
Selects if target path should be checked
- Returns:
The just created mapping item
- Return type:
-
CreatePortMappingItem(systemIdentifier, portType, referenceName=
None, checkTarget=True)¶ Creates a port mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateReferenceMappingItem(mappingItem, referenceName=
None)¶ Creates a mapping item that references another mapping item. The created mapping item can be assigned as the target of mappings in the context of a parameter set of a project’s test case.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateRunningValueMappingItem(systemIdentifier, targetPath, referenceName=
None, checkTarget=True)¶ Creates a running value mapping item of the desired variable type.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateServiceEventLeafMappingItem(systemIdentifier, ecuName, serviceName, eventName, variablePath, eventgroupName=
'', fieldName='', serviceConsumer='', referenceName=None, checkTarget=True)¶ Creates a service event leaf mapping item.
- Parameters:
- systemIdentifier : str¶
SUT key
- ecuName : str¶
Name of the ECU that provides the service
- serviceName : str¶
Name of the service that provides the event
- eventName : str¶
Name of the event
- variablePath : str¶
Path to the return leaf node
- eventgroupName : str¶
Name of the event group that contains the event (optional)
- fieldName : str¶
Name of the field to which the event belongs (optional)
- serviceConsumer : str¶
Name of the consumer ECU (optional)
- referenceName : str¶
Name of the mapping item (optional)
- checkTarget : boolean¶
Selects if target path should be checked (optional)
- Returns:
The just created mapping item
- Return type:
-
CreateServiceMappingItem(systemIdentifier, ecuName, serviceName, eventOrMethodName, fieldName=
'', eventGroupName='', serviceConsumer='', referenceName=None, checkTarget=True)¶ Creates a service field event mapping item.
- Parameters:
- systemIdentifier : str¶
SUT key
- ecuName : str¶
Name of the ECU that provides the service
- serviceName : str¶
Name of the service that provides the event
- eventOrMethodName : str¶
Name of the event or the method
- fieldName : str¶
Name of the field (optional)
- eventGroupName : str¶
Name of the event group that contains the event (optional)
- serviceConsumer : str¶
Name of the consumer ECU (optional)
- referenceName : str¶
Name of the mapping item (optional)
- checkTarget : boolean¶
Selects if target path should be checked (optional)
- Returns:
The just created mapping item
- Return type:
-
CreateServiceMethodParameterMappingItem(systemIdentifier, ecuName, serviceName, methodName, variablePath, eventgroupName=
'', fieldName='', serviceConsumer='', referenceName=None, checkTarget=True)¶ Creates a service method parameter mapping item.
- Parameters:
- systemIdentifier : str¶
SUT key
- ecuName : str¶
Name of the ECU that provides the service
- serviceName : str¶
Name of the service that provides the method
- methodName : str¶
Name of the method
- variablePath : str¶
Path to the parameter leaf node
- eventgroupName : str¶
Name of the event group that contains the method (optional)
- fieldName : str¶
Name of the field to which the method belongs (optional)
- serviceConsumer : str¶
Name of the consumer ECU (optional)
- referenceName : str¶
Name of the mapping item (optional)
- checkTarget : boolean¶
Selects if target path should be checked (optional)
- Returns:
The just created mapping item
- Return type:
-
CreateServiceMethodReturnMappingItem(systemIdentifier, ecuName, serviceName, methodName, variablePath, eventgroupName=
'', fieldName='', serviceConsumer='', referenceName=None, checkTarget=True)¶ Creates a service method return mapping item.
- Parameters:
- systemIdentifier : str¶
SUT key
- ecuName : str¶
Name of the ECU that provides the service
- serviceName : str¶
Name of the service that provides the method
- methodName : str¶
Name of the method
- variablePath : str¶
Path to the return leaf node
- eventgroupName : str¶
Name of the event group that contains the method (optional)
- fieldName : str¶
Name of the field to which the method belongs (optional)
- serviceConsumer : str¶
Name of the consumer ECU (optional)
- referenceName : str¶
Name of the mapping item (optional)
- checkTarget : boolean¶
Selects if target path should be checked (optional)
- Returns:
The just created mapping item
- Return type:
-
CreateServiceServiceMappingItem(systemIdentifier, ecuName, serviceName, referenceName=
None, checkTarget=True)¶ Creates a service mapping item.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateTraceFileMappingItem(targetPath, referenceName=
None, systemIdentifier=None)¶ Creates a trace file mapping item pointing at a certain trace file signal.
- Parameters:
- Returns:
The just created mapping item
- Return type:
-
CreateAnalysisPackageMappingItem(pkgPath, referenceName=