fold<Z> method

  1. @override
Z fold<Z>(
  1. Z onLeft(
    1. L l
    ),
  2. Z onRight(
    1. R r
    )
)
override

Applies onLeft if this is a Left or onRight if this is a Right

Implementation

@override
Z fold<Z>(Z Function(L l) onLeft, Z Function(R r) onRight) => onRight(_value);