TriggerBlock

class TriggerBlock

Returned by

MODE_STARTTRIGGER_TO_NEXT_STOPTRIGGER

Returns the constant used to specify the expectation mode ‘from start trigger until next time stop trigger is fulfilled’.

Returns:

The constant

Return type:

str

MODE_STARTTRIGGER_WHILE_NOT_STOPTRIGGER

Returns the constant used to specify the expectation mode ‘from start trigger as long as stop trigger is not fulfilled’.

Returns:

The constant

Return type:

str

MODE_STARTTRIGGER_WITH_TIME_OFFSETS

Returns the constant used to specify the expectation mode ‘with time offset if start trigger is fulfilled’.

Returns:

The constant

Return type:

str

MODE_WHILE_STARTTRIGGER

Returns the constant used to specify the expectation mode ‘as long as start trigger is fulfilled’.

Returns:

The constant

Return type:

str

AddTag(tag)

Add a specific tag to this step.

Parameters:
tag : str

The tag to be set

AppendTraceStep(traceStep)

Adds a trace step at the end of its children.

Parameters:
traceStep

Trace step to be added

Clone()

Call this method if you want to use API-objects in multiple contexts, e.g. if you want to insert a specific test step in multiple blocks.

Returns:

A copy of this object

Return type:

TriggerBlock

GetDescription()

Returns the description of the trace analysis element.

Returns:

The description

Return type:

str

GetEndOfTraceAsStopTrigger()

Returns whether the end of trace shall be handled as a stop trigger.

Returns:

The setting for the treatment of unfinished ranges at the end of trace

Return type:

bool

GetIgnoreFirstMode()

Returns the ignore first mode.

Returns:

The mode: ‘manual’, ‘firstsample’ or ‘disabled’

Return type:

str

GetIgnoreFirstTime()

Returns the ignore first time if set. Otherwise None is returned.

Returns:

The expression value (only for manual mode)

Return type:

str

GetIgnoreLastMode()

Returns the ignore last mode.

Returns:

The mode: ‘manual’ or ‘disabled’

Return type:

str

GetIgnoreLastTime()

Returns the ignore last time if set. Otherwise None is returned.

Returns:

The expression value (only for manual mode)

Return type:

str

GetIndex()

Returns the zero based index in the parent.

Returns:

Zero based index

Return type:

int

GetLineNo()

Returns the trace steps line number within its trace analysis.

Returns:

Line number

Return type:

int

GetName()

Returns the name of the trace analysis element.

Returns:

The name

Return type:

str

GetReportEntryLimit()

Returns the maximal number of entries per verdict and child the reporting shall be limited to. A return value of None indicates that no limitation is in place.

Returns:

The maximal number of entries per verdict and child as expression string or None

Return type:

str

GetReportFilterCondition()

Returns the condition that must be matched for the trigger range to be reported. Possible values are: - ‘NONE’ (meaning no filtering for verdict types) - ‘SUCCESS’ (meaning SUCCESS or worse) - ‘INCONCLUSIVE’ (meaning INCONCLUSIVE or worse) - ‘FAILED’ (meaning FAILED or worse) - ‘ERROR’ (meaning ERROR)

Returns:

The report condition

Return type:

str

GetReportIgnoredRanges()

Returns whether ranges without a sample after consideration of the ignore times should be reported.

Returns:

The setting whether ignored ranges will be reported

Return type:

bool

GetReportOmittedStartTrigger()

Returns whether omitted start triggers will be reported.

Returns:

The setting whether omitted start triggers will be reported

Return type:

bool

GetResultNoMatch()

Returns the verdict of a trigger block that does not open any trigger range.

Returns:

The verdict of a trigger block without a trigger range

Return type:

str

GetResultTruncatedRange()

Returns the blanket verdict of a truncated trigger range or None if truncated trigger ranges are evaluated normally.

Returns:

The verdict of a truncated trigger range

Return type:

str

GetStartOffset()

Returns the start offset expression or None if no start offset is defined.

Returns:

The start offset or None if no start offset is defined

Return type:

str

GetStartTrigger()

Returns the start trigger expression.

Returns:

The start trigger expression

Return type:

str

GetStopOffset()

Returns the stop offset expression or None if no stop offset is defined.

Returns:

The stop offset or None if no stop offset is defined

Return type:

str

GetStopTrigger()

Returns the stop trigger expression or None if no stop trigger is defined.

Returns:

The stop trigger expression

Return type:

str

GetTags()

Returns the tags set for this step.

Returns:

A (sorted) list of tags

Return type:

list[str]

GetTraceSteps(skipDisabledSteps=False, recursive=False)

Returns either direct or all children of the trace step.

Parameters:
skipDisabledSteps : boolean

Defines whether disabled trace steps should be excluded, defaults to False.

recursive : boolean

Defines whether children of children are included, defaults to False.

Returns:

The trace steps as flat list.

Return type:

list[TraceStep]

GetTriggerMode()

Returns the trigger mode.

Returns:

The trigger mode

Return type:

str

GetTriggerOnce()

Returns whether the trigger block should trigger only once.

Returns:

The setting for restricting the number of trigger ranges to one

Return type:

bool

GetType()

Returns the type (class name) of the trace step, e.g.

  • ‘Episode’

  • ‘AnalysisBlock’

  • ‘TriggerBlock’

  • ‘Calculation’

  • ‘TemplateBasedTraceStep’

  • ‘TraceAnalysisReference’

  • ‘TraceAnalysisReferenceDeprecated’

