NowPlayingTrack class

A container for metadata around a single track state

Artist, album, track, duration, genre, source, progress

Implementers

Constructors

NowPlayingTrack({String? id, String? title, String? album, String? artist, Duration duration = Duration.zero, NowPlayingState state = NowPlayingState.stopped, String? source, Duration position = Duration.zero, DateTime? createdAt})
NowPlayingTrack.fromJson(Map<String, dynamic> json)
Creates a track from json
factory

Properties

album String?
final
artist String?
final
createdAt DateTime
final
duration Duration
final
essentialAlbum String?
no setter
essentialTitle String?
no setter
hashCode int
The hash code for this object.
no setterinherited
hasIcon bool
no setter
hasImage bool
no setter
hasSpotifySource bool
no setter
icon ImageProvider<Object>?
An image representing the app playing the track
no setter
id String
final
image ImageProvider<Object>?
The image for the track, probably album art
getter/setter pair
imageNeedsResolving bool
true if the image is empty and a resolution hasn't been attempted, else false
no setter
isNotReported bool
no setter
isPaused bool
no setter
isPlaying bool
no setter
isReported bool
no setter
isResolvingImage bool
true if the image is being resolved, else false
no setter
isSpotify bool
final
isStopped bool
no setter
position Duration
final
progress Duration
How long the track been has been playing, as a Duration
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
source String?
final
state NowPlayingState
final
title String?
final

Methods

copy() NowPlayingTrack
Creates a copy of a track, largely so that the stream knows it's mutated
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolveImage() Future<void>
toString() String
A string representation of this object.
override

Operators

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

Static Properties

loading NowPlayingTrack
final
notPlaying NowPlayingTrack
final