@Internal public class TaskActionExecutorImpl extends Object implements TaskActionExecutor
Constructor and Description |
---|
TaskActionExecutorImpl(com.atlassian.plugin.PluginAccessor pluginAccessor) |
Modifier and Type | Method and Description |
---|---|
TaskResult |
executePostTaskActions(InternalTaskType task,
TaskResult taskResult,
Collection<PrePostTaskActions> taskActions)
Run post-task execution actions.
|
Collection<PrePostTaskActions> |
executePreTaskActions(InternalTaskType task,
CommonTaskContext taskContext)
Run pre-task execution actions.
|
protected <D extends PrePostTaskActionsDescriptor,T extends InternalTaskType> |
getTaskActionsFor(Class<D> descriptorClass,
T task)
Find all module descriptors of
descriptorClass type, next reduce a list to those which
are intended to be used with tasks of task type (descriptor.getTaskClass()). |
public TaskActionExecutorImpl(com.atlassian.plugin.PluginAccessor pluginAccessor)
protected <D extends PrePostTaskActionsDescriptor,T extends InternalTaskType> Collection<PrePostTaskActions> getTaskActionsFor(Class<D> descriptorClass, T task)
descriptorClass
type, next reduce a list to those which
are intended to be used with tasks of task
type (descriptor.getTaskClass()). Extract
actions from module descriptors.D
- module descriptors for our PrePostTaskActionsT
- type of a current task, in our case CommonTaskType / TaskType / DeploymentTaskTypedescriptorClass
- type of a plugin points we're looking fortask
- current task being executedpublic Collection<PrePostTaskActions> executePreTaskActions(@NotNull InternalTaskType task, @NotNull CommonTaskContext taskContext)
TaskActionExecutor
executePreTaskActions
in interface TaskActionExecutor
task
- a current task which will be executed after these pre-task actionstaskContext
- a current task contextpublic TaskResult executePostTaskActions(@NotNull InternalTaskType task, @Nullable TaskResult taskResult, @NotNull Collection<PrePostTaskActions> taskActions)
TaskActionExecutor
executePostTaskActions
in interface TaskActionExecutor
task
- a current task which was be executed before these post-task actionstaskResult
- a result returned by the task; may be null
in case the task terminated abnormallyCopyright © 2020 Atlassian Software Systems Pty Ltd. All rights reserved.