Package io.jenkins.plugins.util
Klasse AbstractExecution<T>
java.lang.Object
org.jenkinsci.plugins.workflow.steps.StepExecution
org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution<T>
io.jenkins.plugins.util.AbstractExecution<T>
- Typparameter:
T- the type of the return value (useVoidif no return value is available)
- Alle implementierten Schnittstellen:
Serializable
public abstract class AbstractExecution<T>
extends org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution<T>
Base class for step executions. Provides several helper methods to obtain the defined
context
elements.- Autor:
- Ullrich Hafner
- Siehe auch:
-
Konstruktorübersicht
KonstruktorenModifiziererKonstruktorBeschreibungprotectedAbstractExecution(org.jenkinsci.plugins.workflow.steps.StepContext context) Creates a new instance ofAbstractExecution. -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungprotected StageResultHandlerCreates aStageResultHandlerthat sets the overall build result of theRun.protected FilePathReturns Jenkins' build folder.protected Optional<hudson.remoting.VirtualChannel> Returns aVirtualChannelto the agent where this step has been executed.protected CharsetgetCharset(String charset) Returns the default charset for the specified encoding string.protected Run<?, ?> getRun()Returns the associated pipeline run.protected TaskListenerReturns theTaskListenerfor this execution.protected FilePathReturns the workspace for this job.Von Klasse geerbte Methoden org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution
blocksRestart, getStatus, onResume, run, start, stopVon Klasse geerbte Methoden org.jenkinsci.plugins.workflow.steps.StepExecution
applyAll, applyAll, getContext, getStatusBounded
-
Konstruktordetails
-
AbstractExecution
protected AbstractExecution(org.jenkinsci.plugins.workflow.steps.StepContext context) Creates a new instance ofAbstractExecution.- Parameter:
context- the context to use
-
-
Methodendetails
-
getRun
Returns the associated pipeline run.- Gibt zurück:
- the run
- Löst aus:
IOException- if the run could not be resolvedInterruptedException- if the user canceled the run
-
getChannel
protected Optional<hudson.remoting.VirtualChannel> getChannel() throws IOException, InterruptedExceptionReturns aVirtualChannelto the agent where this step has been executed.- Gibt zurück:
- the channel
- Löst aus:
IOException- if the computer could not be resolvedInterruptedException- if the user canceled the run
-
getBuildFolder
Returns Jenkins' build folder.- Gibt zurück:
- the build folder
- Löst aus:
IOException- if the build folder could not be resolvedInterruptedException- if the user canceled the run
-
getWorkspace
Returns the workspace for this job. If the workspace does not yet exist, then the required folders are created.- Gibt zurück:
- the workspace
- Löst aus:
IOException- if the workspace could not be resolvedInterruptedException- if the user canceled the execution
-
getTaskListener
Returns theTaskListenerfor this execution.- Gibt zurück:
- the task listener (or a silent listener if no task listener could be found)
- Löst aus:
InterruptedException- if the user canceled the executionIOException- if the task listener could not be resolved
-
getCharset
Returns the default charset for the specified encoding string. If the default encoding is empty ornull, or if the charset is not valid then the default encoding of the platform is returned.- Parameter:
charset- identifier of the character set- Gibt zurück:
- the default charset for the specified encoding string
-
createStageResultHandler
Creates aStageResultHandlerthat sets the overall build result of theRun.- Gibt zurück:
- a
StageResultHandlerthat sets the overall build result of theRun - Löst aus:
InterruptedException- if the user canceled the executionIOException- if the requiredFlowNodeinstance is not found
-