DataFileSegment¶
- class DataFileSegment¶
Returned by
- 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:
- GetActualDuration()¶
Returns the current duration of the DataFileSegment.
- Returns:
The calculated duration
- Return type:
float
- GetChannelPath()¶
Returns the name of the currently set channel path.
- Returns:
the name of the channel path
- Return type:
str
- GetChannelSource()¶
Returns the name of the currently set channel source.
- Returns:
the name of the channel source
- Return type:
str
- GetComment()¶
Returns the comment of the segment.
- Returns:
The comment
- Return type:
str
- GetDataVectorName()¶
Returns the name of the currently set data vector.
- Returns:
the name of the data vector
- Return type:
str
- GetDuration()¶
Returns the current duration of the signal segment.
- Returns:
The duration
- Return type:
float
- GetDurationExpression()¶
Returns the duration expression of the segment that is conform to the ASAM XIL GES syntax for ConstSymbol expressions.
- Return type:
str
- Returns:
the duration expression
- GetFinalValue()¶
Returns the final value of the signal segment.
- Returns:
the final value
- Return type:
float
- GetFirstValue()¶
Returns the first value of the segment.
- Returns:
the first value or NaN
- Return type:
float
- GetGroupName()¶
Returns the name of the currently set group name.
- Returns:
the name of the group name
- Return type:
str
- GetGroupPath()¶
Returns the name of the currently set group path.
- Returns:
the name of the group path
- Return type:
str
- GetGroupSource()¶
Returns the name of the currently set group source.
- Returns:
the name of the group source
- Return type:
str
- GetStart()¶
Returns the start property of the DataFileSegment.
- Returns:
the start property
- Return type:
float
- GetStartExpression()¶
Returns the start expression of the segment.
- Return type:
str
- Returns:
the start expression
- GetStopTrigger()¶
Returns the stop trigger of the segment
- Returns:
stop trigger
- Return type:
str
- GetTimeVectorName()¶
Returns the name of the currently set time vector.
- Returns:
the name of the time vector
- Return type:
str
- GetTimeout()¶
Returns the timeout of the segment
- Returns:
timeout
- Return type:
float
- GetType()¶
Returns the type of the segment. (e.g. “Constant”)
- Returns:
The type
- Return type:
str
- GetValueAt(timestamp)¶
Returns the value at the given timestamp.
- Parameters:
- timestamp : float¶
The timestamp
- Returns:
the value or NaN
- Return type:
float
- RemoveStopTrigger()¶
Removes the stop trigger of the segment
- RemoveTimeout()¶
Removes the timeout of the segment
- SetChannelPath(channelPath)¶
Sets the name of the channel path.
- Parameters:
- channelPath : str¶
the name of the channel path
- SetChannelSource(channelSource)¶
Sets the name of the channel source.
- Parameters:
- channelSource : str¶
the name of the channel source
- SetDataVectorName(dataVectorName)¶
Sets the name of the data vector.
- Parameters:
- dataVectorName : str¶
the name of the data vector
- SetDuration(duration)¶
Sets the duration of the segment in seconds.If you want to set the duration value of the segment to an expression, use SetDurationExpression instead.
- Parameters:
- duration : float¶
the segments duration
- SetDurationExpression(expression)¶
Sets the duration of the segment in seconds. duration is also allowed to be a string which is an expression that is conform to the ASAM XIL GES syntax for ConstSymbol expressions. If you want to pass such an expression, use SetDurationExpression instead.
- Parameters:
- expression : str¶
the segments duration
- Raises:
ValueError – the duration is not in range
- SetGroupName(groupName)¶
Sets the name of the group name.
- Parameters:
- groupName : str¶
the name of the group name
- SetGroupPath(groupPath)¶
Sets the name of the group path.
- Parameters:
- groupPath : str¶
the name of the group path
- SetGroupSource(groupSource)¶
Sets the name of the group source.
- Parameters:
- groupSource : str¶
the name of the group source
- SetStart(start)¶
Sets the start property of the DataFileSegment.
- Parameters:
- start : float¶
the start value such that start is between the min and max value of the timeVector of the referenced DataFile or -inf
- SetStartExpression(expression)¶
Sets the expression for the start value of the DataFileSegment. The expression needs to be conform to the ASAM XIL GES syntax for ConstSymbol expressions.
- Parameters:
- expression : str¶
the start value expression
- SetStopTrigger(stopTrigger)¶
Sets the stop trigger of the segment
- Parameters:
- stopTrigger : str¶
The stop trigger
- SetTimeVectorName(timeVectorName)¶
Sets the timeVectorName of the segment
- Parameters:
- timeVectorName : str¶
the name of the time vector