Documentation

Track
in package
implements JsonSerializable

Wrapper for songs

Interfaces, Classes, Traits and Enums

JsonSerializable

Table of Contents

$color  : string
$duration  : int
$picture  : string
$score  : int
$spotifyId  : string
$title  : string
__construct()  : mixed
getColor()  : string
Get song color
getDuration()  : string
Get song duration
getPicture()  : string
Get song picture
getScore()  : int
Get song score
getSpotifyId()  : string
Get song Spotify id
getTitle()  : string
Get song title
jsonSerialize()  : mixed
setScore()  : void
Set song score

Properties

$color

private string $color

Song color

$duration

private int $duration

Song duration

$picture

private string $picture

Song picture

$score

private int $score

Song votes

$spotifyId

private string $spotifyId

Song spotify id

$title

private string $title

Song title

Methods

__construct()

public __construct(string $title, string $spotifyId, string $picture, int $duration, int $score, string $color) : mixed
Parameters
$title : string
$spotifyId : string
$picture : string
$duration : int
$score : int
$color : string
Return values
mixed

getColor()

Get song color

public getColor() : string
Return values
string

getDuration()

Get song duration

public getDuration() : string
Return values
string

getPicture()

Get song picture

public getPicture() : string
Return values
string

getScore()

Get song score

public getScore() : int
Return values
int

getSpotifyId()

Get song Spotify id

public getSpotifyId() : string
Return values
string

getTitle()

Get song title

public getTitle() : string
Return values
string

jsonSerialize()

public jsonSerialize() : mixed
Return values
mixed

setScore()

Set song score

public setScore(int $score) : void
Parameters
$score : int
Return values
void

Search results