pretty shell
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
||||
)
|
||||
|
||||
type MusicObject interface {
|
||||
GetSources() []Source
|
||||
Compile() MusicObject
|
||||
GetIndices() []string
|
||||
Merge(other MusicObject) MusicObject
|
||||
@@ -70,6 +71,10 @@ type Song struct {
|
||||
Sources []Source
|
||||
}
|
||||
|
||||
func (m Song) GetSources() []Source {
|
||||
return m.Sources
|
||||
}
|
||||
|
||||
func (m Song) GetIndices() []string {
|
||||
res := sourceIndices(m.Sources)
|
||||
if m.UnifiedName != "" {
|
||||
@@ -122,6 +127,10 @@ type Album struct {
|
||||
Sources []Source
|
||||
}
|
||||
|
||||
func (m Album) GetSources() []Source {
|
||||
return m.Sources
|
||||
}
|
||||
|
||||
func (m Album) GetIndices() []string {
|
||||
res := sourceIndices(m.Sources)
|
||||
if m.UnifiedName != "" {
|
||||
@@ -174,6 +183,10 @@ type Artist struct {
|
||||
Sources []Source
|
||||
}
|
||||
|
||||
func (m Artist) GetSources() []Source {
|
||||
return m.Sources
|
||||
}
|
||||
|
||||
func (m Artist) Merge(other MusicObject) MusicObject {
|
||||
otherArtist, ok := other.(Artist)
|
||||
if !ok {
|
||||
|
||||
Reference in New Issue
Block a user