Package jenkins.cli.listeners
Interface CLIListener
- All Superinterfaces:
ExtensionPoint
- All Known Implementing Classes:
DefaultCLIListener
Allows implementations to listen to
CLICommand.run()
execution events.- Since:
- TODO
-
Nested Class Summary
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
Method Summary
Modifier and TypeMethodDescriptiondefault void
onCompleted
(CLIContext context, int exitCode) Invoked after command execution.default void
onExecution
(CLIContext context) Invoked before command execution.default void
onThrowable
(CLIContext context, Throwable t) Invoked when an exception or error occurs during command execution.
-
Method Details
-
onExecution
Invoked before command execution.- Parameters:
context
- Information about the command being executed.
-
onCompleted
Invoked after command execution.- Parameters:
context
- Information about the command being executed.exitCode
- Exit code returned by the implementation ofCLICommand.run()
.
-
onThrowable
Invoked when an exception or error occurs during command execution.- Parameters:
context
- Information about the command being executed.t
- Any error during the execution of the command.
-