This is a Ruby tree! It shows every object from the Ruby Programming Language in a tree format.

to_int

        # Numeric.to_int

(from ruby core)
---
    to_int -> integer

---

Returns `self` as an integer; converts using method `to_i` in the
derived class.

Of the Core and Standard Library classes, only Rational and Complex use
this implementation.

Examples:

    Rational(1, 2).to_int # => 0
    Rational(2, 1).to_int # => 2
    Complex(2, 0).to_int  # => 2
    Complex(2, 1)         # Raises RangeError (non-zero imaginary part)



      

This is MURDOC! A Ruby documentation browser inspired by Smalltalk-80. It allows you to learn about Ruby by browsing through its class hierarchies, and see any of its methods.