maybeMap<R extends Object?> method
R
maybeMap<R extends Object?>({
- R doNothing(
- EditFormUIActionDoNothing doNothing
- required R orElse(
- EditFormUIAction editFormUIAction
Implementation
R maybeMap<R extends Object?>({
R Function(EditFormUIActionDoNothing doNothing)? doNothing,
required R Function(EditFormUIAction editFormUIAction) orElse,
}) {
final editFormUIAction = this;
if (editFormUIAction is EditFormUIActionDoNothing) {
return doNothing != null
? doNothing(editFormUIAction)
: orElse(editFormUIAction);
} else {
throw AssertionError();
}
}