KDL::Value
Constructors
Instance methods
Checks that the underlying value is Bool, and returns its value.
Returns nil otherwise.
Checks that the underlying value is Float (or Int), and returns its value as an Float64.
Raises otherwise.
Checks that the underlying value is Float (or Int), and returns its value as an Float32.
Raises otherwise.
Checks that the underlying value is Float (or Int), and returns its value as an Float32.
Returns nil otherwise.
Checks that the underlying value is Float (or Int), and returns its value as an Float64.
Returns nil otherwise.
Checks that the underlying value is Int, and returns its value as an Int32.
Raises otherwise.
Checks that the underlying value is Int, and returns its value as an Int64.
Raises otherwise.
Checks that the underlying value is Int, and returns its value as an Int64.
Returns nil otherwise.
Checks that the underlying value is Int, and returns its value as an Int32.
Returns nil otherwise.
Checks that the underlying value is String, and returns its value.
Returns nil otherwise.
Appends a String representation of this object which includes its class name, its object address and the values of all instance variables.
class Person
def initialize(@name : String, @age : Int32)
end
end
Person.new("John", 32).inspect # => #<Person:0x10fd31f20 @name="John", @age=32>
Appends a short String representation of this object which includes its class name and its object address.
class Person
def initialize(@name : String, @age : Int32)
end
end
Person.new("John", 32).to_s # => #<Person:0x10a199f20>