Class: DictCache::Dict
- Inherits:
-
Object
- Object
- DictCache::Dict
- Defined in:
- lib/dict_cache/dict.rb
Class Method Summary collapse
Class Method Details
.translate(word) ⇒ Object
5 6 7 8 9 10 11 12 |
# File 'lib/dict_cache/dict.rb', line 5 def self.translate(word) Cache.with_cache do BingDictionary::Base.translate(word) end rescue StandardError error 'Translate Error: check your word is valid.' exit 1 end |