More stuff
This commit is contained in:
+39
-18
@@ -1,23 +1,44 @@
|
||||
|
||||
export class Song {
|
||||
public type: SongType
|
||||
public title: string;
|
||||
public url: string;
|
||||
public image: string;
|
||||
public length: number | null;
|
||||
|
||||
|
||||
constructor(type: SongType, title: string, url: string, image: string, length: number | null = null) {
|
||||
this.type = type;
|
||||
this.title = title;
|
||||
this.url = url;
|
||||
this.image = image;
|
||||
this.length = length;
|
||||
}
|
||||
}
|
||||
|
||||
export enum SongType {
|
||||
YouTube,
|
||||
Spotify
|
||||
}
|
||||
|
||||
|
||||
export class SearchResult {
|
||||
public type: SongType
|
||||
public title: string;
|
||||
public songId: string;
|
||||
public image: string;
|
||||
|
||||
constructor(type: SongType, title: string, songId: string, image: string) {
|
||||
this.type = type;
|
||||
this.title = title;
|
||||
this.songId = songId;
|
||||
this.image = image;
|
||||
}
|
||||
}
|
||||
|
||||
export class QueuedSong {
|
||||
public title: string;
|
||||
public image: string;
|
||||
|
||||
|
||||
constructor(title: string, image: string) {
|
||||
this.title = title;
|
||||
this.image = image;
|
||||
}
|
||||
}
|
||||
|
||||
export class Song {
|
||||
public type: SongType
|
||||
public songId: string;
|
||||
public title: string;
|
||||
public position: number;
|
||||
|
||||
constructor(type: SongType, songId: string, title: string, position: number) {
|
||||
this.type = type;
|
||||
this.songId = songId;
|
||||
this.title = title;
|
||||
this.position = position;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user