class NumbersAndWords::Wrappers::Integer
Attributes
Public Class Methods
Source
# File lib/numbers_and_words/wrappers/integer.rb, line 8 def initialize(number) @number = number end
Public Instance Methods
Source
# File lib/numbers_and_words/wrappers/integer.rb, line 12 def to_words(options = {}) to_figures_array.to_words options end
Private Instance Methods
Source
# File lib/numbers_and_words/wrappers/integer.rb, line 18 def to_figures_array number.to_s.chars.map(&:to_i).to_figures end