class PgaLeaderboard::CLI

Attributes

tournament[R]

Public Class Methods

new(*args) click to toggle source
Calls superclass method
# File lib/pga_leaderboard/cli.rb, line 10
def initialize(*args)
  super
end

Public Instance Methods

leaderboard() click to toggle source
# File lib/pga_leaderboard/cli.rb, line 15
def leaderboard
  run {
    @tournament = PgaLeaderboard::Tournament.new
    output(tournament)
  }
end

Private Instance Methods

output(array) click to toggle source
# File lib/pga_leaderboard/cli.rb, line 24
def output(array)
  puts
  tournament.heading
  puts "--------------------------------------------".colorize(:red)
  puts
  tournament.body
  puts
end