MovaTestStep class

测试内核的一步媒体行为;after 表示距上一步的等待时间,首步相对 open。 不需要了解首帧信号组合,就绪步骤会自动发出尺寸、时长、缓冲量和首帧。 示例:[MovaTestStep.ready(), MovaTestStep.completed(after: Duration(seconds: 2))]。

One delayed media signal; ready steps emit the complete first-frame sequence.

Constructors

MovaTestStep.buffering(bool value, {Duration after = Duration.zero})
在 after 后推送 value 缓冲状态,返回缓冲步骤。 示例:MovaTestStep.buffering(true, after: Duration(seconds: 1))。
const
MovaTestStep.completed({Duration after = Duration.zero})
在 after 后停止播放并标记结束,返回结束步骤。 示例:MovaTestStep.completed(after: Duration(seconds: 2))。
const
MovaTestStep.error(Object error, {Duration after = Duration.zero})
在 after 后推送内核 error,返回失败步骤;分类沿用真实播放器规则。 示例:MovaTestStep.error('Failed to open file')。
const
MovaTestStep.position(Duration value, {Duration after = Duration.zero})
在 after 后推进到 value,返回进度步骤。 示例:MovaTestStep.position(Duration(seconds: 10))。
const
MovaTestStep.ready({Duration after = Duration.zero, int width = _defaultWidth, int height = _defaultHeight, Duration duration = _defaultDuration})
在 after 后模拟首帧就绪;width/height 为帧尺寸,duration 为媒体时长。 返回就绪步骤;示例:MovaTestStep.ready(duration: Duration(minutes: 2))。
const

Properties

after → Duration
相对上一步的延迟;零表示异步执行,不留下定时器。
final
hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited