getOrThrow method
T
getOrThrow()
Forces extraction of the underlying value or transforms a domain failure into a terminal runtime state exception.
Implementation
T getOrThrow() => switch (this) {
_SuccessResult<T>(success: final success) => success.value,
_FailureResult<T>(failure: final failure) =>
throw Exception(failure.detailedMessage),
};