Class: PRLS::CLI
- Inherits:
-
Object
- Object
- PRLS::CLI
- Defined in:
- lib/prls/cli.rb
Defined Under Namespace
Classes: BPP, CONCORD, DPS, MTI, PLAYSCRIPTS, PRO, Scraper
Instance Method Summary collapse
Instance Method Details
#call ⇒ Object
3 4 5 6 |
# File 'lib/prls/cli.rb', line 3 def call header end |
#header ⇒ Object
8 9 10 11 12 |
# File 'lib/prls/cli.rb', line 8 def header puts "" puts "PERFORMING RIGHTS LOOKUP SERVICE" puts "--------------------------------" end |
#menu ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 |
# File 'lib/prls/cli.rb', line 28 def input = nil while input != 'exit' pros input = gets.chomp.downcase case input.to_s when '1' puts "" puts "Loading..." puts "" DPS.get_plays DPS.list_plays when '2' puts "" puts "Loading..." puts "" CONCORD.get_plays CONCORD.list_plays when '3' puts "" puts "Loading..." puts "" MTI.get_plays MTI.list_plays when '4' puts "" puts "Loading..." puts "" PLAYSCRIPTS.get_plays PLAYSCRIPTS.list_plays when '5' puts "" puts "Loading..." puts "" BPP.get_plays BPP.list_plays when 'exit' puts 'Exiting...' else puts 'Invalid entry. Please try again.' puts "" end end end |
#pros ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/prls/cli.rb', line 14 def pros puts "" puts "Select a PRO to see their currently featured plays:" puts "" puts "1. Dramatist's Play Service, Inc." puts "2. Concord Theatricals (formerly Samuel French, Ltd.)" puts "3. Music Theatre International" puts "4. Playscripts, Inc." puts "5. Broadway Play Publishing, Inc." puts "" puts "To exit, type 'exit'." puts "" end |