Module: Fear::EitherApi

Included in:
Fear
Defined in:
lib/fear/either_api.rb

Instance Method Summary collapse

Instance Method Details

#left(value) ⇒ Fear::Left

Examples:

Fear.left(42) #=> #<Fear::Left value=42>

10
11
12
# File 'lib/fear/either_api.rb', line 10

def left(value)
  Fear::Left.new(value)
end

#right(value) ⇒ Fear::Right

Examples:

Fear.right(42) #=> #<Fear::Right value=42>

19
20
21
# File 'lib/fear/either_api.rb', line 19

def right(value)
  Fear::Right.new(value)
end