Module: AllYourBase::Are::BelongToUs::To

Defined in:
lib/all_your_base/are/belong_to_us.rb

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(sym, *args, &block) ⇒ Object



17
18
19
20
21
22
23
# File 'lib/all_your_base/are/belong_to_us.rb', line 17

def method_missing(sym, *args, &block)
  if sym.to_s.match(/\Ato_base_([0-9]+)\Z/)
    AllYourBase::Are.convert_from_base_10(self.to_i, {:radix => $1.to_i})
  else
    super # NoMethodError
  end
end