Package com.xebialabs.xlrelease.domain
Class Dependency
java.lang.Object
com.xebialabs.deployit.plugin.api.udm.base.BaseConfigurationItem
com.xebialabs.xlrelease.domain.Dependency
- All Implemented Interfaces:
ConfigurationItem
,CiWithInternalMetadata
,Serializable
,Comparable<BaseConfigurationItem>
@Metadata(description="A dependency to another release, phase or task in a Gate task.",
versioned=false)
public class Dependency
extends BaseConfigurationItem
implements CiWithInternalMetadata
Dependency is a link from a gate task to a plan item (release, phase or task) on which the gate depends.
There are several possible states of a dependency:
-
Variable dependency. In this case the
targetId
contains a variable expression like ${varPhaseId}, andtarget
is null. -
Dependency with string target. In this case the
targetId
contains a plan item ID, andtarget
is null.-
It is possible that
targetId
was emptied by a public API call or by deleting a variable. Then such a dependency does not contain neithertarget
nortargetId
and will cause a Gate to fail.
-
It is possible that
-
Normal dependency. In this case the
target
field points to the plan item on which thegateTask
depends. -
Archived dependency. A dependency becomes "archived" when the target plan item was deleted, for example when
archiving old completed releases. In this case the
target
isnull
, and the information about archived plan item is stored in fieldsarchivedTargetId
,archivedTargetTitle
andarchivedAsResolved
. The latter shows if the plan item wasCOMPLETED
orABORTED
.
- See Also:
-
Field Summary
FieldsFields inherited from class com.xebialabs.deployit.plugin.api.udm.base.BaseConfigurationItem
id, syntheticProperties, type
Fields inherited from interface com.xebialabs.deployit.plugin.api.udm.ConfigurationItem
SYNTHETIC_PROPERTIES_FIELD, TYPE_FIELD
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
archive()
static String
createArchivedTargetTitle
(PlanItem planItem) <T extends PlanItem>
Tboolean
boolean
boolean
boolean
boolean
boolean
boolean
isDone()
void
setGateTask
(GateTask gateTask) void
void
setTargetId
(String targetId) Methods inherited from class com.xebialabs.deployit.plugin.api.udm.base.BaseConfigurationItem
compareTo, equals, get$ciAttributes, get$directoryReference, get$externalProperties, get$internalId, get$referenceId, get$securedCi, get$securedDirectoryReference, get$token, get$validationMessages, getId, getName, getProperty, getPropertyDescriptor, getType, hashCode, hasProperty, set$ciAttributes, set$directoryReference, set$externalProperties, set$internalId, set$referenceId, set$securedCi, set$securedDirectoryReference, set$token, set$validationMessages, setId, setProperty, setType, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.xebialabs.deployit.plugin.api.udm.ConfigurationItem
get$directoryReference, get$internalId, get$referenceId, get$securedCi, get$securedDirectoryReference, get$validationMessages, getId, getName, getProperty, getType, hasProperty, setId, setProperty
-
Field Details
-
TYPE_DEPENDENCY
-
PROPERTY_TARGET
- See Also:
-
-
Constructor Details
-
Dependency
public Dependency()
-
-
Method Details
-
getGateTask
-
setGateTask
-
getTarget
-
setTarget
-
getTargetId
-
setTargetId
-
getArchivedTargetId
-
getArchivedTargetTitle
-
isArchived
public boolean isArchived() -
isDone
public boolean isDone() -
isAborted
public boolean isAborted() -
getTargetDisplayPath
-
getTargetTitle
-
archive
public void archive() -
isArchivedAsResolved
public boolean isArchivedAsResolved() -
createArchivedTargetTitle
-
hasResolvedTarget
public boolean hasResolvedTarget() -
hasVariableTarget
public boolean hasVariableTarget() -
hasValidArchiveTargetId
public boolean hasValidArchiveTargetId() -
get$metadata
- Specified by:
get$metadata
in interfaceCiWithInternalMetadata
-