PlayerState class final

Media player

Annotations
  • @immutable

Constructors

PlayerState({required String id, required String venueId, String? name, required PlayerStatus status, String? showId, String? playlistId, String? timelineId, PlayerMatrixCell? matrixCell, int? itemIndex, String? assetId, required double position, double? duration, double? rate, bool? loop, double? volume, double? opacity, double? brightness, double? rotation, PlayerStateTarget? target, bool? pending, String? scheduledAt, Problem? error, required int revision, String? updatedAt, Map<String, Object?> extra = const {}})
Creates a PlayerState.
const
PlayerState.fromJson(Map<String, Object?> json, [String path = ''])
Decodes json; throws FormatException (with the JSON path) on a missing required member or a type mismatch. Unknown members and explicit nulls go to extra.
factory

Properties

assetId → String?
assetId member.
final
brightness → double?
0..1 (brightness, linear volume gain, progress).
final
duration → double?
duration member.
final
error → Problem?
error member.
final
extra → Map<String, Object?>
Members this version does not model (incl. x-* extensions and explicit nulls); written back by toJson.
final
hashCode → int
The hash code for this object.
no setteroverride
id → String
Document-scoped id (.dome displays[].id, assets[].id, playlist / cue ids); unique within its parent.
final
itemIndex → int?
itemIndex member.
final
loop → bool?
loop member.
final
matrixCell → PlayerMatrixCell?
matrixCell member.
final
name → String?
name member.
final
opacity → double?
0..1 (brightness, linear volume gain, progress).
final
pending → bool?
last command not yet acknowledged by the engine (2 s timeout); a later player.state resolves it
final
playlistId → String?
playlistId member.
final
position → double
Media position in seconds from the start.
final
rate → double?
playback rate, 1 = normal
final
revision → int
Monotonic resource revision; the strong ETag is derived from it.
final
rotation → double?
rotation member.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scheduledAt → String?
pending scheduled start (play.at)
final
showId → String?
showId member.
final
status → PlayerStatus
status member.
final
target → PlayerStateTarget?
target member.
final
timelineId → String?
timelineId member.
final
updatedAt → String?
RFC 3339 UTC with milliseconds, e.g. 2026-10-19T12:00:00.000Z.
final
venueId → String
Document-scoped id (.dome displays[].id, assets[].id, playlist / cue ids); unique within its parent.
final
volume → double?
0..1 (brightness, linear volume gain, progress).
final

Methods

copyWith({String? id, String? venueId, String? name, PlayerStatus? status, String? showId, String? playlistId, String? timelineId, PlayerMatrixCell? matrixCell, int? itemIndex, String? assetId, double? position, double? duration, double? rate, bool? loop, double? volume, double? opacity, double? brightness, double? rotation, PlayerStateTarget? target, bool? pending, String? scheduledAt, Problem? error, int? revision, String? updatedAt, Map<String, Object?>? extra}) → PlayerState
A copy with the given members replaced (a member cannot be reset to null this way).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, Object?>
Encodes to JSON (absent members omitted, extra merged back).
toString() → String
A string representation of this object.
override

Operators

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

Constants

schemaId → const String
$id of the schema this model describes.