class ChgkRating::Collections::TournamentTeams

Attributes

tournament[R]

Public Class Methods

new(params = {}) click to toggle source
Calls superclass method ChgkRating::Collections::Base::new
# File lib/chgk_rating/collections/tournament_teams.rb, line 5
def initialize(params = {})
  @tournament = build_model params[:tournament], ChgkRating::Models::Tournament

  super
end

Private Instance Methods

api_path() click to toggle source
# File lib/chgk_rating/collections/tournament_teams.rb, line 17
def api_path
  "tournaments/#{@tournament.id}/list"
end
process(_results, params = {}) click to toggle source
Calls superclass method ChgkRating::Collections::Base#process
# File lib/chgk_rating/collections/tournament_teams.rb, line 13
def process(_results, params = {})
  super { |result| ChgkRating::Models::TournamentTeam.new result, lazy: params[:lazy] }
end