Class: NumbersAndWords::FiguresArray

Inherits:
Array
  • Object
show all
Includes:
ArrayAdditions::Helpers, ArrayAdditions::Validations
Defined in:
lib/numbers_and_words/figures_array.rb

Constant Summary

Constants included from ArrayAdditions::Helpers

ArrayAdditions::Helpers::THOUSAND_CAPACITY

Instance Method Summary collapse

Methods included from ArrayAdditions::Validations

#validate_figure_array!

Methods included from ArrayAdditions::Helpers

#capacity_count, #figures_array_in_capacity, #hundreds, #is_a_thousand_capacity?, #number_for_gender, #number_in_capacity, #ones, #teens, #tens, #tens_with_ones

Methods inherited from Array

#to_figures

Instance Method Details

#reverseObject



11
12
13
# File 'lib/numbers_and_words/figures_array.rb', line 11

def reverse
  super.to_figures
end

#to_words(strategy, options = nil) ⇒ Object



6
7
8
9
# File 'lib/numbers_and_words/figures_array.rb', line 6

def to_words strategy, options = nil
  validate_figure_array!
  strategy.convert self
end