Module: Respanol::Traducir::ClassMethods
- Defined in:
- lib/respanol/traducir.rb
Instance Method Summary collapse
Instance Method Details
#definicion ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/respanol/traducir.rb', line 4 def definicion nombre = self.name.split('::').last.downcase @definicion ||= Traductor.traducir_y_definicion(nombre) tpl = " | %s" o = ["=> #{@definicion[:translated]}"] o << " *---INGLÉS----------" @definicion[:target_definitions].each do |d| o << tpl % d end o << " *---ESPAÑOL----------" @definicion[:source_definitions].each do |d| o << tpl % d end puts o.join("\n") end |