Class: Generator::AskLoop
- Inherits:
-
Utils::AskLoop
- Object
- Utils::AskLoop
- Generator::AskLoop
- Defined in:
- lib/ngi/generator.rb
Overview
Here we just implement the virtual class Utils::AskLoop
Class Method Summary collapse
Class Method Details
.ask(args) ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/ngi/generator.rb', line 28 def self.ask(args) print "\n#{args[:prompt]}" answer = AcceptInput.str(:downcased) loop do break if args[:check] == answer puts 'Exited!' exit end answer end |