Returns:

Type (class name) of the trace step

Return type:

str

GetUuid()

Returns the UUID of the trace step.

Returns:

UUID of the trace step

Return type:

str

InsertTraceStep(traceStep, position)

Adds a trace step at a certain line of the trace analysis.

Parameters:
traceStep

Trace step to be added

position : integer

Target index of child beginning with 0

IsContainer()

Checks whether this trace step can contain trace steps.

Returns:

True if it can contain trace steps, else False

Return type:

boolean

IsEnabled()

Checks whether the trace step is enabled.

Returns:

True if trace step is enabled, else False

Return type:

boolean

IsOk()

Returns the internal state of correctness of the trace step.

Returns:

True if no problems were found, else False

Return type:

boolean

IsVisible()

Checks whether the trace step is visible. This depends on the trace step itself or a parent trace step being disabled.

Returns:

True if trace step is visible, else False

Return type:

boolean

RemoveTag(tag)

Remove a specific tag from this step.

Parameters:
tag : str

The tag to be removed

RemoveTraceStep(traceStep)

Removes the given trace step from the trace analysis.

Parameters:
traceStep

Trace step to be removed

SetDescription(value)

Sets the description of the trace analysis element.

Parameters:
value : str

The new description

SetEnabled(enable)

Enables or disables the trace step (this also affects child trace steps).

Parameters:
enable : boolean

If True, enables the trace step, if False, disables the trace step

SetEndOfTraceAsStopTrigger(mode)

Sets whether the end of trace shall be handled as a stop trigger.

Parameters:
mode : bool

If True, unfinished ranges will be completed as if an ordinary stop trigger occurred. Otherwise such ranges will be rated INCONCLUSIVE.

SetIgnoreFirst(mode, ignoreTime=None)

Sets whether at the start of each trigger range a quantity of samples should be excluded. Possible values for mode are: ‘disabled’, ‘manual’ or ‘firstsample’. In the latter mode the parameter ignoreTime will have no impact.

Parameters:
mode : str

The mode for ignore first

ignoreTime : str

The expression value for the ignored time (only for manual mode)

SetIgnoreLast(mode, ignoreTime=None)

Sets whether at the end of each trigger range a certain time span parameterized by ignoreTime should be excluded. Possible values for mode are: ‘disabled’ or ‘manual’.

Parameters:
mode : str

The mode for ignore last

ignoreTime : str

The expression value for the ignored time (only for manual mode)

SetName(value)

Sets the name of the trace analysis element.

Parameters:
value : str

The new name

SetReportEntryLimit(maxEntryCount)

Sets the maximal number of entries per verdict and child the reporting shall be limited to. A value of None specifies that no limit shall be applied.

Parameters:
maxEntryCount : str

The maximal number of entries per verdict as expression or None

SetReportFilterCondition(condition)

Sets the condition that must be matched for the trigger range to be reported. Possible values are: - ‘NONE’ (meaning no filtering for verdict types) - ‘SUCCESS’ (meaning SUCCESS or worse) - ‘INCONCLUSIVE’ (meaning INCONCLUSIVE or worse) - ‘FAILED’ (meaning FAILED or worse) - ‘ERROR’ (meaning ERROR)

Parameters:
condition : str

The report condition

SetReportIgnoredRanges(reportRanges)

Sets whether ranges without a sample after consideration of the ignore times should be reported.

Parameters:
reportRanges : bool

If true, a range whose samples are completely left out due to the ignore times will be reported as NONE range. Otherwise it will not be reported.

SetReportOmittedStartTrigger(reportTrigger)

Sets whether omitted start triggers will be reported.

Parameters:
reportTrigger : bool

If true, for every omitted start trigger of the mode ‘start trigger while not stop trigger’ a spot will be generated.

SetResultNoMatch(result)

Sets the verdict of a trigger block that does not open any trigger range. Possible values: ‘NONE’, ‘SUCCESS’, ‘INCONCLUSIVE’, ‘FAILED’ or ‘ERROR’.

Parameters:
result : str

The verdict of a trigger block without a trigger range

SetResultTruncatedRange(result)

Sets the blanket verdict of a truncated trigger range. Possible values of verdicts: ‘NONE’, ‘SUCCESS’, ‘INCONCLUSIVE’, ‘FAILED’ or ‘ERROR’.

Set to None if truncated trigger ranges shall be evaluated normally

Parameters:
result : str

The verdict of a truncated trigger range

SetStartOffset(startOffset)

Sets the start offset expression.

Parameters:
startOffset : str

The start offset

SetStartTrigger(startTrigger)

Sets the start trigger expression.

Parameters:
startTrigger : str

The start trigger expression

SetStopOffset(stopOffset)

Sets the stop offset expression.

Parameters:
stopOffset : str

The start offset

SetStopTrigger(stopTrigger)

Sets the stop trigger expression.

Parameters:
stopTrigger : str

The stop trigger expression

SetTags(tags)

Set the list of tags for this step. The list of tags will be sorted and stored.

Parameters:
tags : list[str]

The list of tags

SetTriggerMode(triggerMode)

Sets the trigger mode. Possible values for mode can be obtained by either of the constants:

Parameters:
triggerMode : str

The stop trigger expression

SetTriggerOnce(triggerOnce)

Sets whether the trigger block should trigger once or repeatedly.

Parameters:
triggerOnce : bool

If true, only the very first trigger range that is found will be analyzed. Further ranges will be ignored.