Package org.springframework.boot
Interface ExitCodeExceptionMapper
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface ExitCodeExceptionMapper
Strategy interface that can be used to provide a mapping between exceptions and exit codes.- Since:
- 1.3.2
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description int
getExitCode(Throwable exception)
Returns the exit code that should be returned from the application.
Method Detail
getExitCode
int getExitCode(Throwable exception)
Returns the exit code that should be returned from the application.- Parameters:
exception
- the exception causing the application to exit- Returns:
- the exit code or
0
.