vendor!
This commit is contained in:
41
vendor/github.com/thehowl/go-osuapi/genre.go
generated
vendored
Normal file
41
vendor/github.com/thehowl/go-osuapi/genre.go
generated
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
package osuapi
|
||||
|
||||
import "strconv"
|
||||
|
||||
// Genres
|
||||
const (
|
||||
GenreAny Genre = iota
|
||||
GenreUnspecified
|
||||
GenreVideoGame
|
||||
GenreAnime
|
||||
GenreRock
|
||||
GenrePop
|
||||
GenreOther
|
||||
GenreNovelty
|
||||
GenreHipHop Genre = iota + 1 // there's no 8, so we must manually increment it by one
|
||||
GenreElectronic
|
||||
)
|
||||
|
||||
// Genre is the genre of a beatmap's song.
|
||||
type Genre int
|
||||
|
||||
var genreString = [...]string{
|
||||
"any",
|
||||
"unspecified",
|
||||
"video game",
|
||||
"anime",
|
||||
"rock",
|
||||
"pop",
|
||||
"other",
|
||||
"novelty",
|
||||
"8",
|
||||
"hip hop",
|
||||
"electronic",
|
||||
}
|
||||
|
||||
func (g Genre) String() string {
|
||||
if g >= 0 && int(g) < len(genreString) {
|
||||
return genreString[g]
|
||||
}
|
||||
return strconv.Itoa(int(g))
|
||||
}
|
Reference in New Issue
Block a user