2020-03-24 22:17:03 +01:00
|
|
|
import 'package:equatable/equatable.dart';
|
2020-03-28 14:35:41 +01:00
|
|
|
import 'package:meta/meta.dart';
|
2020-03-24 22:17:03 +01:00
|
|
|
|
|
|
|
class Song extends Equatable {
|
2020-04-11 14:27:49 +02:00
|
|
|
const Song({
|
2020-03-28 14:35:41 +01:00
|
|
|
@required this.title,
|
|
|
|
@required this.album,
|
|
|
|
@required this.artist,
|
|
|
|
@required this.path,
|
2020-04-11 14:27:49 +02:00
|
|
|
@required this.duration,
|
2020-09-19 17:08:48 +02:00
|
|
|
@required this.blocked,
|
2020-09-28 20:04:03 +02:00
|
|
|
this.discNumber,
|
2020-03-28 14:35:41 +01:00
|
|
|
this.trackNumber,
|
|
|
|
this.albumArtPath,
|
|
|
|
});
|
|
|
|
|
2020-03-24 22:17:03 +01:00
|
|
|
final String title;
|
|
|
|
final String album;
|
|
|
|
final String artist;
|
|
|
|
final String path;
|
2020-04-11 14:27:49 +02:00
|
|
|
/// Duration in milliseconds.
|
|
|
|
final int duration;
|
2020-09-28 20:04:03 +02:00
|
|
|
final int discNumber;
|
2020-04-11 14:27:49 +02:00
|
|
|
final int trackNumber;
|
2020-03-24 22:17:03 +01:00
|
|
|
final String albumArtPath;
|
2020-09-19 17:08:48 +02:00
|
|
|
/// Is this song blocked in shuffle mode?
|
|
|
|
final bool blocked;
|
2020-03-24 22:17:03 +01:00
|
|
|
|
|
|
|
@override
|
|
|
|
List<Object> get props => [title, album, artist];
|
|
|
|
}
|