@PublicAPI @Beta public enum SimpleErrorHandling extends Enum<SimpleErrorHandling>
Please note that this enum is marked with Beta
annotation, so it can be subject of incompatible changes
or removal in later releases.
Enum Constant and Description |
---|
FAIL
Fail in case of an input related error.
|
LOG
Note and log error but try to continue.
|
SILENT
Continue in case of error.
|
Modifier and Type | Method and Description |
---|---|
abstract Consumer<Exception> |
getSuitableErrorHandler()
Get a default error handler.
|
static SimpleErrorHandling |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SimpleErrorHandling[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SimpleErrorHandling FAIL
IllegalStateException
with the reported Exception
as its cause.public static final SimpleErrorHandling LOG
Throwable.getMessage()
to System.err
.public static final SimpleErrorHandling SILENT
Exception
is reported.public static SimpleErrorHandling[] values()
for (SimpleErrorHandling c : SimpleErrorHandling.values()) System.out.println(c);
public static SimpleErrorHandling valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null