Module: LearnJapanese
- Defined in:
- lib/learn-japanese.rb,
lib/learn-japanese/version.rb
Constant Summary collapse
- VERSION =
'0.9.1'
- NAME =
'learn-japanese'
- HOMEPAGE =
'https://github.com/dvarrui/learn-japanese'
Class Method Summary collapse
- .choose_answer(level) ⇒ Object
- .romaji ⇒ Object
- .short_answer(level) ⇒ Object
- .show_help ⇒ Object
- .show_version ⇒ Object
- .sound ⇒ Object
Class Method Details
.choose_answer(level) ⇒ Object
19 20 21 22 |
# File 'lib/learn-japanese.rb', line 19 def self.choose_answer(level) show_help unless level > 0 ChooseAnswerGame.new(level).run end |
.romaji ⇒ Object
24 25 26 |
# File 'lib/learn-japanese.rb', line 24 def self.romaji RomajiGame.new.run end |
.short_answer(level) ⇒ Object
28 29 30 31 |
# File 'lib/learn-japanese.rb', line 28 def self.short_answer(level) show_help unless level > 0 ShortAnswerGame.new(level).run end |
.show_help ⇒ Object
14 15 16 17 |
# File 'lib/learn-japanese.rb', line 14 def self.show_help puts "Usage: learn-japanese --help" exit 0 end |
.show_version ⇒ Object
10 11 12 |
# File 'lib/learn-japanese.rb', line 10 def self.show_version puts "#{LearnJapanese::NAME} (version #{LearnJapanese::VERSION})" end |