public interface Exceptional
IProblem interface for problems that extend Exception. Since Exception
is a concrete type any class can only extend one exception type. ProblemRuntime is one choice, but we
don't want to force people to extend from this but choose their own super class. For this they can implement this
interface and get the same handling as ProblemRuntime for free. A common use case would be:
public final class OutOfStockException extends BusinessException implements Exceptional
Exception,
IProblem,
ProblemRuntime| Modifier and Type | Method and Description |
|---|---|
default java.lang.Exception |
propagate() |
default <X extends java.lang.Throwable> |
propagateAs(java.lang.Class<X> type) |