forked from shkh/lastfm-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tag_result.go
123 lines (115 loc) · 3.16 KB
/
tag_result.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
package lastfm_go
import "encoding/xml"
// tag.getinfo
type TagGetInfo struct {
XMLName xml.Name `tag`
Name string `xml:"name"`
Url string `xml:"url"`
Reach string `xml:"reach"`
Taggings string `xml:"taggings"`
Streamable string `xml:"streamable"`
Wiki struct {
Published string `xml:"published"`
Summary string `xml:"summary"`
Content string `xml:"content"`
} `xml:"wiki"`
}
// tag.getSimilar
type TagGetSimilar struct {
XMLName xml.Name `xml:"similartags"`
Tag string `xml:"tag,attr"`
Tags []struct {
Name string `xml:"name"`
Url string `xml:"url"`
Streamable string `xml:"streamable"`
} `xml:"tag"`
}
// tag.getTopAlbums
type TagGetTopAlbums struct {
XMLName xml.Name `xml:"topalbums"`
Tag string `xml:"tag,attr"`
Total int `xml:"total,attr"`
Page int `xml:"page,attr"`
PerPage int `xml:"perPage,attr"`
TotalPages int `xml:"totalPages,attr"`
Albums []struct {
Rank string `xml:"rank,attr"`
Name string `xml:"name"`
Url string `xml:"url"`
Artist struct {
Name string `xml:"name"`
Mbid string `xml:"mbid"`
Url string `xml:"url"`
} `xml:"artist"`
Images []struct {
Size string `xml:"size,attr"`
Url string `xml:",chardata"`
} `xml:"image"`
} `xml:"album"`
}
// tag.getTopArtists
type TagGetTopArtists struct {
XMLName xml.Name `xml:"topartists"`
Tag string `xml:"tag,attr"`
//Total string `xml:"total,attr"`
//Page string `xml:"page,attr"`
//PerPage string `xml:"perPage,attr"`
//TotalPages string `xml:"totalPages"`
Artists []struct {
Rank string `xml:"rank,attr"`
Name string `xml:"name"`
Url string `xml:"url"`
Streamable string `xml:"streamable"`
Images []struct {
Size string `xml:"size,attr"`
Url string `xml:",chardata"`
} `xml:"image"`
} `xml:"artist"`
}
// tag.getTopTags
type TagGetTopTags struct {
XMLName xml.Name `xml:"toptags"`
Tags []struct {
Name string `xml:"name"`
Count string `xml:"count"`
Url string `xml:"url"`
} `xml:"tag"`
}
// tag.getTopTracks
type TagGetTopTracks struct {
XMLName xml.Name `xml:"toptracks"`
Tag string `xml:"tag,attr"`
Total int `xml:"total,attr"`
Page int `xml:"page,attr"`
PerPage int `xml:"perPage,attr"`
TotalPages int `xml:"totalPages,attr"`
Tracks []struct {
Rank string `xml:"rank,attr"`
Name string `xml:"name"`
Duration string `xml:"duration"`
Mbid string `xml:"mbid"`
Url string `xml:"url"`
Streamable struct {
FullTrack string `xml:"fulltrack,attr"`
Streamable string `xml:"streamable"`
} `xml:"streamable"`
Artist struct {
Name string `xml:"name"`
Mbid string `xml:"mbid"`
Url string `xml:"url"`
} `xml:"artist"`
Images []struct {
Size string `xml:"size,attr"`
Url string `xml:",chardata"`
} `xml:"image"`
} `xml:"track"`
}
// tag.getWeeklyChartList
type TagGetWeeklyChartList struct {
XMLName xml.Name `xml:"weeklychartlist"`
Tag string `xml:"tag,attr"`
Charts []struct {
From string `xml:"from,attr"`
To string `xml:"to,attr"`
} `xml:"chart"`
}