Documentation ¶
Index ¶
- type Client
- func (c *Client) BoxScore(season data.Season, gameID string) (*data.BoxScore, error)
- func (c *Client) GameDetails(gameID string) (*data.GameDetails, error)
- func (c *Client) GamePlayByPlay(season data.Season, gameID string) ([]*data.Event, error)
- func (c *Client) Games(season data.Season) ([]data.GameID, error)
- func (c *Client) GamesByDate(date time.Time) ([]*data.Game, error)
- func (c *Client) GamesPlayedBy(season data.Season, teamID int) ([]data.GameID, error)
- func (c *Client) HistoricalPlayers() ([]*data.Player, error)
- func (c *Client) PlayerDetails(playerID int) (*data.PlayerDetails, error)
- func (c *Client) Players(season data.Season) ([]*data.Player, error)
- func (c *Client) Teams() ([]*data.Team, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
var ( DefaultClient *Client = &Client{ requester: &endpoints.DefaultRequester, } )
func (*Client) GameDetails ¶
func (c *Client) GameDetails(gameID string) (*data.GameDetails, error)
GameDetails returns detailed information about the given game.
func (*Client) GamePlayByPlay ¶
GamePlayByPlay returns a play-by-play list of events for a game.
func (*Client) Games ¶
Games returns the game IDs of all of the games played in the season, including playoff games.
func (*Client) GamesByDate ¶
GamesByDate retrieves all the NBA games happening on the given date.
func (*Client) GamesPlayedBy ¶
GamesPlayedBy returns the IDs of all games played by the given team so far in the provided season. Unfortunately, the stats.nba.com API does not provide upcoming games.
func (*Client) HistoricalPlayers ¶
HistoricalPlayers returns a slice of all players from all time.
func (*Client) PlayerDetails ¶
func (c *Client) PlayerDetails(playerID int) (*data.PlayerDetails, error)
Details returns detailed information about a player. It does not include stats about the player's performance.