Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Album ¶
type Album struct { MediaObject Name string `json:"name"` ArtistID string `gorm:"size:64" json:"-"` Artist Artist `json:"-"` }
func (*Album) GetApiLink ¶
func (Album) MarshalJSON ¶
type Artist ¶
type Artist struct { MediaObject Name string `json:"name"` Albums []Album `json:"-"` }
func (*Artist) GetApiLink ¶
func (Artist) MarshalJSON ¶
type JsonArtist ¶
type JsonArtist Artist
type JsonPlaylist ¶
type JsonPlaylist Playlist
type MediaObject ¶
type MediaObject struct { special.UserBelongingObject Covername string `gorm:"size:128" json:"-"` }
func (*MediaObject) GetCoverLink ¶
func (m *MediaObject) GetCoverLink() string
GetCoverLink returns the link for the cover art
func (*MediaObject) GetUiLink ¶
func (m *MediaObject) GetUiLink() string
GetUiLink returns the link for the specific media objects ui
type Playlist ¶
type Playlist struct { MediaObject Name string `json:"name"` Songs []Song `gorm:"many2many:playlist_songs;" json:"-"` }
func (*Playlist) AddSong ¶
AddSong adds the given song to the playlist. Returns true, if song could be added, false if the song was already inside of the playlist
func (*Playlist) ContainsSong ¶
ContainsSong checks if the playlist contains the given song
func (*Playlist) GetApiLink ¶
func (Playlist) MarshalJSON ¶
type Song ¶
type Song struct { MediaObject Artists []Artist `gorm:"many2many:song_artists;" json:"-"` Title string `json:"title"` Track int `json:"track"` Size int64 `json:"size"` Duration float64 `json:"duration"` Filename string `gorm:"size:40" json:"-"` AlbumID string `gorm:"size:64" json:"-"` Album Album `json:"-"` Type string `json:"type"` Playlists []Playlist `gorm:"many2many:playlist_songs;" json:"-"` }
func (*Song) GetApiLink ¶
func (*Song) GetUploadFilePath ¶
func (Song) MarshalJSON ¶
Click to show internal directories.
Click to hide internal directories.