Class: NBA::TeamInfo
- Inherits:
-
Shale::Mapper
- Object
- Shale::Mapper
- NBA::TeamInfo
- Defined in:
- lib/nba/team_info.rb
Overview
Represents team information from the TeamInfoCommon endpoint
Instance Attribute Summary collapse
-
#conf_rank ⇒ Integer?
Returns conference rank.
-
#div_rank ⇒ Integer?
Returns division rank.
-
#l ⇒ Integer?
Returns losses.
-
#max_year ⇒ String?
Returns the maximum year.
-
#min_year ⇒ String?
Returns the minimum year (franchise founding year).
-
#pct ⇒ Float?
Returns win percentage.
-
#season_year ⇒ String?
Returns the season year.
-
#team_abbreviation ⇒ String?
Returns the team abbreviation.
-
#team_city ⇒ String?
Returns the team city.
-
#team_code ⇒ String?
Returns the team code.
-
#team_conference ⇒ String?
Returns the team conference.
-
#team_division ⇒ String?
Returns the team division.
-
#team_id ⇒ Integer?
Returns the team ID.
-
#team_name ⇒ String?
Returns the team name.
-
#team_slug ⇒ String?
Returns the team slug.
-
#w ⇒ Integer?
Returns wins.
Instance Method Summary collapse
-
#team ⇒ Team?
Returns the team associated with this info.
Instance Attribute Details
#conf_rank ⇒ Integer?
Returns conference rank
114 |
# File 'lib/nba/team_info.rb', line 114 attribute :conf_rank, Shale::Type::Integer |
#div_rank ⇒ Integer?
Returns division rank
122 |
# File 'lib/nba/team_info.rb', line 122 attribute :div_rank, Shale::Type::Integer |
#l ⇒ Integer?
Returns losses
98 |
# File 'lib/nba/team_info.rb', line 98 attribute :l, Shale::Type::Integer |
#max_year ⇒ String?
Returns the maximum year
138 |
# File 'lib/nba/team_info.rb', line 138 attribute :max_year, Shale::Type::String |
#min_year ⇒ String?
Returns the minimum year (franchise founding year)
130 |
# File 'lib/nba/team_info.rb', line 130 attribute :min_year, Shale::Type::String |
#pct ⇒ Float?
Returns win percentage
106 |
# File 'lib/nba/team_info.rb', line 106 attribute :pct, Shale::Type::Float |
#season_year ⇒ String?
Returns the season year
26 |
# File 'lib/nba/team_info.rb', line 26 attribute :season_year, Shale::Type::String |
#team_abbreviation ⇒ String?
Returns the team abbreviation
50 |
# File 'lib/nba/team_info.rb', line 50 attribute :team_abbreviation, Shale::Type::String |
#team_city ⇒ String?
Returns the team city
34 |
# File 'lib/nba/team_info.rb', line 34 attribute :team_city, Shale::Type::String |
#team_code ⇒ String?
Returns the team code
74 |
# File 'lib/nba/team_info.rb', line 74 attribute :team_code, Shale::Type::String |
#team_conference ⇒ String?
Returns the team conference
58 |
# File 'lib/nba/team_info.rb', line 58 attribute :team_conference, Shale::Type::String |
#team_division ⇒ String?
Returns the team division
66 |
# File 'lib/nba/team_info.rb', line 66 attribute :team_division, Shale::Type::String |
#team_id ⇒ Integer?
Returns the team ID
18 |
# File 'lib/nba/team_info.rb', line 18 attribute :team_id, Shale::Type::Integer |
#team_name ⇒ String?
Returns the team name
42 |
# File 'lib/nba/team_info.rb', line 42 attribute :team_name, Shale::Type::String |
#team_slug ⇒ String?
Returns the team slug
82 |
# File 'lib/nba/team_info.rb', line 82 attribute :team_slug, Shale::Type::String |
#w ⇒ Integer?
Returns wins
90 |
# File 'lib/nba/team_info.rb', line 90 attribute :w, Shale::Type::Integer |
Instance Method Details
#team ⇒ Team?
Returns the team associated with this info
146 147 148 |
# File 'lib/nba/team_info.rb', line 146 def team Teams.find(team_id) end |