Class: NumbersAndWords::FiguresArray
Constant Summary
ArrayExtensions::Helpers::FIGURES_IN_CAPACITY, ArrayExtensions::Helpers::MICRO_CAPACITY_SHIFT, ArrayExtensions::Helpers::ONES_SHIFT, ArrayExtensions::Helpers::THOUSAND_CAPACITY
Instance Method Summary
collapse
#capacity_count, #capacity_length, #figures_array_under_capacity, #fraction_capacity, #fraction_capacity_count, #fraction_sub_capacity, #hundreds, #number_in_capacity, #number_under_capacity, #ones, #only_ones, #opaque?, #ordinal_capacity, #ordinal_index, #round_hundred?, #sub_capacity, #teens, #tens, #tens_with_ones
Methods inherited from Array
#to_figures
Instance Method Details
17
18
19
|
# File 'lib/numbers_and_words/helper_classes/figures_array.rb', line 17
def figures_array_in_capacity(capacity)
super.to_figures
end
|
#local_language ⇒ Object
21
22
23
|
# File 'lib/numbers_and_words/helper_classes/figures_array.rb', line 21
def local_language(&)
::I18n.with_locale(I18n.local_language, &)
end
|
#reverse ⇒ Object
13
14
15
|
# File 'lib/numbers_and_words/helper_classes/figures_array.rb', line 13
def reverse
super.to_figures
end
|
#to_words(options = {}) ⇒ Object
9
10
11
|
# File 'lib/numbers_and_words/helper_classes/figures_array.rb', line 9
def to_words(options = {})
local_language { Strategies.figures_converter.new(self, options).run }
end
|