class Nothing
Public Instance Methods
==(object)
click to toggle source
# File lib/ruby-maybe/nothing.rb, line 22 def ==(object) if object.class == Nothing true else false end end
bind()
click to toggle source
# File lib/ruby-maybe/nothing.rb, line 6 def bind Nothing.new end
get(&block)
click to toggle source
# File lib/ruby-maybe/nothing.rb, line 18 def get(&block) block.call end
map()
click to toggle source
# File lib/ruby-maybe/nothing.rb, line 10 def map Nothing.new end
method_missing(method_name, *args, &block)
click to toggle source
# File lib/ruby-maybe/nothing.rb, line 2 def method_missing(method_name, *args, &block) Nothing.new end
or(&block)
click to toggle source
# File lib/ruby-maybe/nothing.rb, line 14 def or(&block) block.call end