Class: NBA::TeamGameLogStat
- Inherits:
-
Shale::Mapper
- Object
- Shale::Mapper
- NBA::TeamGameLogStat
- Defined in:
- lib/nba/team_game_log_stat.rb
Overview
Represents a single team game log entry from the batch endpoint
Instance Attribute Summary collapse
-
#ast ⇒ Integer
Returns the assists.
-
#blk ⇒ Integer
Returns the blocks.
-
#dreb ⇒ Integer
Returns the defensive rebounds.
-
#fg3_pct ⇒ Float
Returns the three-point percentage.
-
#fg3a ⇒ Integer
Returns the three-pointers attempted.
-
#fg3m ⇒ Integer
Returns the three-pointers made.
-
#fg_pct ⇒ Float
Returns the field goal percentage.
-
#fga ⇒ Integer
Returns the field goals attempted.
-
#fgm ⇒ Integer
Returns the field goals made.
-
#ft_pct ⇒ Float
Returns the free throw percentage.
-
#fta ⇒ Integer
Returns the free throws attempted.
-
#ftm ⇒ Integer
Returns the free throws made.
-
#game_date ⇒ String
Returns the game date.
-
#game_id ⇒ String
Returns the game ID.
-
#matchup ⇒ String
Returns the matchup description.
-
#min ⇒ Integer
Returns the minutes played.
-
#oreb ⇒ Integer
Returns the offensive rebounds.
-
#pf ⇒ Integer
Returns the personal fouls.
-
#plus_minus ⇒ Integer
Returns the plus/minus.
-
#pts ⇒ Integer
Returns the points scored.
-
#reb ⇒ Integer
Returns the total rebounds.
-
#season_year ⇒ String
Returns the season year.
-
#stl ⇒ Integer
Returns the steals.
-
#team_abbreviation ⇒ String
Returns the team abbreviation.
-
#team_id ⇒ Integer
Returns the team ID.
-
#team_name ⇒ String
Returns the team name.
-
#tov ⇒ Integer
Returns the turnovers.
-
#wl ⇒ String
Returns the win/loss indicator.
Instance Method Summary collapse
-
#game ⇒ Game?
Returns the game object for this log entry.
-
#loss? ⇒ Boolean
Returns whether the game was a loss.
-
#team ⇒ Team?
Returns the team object for this log entry.
-
#win? ⇒ Boolean
Returns whether the game was a win.
Instance Attribute Details
#ast ⇒ Integer
Returns the assists
185 |
# File 'lib/nba/team_game_log_stat.rb', line 185 attribute :ast, Shale::Type::Integer |
#blk ⇒ Integer
Returns the blocks
201 |
# File 'lib/nba/team_game_log_stat.rb', line 201 attribute :blk, Shale::Type::Integer |
#dreb ⇒ Integer
Returns the defensive rebounds
169 |
# File 'lib/nba/team_game_log_stat.rb', line 169 attribute :dreb, Shale::Type::Integer |
#fg3_pct ⇒ Float
Returns the three-point percentage
129 |
# File 'lib/nba/team_game_log_stat.rb', line 129 attribute :fg3_pct, Shale::Type::Float |
#fg3a ⇒ Integer
Returns the three-pointers attempted
121 |
# File 'lib/nba/team_game_log_stat.rb', line 121 attribute :fg3a, Shale::Type::Integer |
#fg3m ⇒ Integer
Returns the three-pointers made
113 |
# File 'lib/nba/team_game_log_stat.rb', line 113 attribute :fg3m, Shale::Type::Integer |
#fg_pct ⇒ Float
Returns the field goal percentage
105 |
# File 'lib/nba/team_game_log_stat.rb', line 105 attribute :fg_pct, Shale::Type::Float |
#fga ⇒ Integer
Returns the field goals attempted
97 |
# File 'lib/nba/team_game_log_stat.rb', line 97 attribute :fga, Shale::Type::Integer |
#fgm ⇒ Integer
Returns the field goals made
89 |
# File 'lib/nba/team_game_log_stat.rb', line 89 attribute :fgm, Shale::Type::Integer |
#ft_pct ⇒ Float
Returns the free throw percentage
153 |
# File 'lib/nba/team_game_log_stat.rb', line 153 attribute :ft_pct, Shale::Type::Float |
#fta ⇒ Integer
Returns the free throws attempted
145 |
# File 'lib/nba/team_game_log_stat.rb', line 145 attribute :fta, Shale::Type::Integer |
#ftm ⇒ Integer
Returns the free throws made
137 |
# File 'lib/nba/team_game_log_stat.rb', line 137 attribute :ftm, Shale::Type::Integer |
#game_date ⇒ String
Returns the game date
57 |
# File 'lib/nba/team_game_log_stat.rb', line 57 attribute :game_date, Shale::Type::String |
#game_id ⇒ String
Returns the game ID
49 |
# File 'lib/nba/team_game_log_stat.rb', line 49 attribute :game_id, Shale::Type::String |
#matchup ⇒ String
Returns the matchup description
65 |
# File 'lib/nba/team_game_log_stat.rb', line 65 attribute :matchup, Shale::Type::String |
#min ⇒ Integer
Returns the minutes played
81 |
# File 'lib/nba/team_game_log_stat.rb', line 81 attribute :min, Shale::Type::Integer |
#oreb ⇒ Integer
Returns the offensive rebounds
161 |
# File 'lib/nba/team_game_log_stat.rb', line 161 attribute :oreb, Shale::Type::Integer |
#pf ⇒ Integer
Returns the personal fouls
217 |
# File 'lib/nba/team_game_log_stat.rb', line 217 attribute :pf, Shale::Type::Integer |
#plus_minus ⇒ Integer
Returns the plus/minus
233 |
# File 'lib/nba/team_game_log_stat.rb', line 233 attribute :plus_minus, Shale::Type::Integer |
#pts ⇒ Integer
Returns the points scored
225 |
# File 'lib/nba/team_game_log_stat.rb', line 225 attribute :pts, Shale::Type::Integer |
#reb ⇒ Integer
Returns the total rebounds
177 |
# File 'lib/nba/team_game_log_stat.rb', line 177 attribute :reb, Shale::Type::Integer |
#season_year ⇒ String
Returns the season year
17 |
# File 'lib/nba/team_game_log_stat.rb', line 17 attribute :season_year, Shale::Type::String |
#stl ⇒ Integer
Returns the steals
193 |
# File 'lib/nba/team_game_log_stat.rb', line 193 attribute :stl, Shale::Type::Integer |
#team_abbreviation ⇒ String
Returns the team abbreviation
33 |
# File 'lib/nba/team_game_log_stat.rb', line 33 attribute :team_abbreviation, Shale::Type::String |
#team_id ⇒ Integer
Returns the team ID
25 |
# File 'lib/nba/team_game_log_stat.rb', line 25 attribute :team_id, Shale::Type::Integer |
#team_name ⇒ String
Returns the team name
41 |
# File 'lib/nba/team_game_log_stat.rb', line 41 attribute :team_name, Shale::Type::String |
#tov ⇒ Integer
Returns the turnovers
209 |
# File 'lib/nba/team_game_log_stat.rb', line 209 attribute :tov, Shale::Type::Integer |
#wl ⇒ String
Returns the win/loss indicator
73 |
# File 'lib/nba/team_game_log_stat.rb', line 73 attribute :wl, Shale::Type::String |
Instance Method Details
#game ⇒ Game?
Returns the game object for this log entry
261 262 263 |
# File 'lib/nba/team_game_log_stat.rb', line 261 def game Games.find(game_id) end |
#loss? ⇒ Boolean
Returns whether the game was a loss
251 252 253 |
# File 'lib/nba/team_game_log_stat.rb', line 251 def loss? wl.eql?("L") end |
#team ⇒ Team?
Returns the team object for this log entry
271 272 273 |
# File 'lib/nba/team_game_log_stat.rb', line 271 def team Teams.find(team_id) end |
#win? ⇒ Boolean
Returns whether the game was a win
241 242 243 |
# File 'lib/nba/team_game_log_stat.rb', line 241 def win? wl.eql?("W") end |