Documentation ¶
Index ¶
- Variables
- func ObfuscateDevInfo(info DevInfo) (string, error)
- func SanitizeURL(s string) string
- func Threads(ctx context.Context, dev DevInfo, user UserInfo) int
- type DevInfo
- type Game
- func (g Game) Date(r []string) (string, bool)
- func (g Game) Desc(l []string) (string, bool)
- func (g Game) Genre(l []string) (string, bool)
- func (game Game) Media(mediaType MediaType, regions []string) (string, bool)
- func (game Game) MediaWithFormat(mediaType MediaType, regions []string) (string, string, bool)
- func (g Game) Name(r []string) (string, bool)
- func (g Game) ROM(req GameInfoReq) (ROM, bool)
- type GameInfoReq
- type GameInfoResp
- type Genre
- type IDAndText
- type LanguageAndText
- type MediaType
- type Medium
- type ROM
- type RegionAndText
- type Response
- type TextField
- type UserInfo
- type UserInfoResp
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = errors.New("not found")
ErrNotFound is the error returned when a ROM isn't found.
Functions ¶
func ObfuscateDevInfo ¶ added in v1.4.0
func SanitizeURL ¶ added in v1.2.1
Types ¶
type DevInfo ¶
DevInfo is the information about the developer and used across APIs.
func DeobfuscateDevInfo ¶ added in v1.2.0
type Game ¶
type Game struct { ID string `json:"id"` Names []RegionAndText `json:"noms"` Descriptions []LanguageAndText `json:"synopsis"` Publisher IDAndText `json:"editeur"` Developer IDAndText `json:"developpeur"` Players TextField `json:"joueurs"` Rating TextField `json:"note"` Dates []RegionAndText `json:"dates"` Genres []Genre `json:"genres"` Medias []Medium `json:"medias"` ROMs []ROM `json:"roms"` // contains filtered or unexported fields }
func (Game) MediaWithFormat ¶
type GameInfoReq ¶
GameInfoReq is the information we use in the GameInfo command.
type GameInfoResp ¶
type GameInfoResp struct {
Response Response `json:"response"`
}
func GameInfo ¶
func GameInfo(ctx context.Context, dev DevInfo, user UserInfo, req GameInfoReq) (*GameInfoResp, error)
GameInfo is the call to get game info.
type Genre ¶
type Genre struct { ID string `json:"id"` Names []LanguageAndText `json:"noms"` }
type LanguageAndText ¶
type MediaType ¶
type MediaType string
const ( Screenshot MediaType = "ss" ScreenMarquee MediaType = "screenmarquee" Marquee MediaType = "marquee" Video MediaType = "video" Box2D MediaType = "box-2D" Box3D MediaType = "box-3D" Flyer MediaType = "flyer" Wheel MediaType = "wheel" Support2D MediaType = "support-2D" SupportLabel MediaType = "support-texture" )
type ROM ¶ added in v1.2.1
type RegionAndText ¶
type UserInfoResp ¶ added in v1.2.1
type UserInfoResp struct { ID string `xml:"ssuser>id"` Level int `xml:"ssuser>niveau"` Contribution int `xml:"ssuser>contribution"` UploadedSystems int `xml:"ssuser>uploadsysteme"` UploadedInfo int `xml:"ssuser>uploadinfos"` ROMsAssociated int `xml:"ssuser>romasso"` UpdatedMedia int `xml:"ssuser>uploadmedia"` FavoriteRegion string `xml:"ssuser>favregion"` MaxThreads int `xml:"ssuser>maxthreads"` }
Click to show internal directories.
Click to hide internal directories.