class Either::Left

Attributes

val[R]

Public Class Methods

new(val) click to toggle source
# File lib/either.rb, line 35
def initialize(val)
  @val = val
end

Public Instance Methods

flat_map(&block) click to toggle source
# File lib/either.rb, line 43
def flat_map(&block)
  self
end
left?() click to toggle source
# File lib/either.rb, line 28
def left?
  true
end
map(&block) click to toggle source
# File lib/either.rb, line 39
def map(&block)
  self
end
right?() click to toggle source
# File lib/either.rb, line 31
def right?
  false
end