Package com.atlassian.bamboo.plan.task
Class DecoratedTaskDefinitionImpl<T extends TaskContainer>
java.lang.Object
com.atlassian.bamboo.task.TaskDefinitionImpl
com.atlassian.bamboo.plan.task.DecoratedTaskDefinitionImpl<T>
- All Implemented Interfaces:
EntityWithOid
,ImmutableEntityWithOid
,PluginKeyProvider
,DecoratedTaskDefinition<T>
,TaskDefinition
,TaskIdentifier
,Serializable
public class DecoratedTaskDefinitionImpl<T extends TaskContainer>
extends TaskDefinitionImpl
implements DecoratedTaskDefinition<T>
Decoration of task used when displaying on the UI.
- See Also:
-
Field Summary
Fields inherited from interface com.atlassian.bamboo.task.TaskDefinition
DISABLED, ENABLED
-
Constructor Summary
ConstructorDescriptionDecoratedTaskDefinitionImpl
(@NotNull TaskDefinition taskDefinition, @Nullable TaskModuleDescriptor taskModuleDescriptor, T taskContainer) -
Method Summary
Modifier and TypeMethodDescription@NotNull com.opensymphony.webwork.dispatcher.json.JSONObject
Retrieve a JSON representation of this task definition.@NotNull String
getName()
Retrieve the name of this task.Retrieve the entity for which this task belongs.boolean
isValid()
Validate this Task Definition by checking whether it is linked to a taskModuleDescriptor.Methods inherited from class com.atlassian.bamboo.task.TaskDefinitionImpl
compareTo, equals, getConditions, getConfiguration, getId, getOid, getPluginKey, getRootDirectorySelector, getUserDescription, hashCode, isEnabled, isFinalising, setConditions, setConfiguration, setEnabled, setFinalising, setOid, setRootDirectorySelector, setUserDescription, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.atlassian.bamboo.core.EntityWithOid
setOid
Methods inherited from interface com.atlassian.bamboo.core.ImmutableEntityWithOid
getOid
Methods inherited from interface com.atlassian.bamboo.task.TaskDefinition
getConditions, getConfiguration, getEntityType, getRootDirectorySelector, setConditions, setConfiguration, setEnabled, setFinalising, setRootDirectorySelector, setUserDescription
Methods inherited from interface com.atlassian.bamboo.task.TaskIdentifier
getId, getPluginKey, getUserDescription, isEnabled, isFinalising
-
Constructor Details
-
DecoratedTaskDefinitionImpl
public DecoratedTaskDefinitionImpl(@NotNull @NotNull TaskDefinition taskDefinition, @Nullable @Nullable TaskModuleDescriptor taskModuleDescriptor, @NotNull T taskContainer)
-
-
Method Details
-
isValid
public boolean isValid()Description copied from interface:DecoratedTaskDefinition
Validate this Task Definition by checking whether it is linked to a taskModuleDescriptor.- Specified by:
isValid
in interfaceDecoratedTaskDefinition<T extends TaskContainer>
- Returns:
- whether this DecoratedTaskDefinition is valid.
-
getName
Description copied from interface:DecoratedTaskDefinition
Retrieve the name of this task.- Specified by:
getName
in interfaceDecoratedTaskDefinition<T extends TaskContainer>
- Returns:
- the name of this task. If the name is not defined in the TaskModuleDescriptor, the plugin key will be used.
-
getTaskContainer
Description copied from interface:DecoratedTaskDefinition
Retrieve the entity for which this task belongs.- Specified by:
getTaskContainer
in interfaceDecoratedTaskDefinition<T extends TaskContainer>
- Returns:
- the entity that contains this task definition.
-
getJsonObject
@NotNull public @NotNull com.opensymphony.webwork.dispatcher.json.JSONObject getJsonObject() throws com.opensymphony.webwork.dispatcher.json.JSONExceptionDescription copied from interface:DecoratedTaskDefinition
Retrieve a JSON representation of this task definition.- Specified by:
getJsonObject
in interfaceDecoratedTaskDefinition<T extends TaskContainer>
- Returns:
- a JSON representation of this task definition.
- Throws:
com.opensymphony.webwork.dispatcher.json.JSONException
-