Class: Float
Instance Method Summary collapse
- #*(other_obj) ⇒ Object
- #**(other_obj) ⇒ Object
- #+(other_obj) ⇒ Object
- #-(other_obj) ⇒ Object
- #/(other_obj) ⇒ Object
- #old_divide ⇒ Object
- #old_min ⇒ Object
- #old_multiply ⇒ Object
- #old_pow ⇒ Object
- #old_sum ⇒ Object
Methods included from HexValuesFromFloat
Instance Method Details
#*(other_obj) ⇒ Object
59 60 61 62 |
# File 'lib/hex_values.rb', line 59 def *(other_obj) return other_obj * self if other_obj.instance_of? Hexadecimal return old_multiply(other_obj) end |
#**(other_obj) ⇒ Object
69 70 71 72 |
# File 'lib/hex_values.rb', line 69 def **(other_obj) return self ** other_obj.to_float if other_obj.instance_of? Hexadecimal return old_pow(other_obj) end |
#+(other_obj) ⇒ Object
49 50 51 52 |
# File 'lib/hex_values.rb', line 49 def +(other_obj) return other_obj + self if other_obj.instance_of? Hexadecimal return old_sum(other_obj) end |
#-(other_obj) ⇒ Object
54 55 56 57 |
# File 'lib/hex_values.rb', line 54 def -(other_obj) return self.to_hex - other_obj if other_obj.instance_of? Hexadecimal return old_min(other_obj) end |
#/(other_obj) ⇒ Object
64 65 66 67 |
# File 'lib/hex_values.rb', line 64 def /(other_obj) return self.to_hex / other_obj if other_obj.instance_of? Hexadecimal return old_divide(other_obj) end |
#old_divide ⇒ Object
46 |
# File 'lib/hex_values.rb', line 46 alias :old_divide :/ |
#old_min ⇒ Object
44 |
# File 'lib/hex_values.rb', line 44 alias :old_min :- |
#old_multiply ⇒ Object
45 |
# File 'lib/hex_values.rb', line 45 alias :old_multiply :* |
#old_pow ⇒ Object
47 |
# File 'lib/hex_values.rb', line 47 alias :old_pow :** |
#old_sum ⇒ Object
43 |
# File 'lib/hex_values.rb', line 43 alias :old_sum :+ |