Class: NBA::Standing
- Inherits:
-
Shale::Mapper
- Object
- Shale::Mapper
- NBA::Standing
- Defined in:
- lib/nba/standing.rb
Overview
Represents a team’s standing in the league
Instance Attribute Summary collapse
-
#conference ⇒ String
Returns the conference.
-
#conference_rank ⇒ Integer
Returns the conference rank.
-
#division ⇒ String
Returns the division.
-
#home_record ⇒ String
Returns the home record.
-
#losses ⇒ Integer
Returns the number of losses.
-
#road_record ⇒ String
Returns the road record.
-
#streak ⇒ String
Returns the current streak.
-
#team_id ⇒ Integer
Returns the team ID.
-
#team_name ⇒ String
Returns the team name.
-
#win_pct ⇒ Float
Returns the win percentage.
-
#wins ⇒ Integer
Returns the number of wins.
Instance Method Summary collapse
-
#team ⇒ Team?
Returns the team object for this standing.
Instance Attribute Details
#conference ⇒ String
Returns the conference
32 |
# File 'lib/nba/standing.rb', line 32 attribute :conference, Shale::Type::String |
#conference_rank ⇒ Integer
Returns the conference rank
72 |
# File 'lib/nba/standing.rb', line 72 attribute :conference_rank, Shale::Type::Integer |
#division ⇒ String
Returns the division
40 |
# File 'lib/nba/standing.rb', line 40 attribute :division, Shale::Type::String |
#home_record ⇒ String
Returns the home record
80 |
# File 'lib/nba/standing.rb', line 80 attribute :home_record, Shale::Type::String |
#losses ⇒ Integer
Returns the number of losses
56 |
# File 'lib/nba/standing.rb', line 56 attribute :losses, Shale::Type::Integer |
#road_record ⇒ String
Returns the road record
88 |
# File 'lib/nba/standing.rb', line 88 attribute :road_record, Shale::Type::String |
#streak ⇒ String
Returns the current streak
96 |
# File 'lib/nba/standing.rb', line 96 attribute :streak, Shale::Type::String |
#team_id ⇒ Integer
Returns the team ID
16 |
# File 'lib/nba/standing.rb', line 16 attribute :team_id, Shale::Type::Integer |
#team_name ⇒ String
Returns the team name
24 |
# File 'lib/nba/standing.rb', line 24 attribute :team_name, Shale::Type::String |
#win_pct ⇒ Float
Returns the win percentage
64 |
# File 'lib/nba/standing.rb', line 64 attribute :win_pct, Shale::Type::Float |
#wins ⇒ Integer
Returns the number of wins
48 |
# File 'lib/nba/standing.rb', line 48 attribute :wins, Shale::Type::Integer |
Instance Method Details
#team ⇒ Team?
Returns the team object for this standing
105 106 107 |
# File 'lib/nba/standing.rb', line 105 def team Teams.find(team_id) end |