class Rumonade::Some
Represents an Option
containing a value
Public Class Methods
new(value)
click to toggle source
# File lib/rumonade/option.rb, line 88 def initialize(value) @value = value end
Public Instance Methods
==(other)
click to toggle source
# File lib/rumonade/option.rb, line 99 def ==(other) other.is_a?(Some) && other.value == value end
empty?()
click to toggle source
@return (see Option#empty?
)
# File lib/rumonade/option.rb, line 95 def empty? false end
to_s()
click to toggle source
# File lib/rumonade/option.rb, line 103 def to_s "Some(#{value.nil? ? 'nil' : value.to_s})" end