Class: Basketball::Draft::Assessment

Inherits:
Object
  • Object
show all
Defined in:
lib/basketball/draft/assessment.rb

Overview

An assessment is given to a front office when it needs the front office to make a pick. This is essentially just a data-transfer object to get information to a front office to make a pick.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(drafted_players:, pick:, round_pick:, round:, undrafted_players:) ⇒ Assessment

Returns a new instance of Assessment.



14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'lib/basketball/draft/assessment.rb', line 14

def initialize(
  drafted_players:,
  pick:,
  round_pick:,
  round:,
  undrafted_players:
)
  @drafted_players   = drafted_players
  @pick              = pick
  @round             = round
  @round_pick        = round_pick
  @undrafted_players = undrafted_players

  freeze
end

Instance Attribute Details

#drafted_playersObject (readonly)

Returns the value of attribute drafted_players.



8
9
10
# File 'lib/basketball/draft/assessment.rb', line 8

def drafted_players
  @drafted_players
end

#pickObject (readonly)

Returns the value of attribute pick.



8
9
10
# File 'lib/basketball/draft/assessment.rb', line 8

def pick
  @pick
end

#roundObject (readonly)

Returns the value of attribute round.



8
9
10
# File 'lib/basketball/draft/assessment.rb', line 8

def round
  @round
end

#round_pickObject (readonly)

Returns the value of attribute round_pick.



8
9
10
# File 'lib/basketball/draft/assessment.rb', line 8

def round_pick
  @round_pick
end

#undrafted_playersObject (readonly)

Returns the value of attribute undrafted_players.



8
9
10
# File 'lib/basketball/draft/assessment.rb', line 8

def undrafted_players
  @undrafted_players
end