fold<C> method
C
fold<C>(
- C onLeft(
- L l
- C onRight(
- R r
Execute onLeft when value is Left, otherwise execute onRight.
Same as match.
Implementation
C fold<C>(C Function(L l) onLeft, C Function(R r) onRight) =>
match<C>(onLeft, onRight);