Class: YFantasy::PickemTeam::WeekPick
- Inherits:
-
BaseSubresource
- Object
- BaseSubresource
- YFantasy::PickemTeam::WeekPick
- Defined in:
- lib/y_fantasy/resources/pickem_team/week_pick.rb
Overview
Represents a single week of picks for a team in a Yahoo Fantasy NFL Survival Group. There may be multiple picks per week.
Instance Attribute Summary collapse
-
#picks ⇒ Array<Pick>
readonly
The picks made for this week.
-
#picks_completed ⇒ Integer
readonly
The number of picks completed for this week.
-
#week ⇒ Integer
readonly
The week number.
Instance Method Summary collapse
-
#pick_details ⇒ Array<Hash>
Team details for each pick.
Methods inherited from BaseSubresource
dependent?, find, resource_name
Methods included from Subresourceable
Instance Attribute Details
#picks ⇒ Array<Pick> (readonly)
Returns the picks made for this week.
20 |
# File 'lib/y_fantasy/resources/pickem_team/week_pick.rb', line 20 option :picks, type: array_of(Pick) |
#picks_completed ⇒ Integer (readonly)
Returns the number of picks completed for this week.
16 |
# File 'lib/y_fantasy/resources/pickem_team/week_pick.rb', line 16 option :picks_completed, type: Types::Coercible::Integer |
#week ⇒ Integer (readonly)
Returns the week number.
12 |
# File 'lib/y_fantasy/resources/pickem_team/week_pick.rb', line 12 option :week, type: Types::Coercible::Integer |
Instance Method Details
#pick_details ⇒ Array<Hash>
Returns team details for each pick.
23 24 25 |
# File 'lib/y_fantasy/resources/pickem_team/week_pick.rb', line 23 def pick_details picks.compact.map(&:team_details) end |