class SleeperRb::Resources::Draft
Represents a draft for a given user.
Attributes
created[R]
creators[R]
draft_id[R]
draft_order[R]
last_message_id[R]
last_message_time[R]
last_picked[R]
league[R]
league_id[R]
season[R]
season_type[R]
sport[R]
start_time[R]
status[R]
type[R]
Public Instance Methods
auction?()
click to toggle source
# File lib/sleeper_rb/resources/draft.rb, line 101 def auction? type == "auction" end
draft_picks()
click to toggle source
All picks in the Draft
.
@return [SleeperRb::Resources::Draft::Pick
]
# File lib/sleeper_rb/resources/draft.rb, line 97 cached_association :draft_picks do retrieve_picks! end
metadata()
click to toggle source
Metadata
for the draft.
@return [SleeperRb::Resources::Draft::Metadata
]
# File lib/sleeper_rb/resources/draft.rb, line 73 cached_attr :type, :status, :start_time, :sport, :season_type, :season, :league_id, :last_picked, :league, :last_message_time, :last_message_id, :draft_order, :draft_id, :creators, :created, :slot_to_roster_id, settings: ->(hash) { Settings.new(hash) }, metadata: ->(hash) { Metadata.new(hash) }
settings()
click to toggle source
Settings
for the draft.
@return [SleeperRb::Resources::Draft::Settings
]
# File lib/sleeper_rb/resources/draft.rb, line 62
snake?()
click to toggle source
# File lib/sleeper_rb/resources/draft.rb, line 105 def snake? type == "snake" end
traded_picks()
click to toggle source
All picks in the Draft
that were traded.
@return [SleeperRb::Resources::TradedPickArray
]
# File lib/sleeper_rb/resources/draft.rb, line 88 cached_association :traded_picks do retrieve_traded_picks! end