Class SpringApplication.AbandonedRunException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.springframework.boot.SpringApplication.AbandonedRunException
- All Implemented Interfaces:
Serializable
- Enclosing class:
SpringApplication
Exception that can be thrown to silently exit a running
SpringApplication
without handling run failures.- Since:
- 3.0.0
- Author:
- Phillip Webb, Dave Syer, Andy Wilkinson, Christian Dupuis, Stephane Nicoll, Jeremy Rickard, Craig Burke, Michael Simons, Madhura Bhave, Brian Clozel, Ethan Rubinson, Chris Bono, Moritz Halbritter, Tadaya Tsuyukubo, Lasse Wulff, Yanming Zhou
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a newSpringApplication.AbandonedRunException
instance.AbandonedRunException
(ConfigurableApplicationContext applicationContext) Create a newSpringApplication.AbandonedRunException
instance with the given application context. -
Method Summary
Modifier and TypeMethodDescriptionReturn the application context that was available when the run was abandoned ornull
if no context was available.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
AbandonedRunException
public AbandonedRunException()Create a newSpringApplication.AbandonedRunException
instance. -
AbandonedRunException
Create a newSpringApplication.AbandonedRunException
instance with the given application context.- Parameters:
applicationContext
- the application context that was available when the run was abandoned
-
-
Method Details
-
getApplicationContext
Return the application context that was available when the run was abandoned ornull
if no context was available.- Returns:
- the application context
-