wowhead

package
v1.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 14, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Client = &http.Client{
		Transport: transport,
	}
)

Functions

This section is empty.

Types

type Error

type Error struct {
	Err string `xml:"error"`
}

func (Error) Error

func (e Error) Error() string

type Gem

type Gem struct {
	Quality int64
	Name    string
	Color   string
}

func GetGem

func GetGem(ctx context.Context, gemID int64) (*Gem, error)

type Item

type Item struct {
	Name    string `json:"name"`
	Slot    string `json:"slot"`
	Sockets int64  `json:"sockets"`
}

func GetItem

func GetItem(ctx context.Context, itemID int64) (*Item, error)

type WowheadItem

type WowheadItem struct {
	XMLName xml.Name `xml:"wowhead"`
	Text    string   `xml:",chardata"`
	Item    struct {
		Text    string `xml:",chardata"`
		ID      string `xml:"id,attr"`
		Name    string `xml:"name"`
		Level   string `xml:"level"`
		Quality struct {
			Text string `xml:",chardata"`
			ID   string `xml:"id,attr"`
		} `xml:"quality"`
		InventorySlot struct {
			Text string `xml:",chardata"`
			ID   string `xml:"id,attr"`
		} `xml:"inventorySlot"`
		JSON      string `xml:"json"`
		JsonEquip string `xml:"jsonEquip"`
		Link      string `xml:"link"`
	} `xml:"item"`
}

type WowheadSpell added in v1.6.0

type WowheadSpell struct {
	SpellID int64
	Name    string
	Rank    int64
}

func GetSpell added in v1.6.0

func GetSpell(ctx context.Context, spellID int64) (*WowheadSpell, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL