Package com.atlassian.bamboo.process
Class ProcessContextImpl
java.lang.Object
com.atlassian.bamboo.process.ProcessContextImpl
- All Implemented Interfaces:
ProcessContext
-
Method Summary
Modifier and TypeMethodDescriptiondecorateProcessCommand(@NotNull List<String> command) Modifies given command by executing command decorators available in the current context.@NotNull BuildKey@NotNull BuildLogger@NotNull CommonContext@NotNull StringgetPaths()@NotNull ResultKey@Nullable CommonTaskContext@NotNull StringlongReturns and id of the current task.@NotNull String@NotNull VariableContextbooleanControls the amount of logging during the execution.
-
Method Details
-
getBuildLogger
- Specified by:
getBuildLoggerin interfaceProcessContext- Returns:
- a build logger for current executable.
-
getResultKey
- Specified by:
getResultKeyin interfaceProcessContext- Returns:
- result key of current execution
-
getJobDisplayName
- Specified by:
getJobDisplayNamein interfaceProcessContext- Returns:
- display name of job or environment being executed
-
getTaskDescription
- Specified by:
getTaskDescriptionin interfaceProcessContext- Returns:
- current task description or empty string if none
-
getVariableContext
- Specified by:
getVariableContextin interfaceProcessContext- Returns:
- variable context of current execution
-
getTaskId
public long getTaskId()Description copied from interface:ProcessContextReturns and id of the current task. If not a scope of a task returns a unique number that will not clash with id of any task.- Specified by:
getTaskIdin interfaceProcessContext
-
getTaskPluginKey
- Specified by:
getTaskPluginKeyin interfaceProcessContext- Returns:
- plugin key of current task or an empty string if none
-
getCommonContext
- Specified by:
getCommonContextin interfaceProcessContext- Returns:
- execution context of current job/environment
-
getTaskContext
- Specified by:
getTaskContextin interfaceProcessContext- Returns:
- current task context or null if not in task context
-
getEnvironment
- Specified by:
getEnvironmentin interfaceProcessContext- Returns:
- environment variables used for process execution
-
getPaths
- Specified by:
getPathsin interfaceProcessContext- Returns:
- content of "PATH" variable used for process execution
-
getBuildKey
- Specified by:
getBuildKeyin interfaceProcessContext- Returns:
- unique key of the current context
-
decorateProcessCommand
@NotNull public @NotNull List<String> decorateProcessCommand(@NotNull @NotNull List<String> command) Description copied from interface:ProcessContextModifies given command by executing command decorators available in the current context.- Specified by:
decorateProcessCommandin interfaceProcessContext- Parameters:
command-- Returns:
-
isVerboseLoggingOn
public boolean isVerboseLoggingOn()Description copied from interface:ProcessContextControls the amount of logging during the execution. Some of the logging is only output in verbose mode.- Specified by:
isVerboseLoggingOnin interfaceProcessContext- Returns:
- true if verbose logging is enabled.
-