Class: NBA::TeamGameLogEntry
- Inherits:
-
Shale::Mapper
- Object
- Shale::Mapper
- NBA::TeamGameLogEntry
- Defined in:
- lib/nba/team_game_log_entry.rb
Overview
Represents a single team game log entry
Instance Attribute Summary collapse
-
#ast ⇒ Integer
Returns assists.
-
#blk ⇒ Integer
Returns blocks.
-
#dreb ⇒ Integer
Returns defensive rebounds.
-
#fg3_pct ⇒ Float
Returns three-point percentage.
-
#fg3a ⇒ Integer
Returns three-pointers attempted.
-
#fg3m ⇒ Integer
Returns three-pointers made.
-
#fg_pct ⇒ Float
Returns field goal percentage.
-
#fga ⇒ Integer
Returns field goals attempted.
-
#fgm ⇒ Integer
Returns field goals made.
-
#ft_pct ⇒ Float
Returns free throw percentage.
-
#fta ⇒ Integer
Returns free throws attempted.
-
#ftm ⇒ Integer
Returns 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 offensive rebounds.
-
#pf ⇒ Integer
Returns personal fouls.
-
#plus_minus ⇒ Integer
Returns plus/minus.
-
#pts ⇒ Integer
Returns points.
-
#reb ⇒ Integer
Returns total rebounds.
-
#stl ⇒ Integer
Returns steals.
-
#team_id ⇒ Integer
Returns the team ID.
-
#tov ⇒ Integer
Returns turnovers.
-
#wl ⇒ String
Returns the win/loss result.
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 game log.
-
#win? ⇒ Boolean
Returns whether the game was a win.
Instance Attribute Details
#ast ⇒ Integer
Returns assists
156 |
# File 'lib/nba/team_game_log_entry.rb', line 156 attribute :ast, Shale::Type::Integer |
#blk ⇒ Integer
Returns blocks
172 |
# File 'lib/nba/team_game_log_entry.rb', line 172 attribute :blk, Shale::Type::Integer |
#dreb ⇒ Integer
Returns defensive rebounds
140 |
# File 'lib/nba/team_game_log_entry.rb', line 140 attribute :dreb, Shale::Type::Integer |
#fg3_pct ⇒ Float
Returns three-point percentage
100 |
# File 'lib/nba/team_game_log_entry.rb', line 100 attribute :fg3_pct, Shale::Type::Float |
#fg3a ⇒ Integer
Returns three-pointers attempted
92 |
# File 'lib/nba/team_game_log_entry.rb', line 92 attribute :fg3a, Shale::Type::Integer |
#fg3m ⇒ Integer
Returns three-pointers made
84 |
# File 'lib/nba/team_game_log_entry.rb', line 84 attribute :fg3m, Shale::Type::Integer |
#fg_pct ⇒ Float
Returns field goal percentage
76 |
# File 'lib/nba/team_game_log_entry.rb', line 76 attribute :fg_pct, Shale::Type::Float |
#fga ⇒ Integer
Returns field goals attempted
68 |
# File 'lib/nba/team_game_log_entry.rb', line 68 attribute :fga, Shale::Type::Integer |
#fgm ⇒ Integer
Returns field goals made
60 |
# File 'lib/nba/team_game_log_entry.rb', line 60 attribute :fgm, Shale::Type::Integer |
#ft_pct ⇒ Float
Returns free throw percentage
124 |
# File 'lib/nba/team_game_log_entry.rb', line 124 attribute :ft_pct, Shale::Type::Float |
#fta ⇒ Integer
Returns free throws attempted
116 |
# File 'lib/nba/team_game_log_entry.rb', line 116 attribute :fta, Shale::Type::Integer |
#ftm ⇒ Integer
Returns free throws made
108 |
# File 'lib/nba/team_game_log_entry.rb', line 108 attribute :ftm, Shale::Type::Integer |
#game_date ⇒ String
Returns the game date
28 |
# File 'lib/nba/team_game_log_entry.rb', line 28 attribute :game_date, Shale::Type::String |
#game_id ⇒ String
Returns the game ID
20 |
# File 'lib/nba/team_game_log_entry.rb', line 20 attribute :game_id, Shale::Type::String |
#matchup ⇒ String
Returns the matchup description
36 |
# File 'lib/nba/team_game_log_entry.rb', line 36 attribute :matchup, Shale::Type::String |
#min ⇒ Integer
Returns the minutes played
52 |
# File 'lib/nba/team_game_log_entry.rb', line 52 attribute :min, Shale::Type::Integer |
#oreb ⇒ Integer
Returns offensive rebounds
132 |
# File 'lib/nba/team_game_log_entry.rb', line 132 attribute :oreb, Shale::Type::Integer |
#pf ⇒ Integer
Returns personal fouls
188 |
# File 'lib/nba/team_game_log_entry.rb', line 188 attribute :pf, Shale::Type::Integer |
#plus_minus ⇒ Integer
Returns plus/minus
204 |
# File 'lib/nba/team_game_log_entry.rb', line 204 attribute :plus_minus, Shale::Type::Integer |
#pts ⇒ Integer
Returns points
196 |
# File 'lib/nba/team_game_log_entry.rb', line 196 attribute :pts, Shale::Type::Integer |
#reb ⇒ Integer
Returns total rebounds
148 |
# File 'lib/nba/team_game_log_entry.rb', line 148 attribute :reb, Shale::Type::Integer |
#stl ⇒ Integer
Returns steals
164 |
# File 'lib/nba/team_game_log_entry.rb', line 164 attribute :stl, Shale::Type::Integer |
#team_id ⇒ Integer
Returns the team ID
12 |
# File 'lib/nba/team_game_log_entry.rb', line 12 attribute :team_id, Shale::Type::Integer |
#tov ⇒ Integer
Returns turnovers
180 |
# File 'lib/nba/team_game_log_entry.rb', line 180 attribute :tov, Shale::Type::Integer |
#wl ⇒ String
Returns the win/loss result
44 |
# File 'lib/nba/team_game_log_entry.rb', line 44 attribute :wl, Shale::Type::String |
Instance Method Details
#game ⇒ Game?
Returns the game object for this log entry
242 243 244 |
# File 'lib/nba/team_game_log_entry.rb', line 242 def game Games.find(game_id) end |
#loss? ⇒ Boolean
Returns whether the game was a loss
222 223 224 |
# File 'lib/nba/team_game_log_entry.rb', line 222 def loss? wl.eql?("L") end |
#team ⇒ Team?
Returns the team object for this game log
232 233 234 |
# File 'lib/nba/team_game_log_entry.rb', line 232 def team Teams.find(team_id) end |
#win? ⇒ Boolean
Returns whether the game was a win
212 213 214 |
# File 'lib/nba/team_game_log_entry.rb', line 212 def win? wl.eql?("W") end |