@Contract public interface RunLevelListener
Instances of classes implementing this contract can be registered to be informed of events of RunLevelControllers.
Note that RunLevelController implementations may be asynchronous, so RunLevelListeners should be thread safe. Additionally, you are discouraged from performing lengthy operations in the listener since that may impact the performance of the RunLevelController calling the listener on the same thread.
| Modifier and Type | Method and Description |
|---|---|
void |
onCancelled(RunLevelController controller,
int previousProceedTo,
boolean isInterrupt)
Called when an RunLevelController implementation's proceedTo() operation
has been canceled for some reason.
|
void |
onError(RunLevelController controller,
java.lang.Throwable error,
boolean willContinue)
Called when a service throws an exception during lifecycle
orchestration.
|
void |
onProgress(RunLevelController controller)
Called when the RunLevelController advances in some tangible way.
|
void onCancelled(RunLevelController controller, int previousProceedTo, boolean isInterrupt)
controller - the run level controllerpreviousProceedTo - the previousProceedTo service that is being
canceledisInterrupt - set to true if the onCancelled even was as
a result of an explicit interrupt() callvoid onError(RunLevelController controller, java.lang.Throwable error, boolean willContinue)
controller - the run level controllererror - the error that was caughtwillContinue - the flag indicating whether or not the RunLevelController
plans to proceed thru to the planned RunLevel servicevoid onProgress(RunLevelController controller)
controller - the run level controllerCopyright © 2013 Oracle Corporation. All Rights Reserved.