Package com.xebialabs.xlrelease.domain

## Class Release

- java.lang.Object
- - com.xebialabs.deployit.plugin.api.udm.base.BaseConfigurationItem
  - - com.xebialabs.xlrelease.domain.PlanItem
    - - com.xebialabs.xlrelease.domain.Release

- All Implemented Interfaces:
    `ConfigurationItem`, `com.xebialabs.deployit.repository.core.Securable`, `CiWithInternalMetadata`, `CiWithUid`, `VariableContainer`, `VisitableItem`, `java.io.Serializable`, `java.lang.Comparable<BaseConfigurationItem>`

      @Metadata(description="A release or template.",
                root=APPLICATIONS,
                versioned=false)
      public class Release
      extends PlanItem
      implements com.xebialabs.deployit.repository.core.Securable, CiWithInternalMetadata, VariableContainer, CiWithUid

  See Also:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected boolean` | `abortOnFailure` |
    `protected boolean` | `allowConcurrentReleasesFromTrigger` |
    `protected boolean` | `allowPasswordsInAllFields` |
    `protected boolean` | `archiveRelease` |
    `protected java.lang.String` | `author` |
    `protected int` | `automatedResumeCount` |
    `protected boolean` | `autoStart` |
    `protected java.lang.String` | `calendarLinkToken` |
    `protected boolean` | `calendarPublished` |
    `protected java.util.Set<java.lang.String>` | `categories` |
    `protected boolean` | `createdFromTrigger` |
    `static java.lang.String` | `DEFAULT_TARGET_FOLDER_ID_PROPERTY_NAME` |
    `protected boolean` | `disableNotifications` |
    `protected java.util.List<ReleaseExtension>` | `extensions` |
    `protected ReleaseKind` | `kind` |
    `protected TemplateLogo` | `logo` |
    `protected int` | `maxAutomatedResumes` |
    `protected java.lang.String` | `originTemplateId` |
    `protected java.util.List<Phase>` | `phases` |
    `protected java.util.Date` | `queryableEndDate` |
    `protected java.util.Date` | `queryableStartDate` |
    `protected FlagStatus` | `realFlagStatus` |
    `protected java.util.List<ReleaseTrigger>` | `releaseTriggers` | Deprecated.
    `protected RiskProfile` | `riskProfile` |
    `static java.lang.String` | `SCRIPT_USER_PASSWORD_VARIABLE_MAPPING_KEY` |
    `protected java.lang.String` | `scriptUsername` |
    `protected java.lang.String` | `scriptUserPassword` |
    `protected java.lang.String` | `startedFromTaskId` |
    `protected ReleaseStatus` | `status` |
    `protected java.util.List<java.lang.String>` | `tags` |
    `protected java.util.List<Team>` | `teams` | The Digital.ai Release teams are transient CIs and are kept for backwards-compatibility.
    `protected boolean` | `tutorial` |
    `protected java.util.List<Variable>` | `variables` |

    - ### Fields inherited from class com.xebialabs.xlrelease.domain.PlanItem

      `BY_TITLE, description, dueDate, endDate, flagComment, flagStatus, overdueNotified, owner, plannedDuration, scheduledStartDate, startDate, title`

    - ### Fields 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`

    - ### Fields inherited from interface com.xebialabs.deployit.repository.core.Securable

      `SECURITY_PERMISSIONS_PROPERTY`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `Release()` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `Changes` | `abort​(java.lang.String abortComment)` |
    `Changes` | `abortAsPartOfBulkOperation​(java.lang.String abortComment)` |
    `void` | `accept​(ReleaseVisitor visitor)` |
    `void` | `addBelow​(java.lang.String phaseId, Phase addedPhase)` |
    `void` | `addPhase​(Phase phase)` |
    `void` | `addPhase​(Phase phase, int position)` |
    `void` | `addTeam​(Team team)` |
    `Variable` | `addVariable​(Variable variable)` |
    `void` | `addVariables​(java.util.List<Variable> newVariables)` |
    `boolean` | `canAutomaticallyStartReleaseNow()` |
    `boolean` | `canScheduleReleaseStart()` |
    `void` | `checkDatesValidity()` |
    `void` | `checkDatesValidityForRelease()` |
    `void` | `checkDatesValidityForTemplate()` |
    `void` | `checkVariableCanBeAdded​(Variable variable)` |
    `void` | `clearComments()` |
    `java.util.Set<VariableReference>` | `collectVariableReferences()` |
    `java.util.Set<VariableReference>` | `collectVariableReferences​(VisitableItem updated)` |
    `void` | `deleteAttachment​(java.lang.String attachmentId)` |
    `void` | `deletePhase​(Phase phase)` |
    `void` | `deleteReleaseTriggerById​(java.lang.String triggerId)` | Deprecated.
    `void` | `deleteTask​(Task task)` |
    `void` | `deleteTeam​(java.lang.String teamId)` |
    `Changes` | `failTask​(java.lang.String taskId, java.lang.String failReason)` |
    `Changes` | `failTask​(java.lang.String taskId, java.lang.String failReason, boolean fromAbort)` |
    `Changes` | `failTask​(java.lang.String taskId, java.lang.String failReason, User user, boolean fromAbort)` |
    `java.util.List<Phase>` | `filterPhasesContainingInTitle​(java.util.List<Phase> phases, java.lang.String partialTitleToLookFor)` |
    `java.util.Date` | `findFirstSetDate()` |
    `java.lang.String` | `findFolderId()` |
    `void` | `fixId​(java.lang.String folderId)` |
    `java.util.Map<java.lang.String,​InternalMetadata>` | `get$metadata()` |
    `java.lang.String` | `getAbortComment()` |
    `java.util.List<Task>` | `getActiveTasks()` |
    `Team` | `getAdminTeam()` |
    `java.util.List<GateTask>` | `getAllGates()` |
    `boolean` | `getAllowTargetFolderOverride()` |
    `java.util.List<PlanItem>` | `getAllPlanItems()` |
    `java.util.Map<java.lang.String,​java.lang.String>` | `getAllStringVariableValues()` |
    `java.util.List<Task>` | `getAllTasks()` |
    `<T> java.util.List<T>` | `getAllTasksOfType​(java.lang.Class<T> clazz)` |
    `java.util.List<UserInputTask>` | `getAllUserInputTasks()` |
    `java.util.List<Variable>` | `getAllVariables()` |
    `java.util.Map<java.lang.String,​ValueWithInterpolation>` | `getAllVariableValuesAsStringsWithInterpolationInfo()` |
    `Attachment` | `getAttachment​(java.lang.String attachmentId)` |
    `java.util.List<Attachment>` | `getAttachments()` |
    `java.lang.String` | `getAuthor()` |
    `int` | `getAutomatedResumeCount()` |
    `java.lang.String` | `getCalendarLinkToken()` |
    `java.util.Set<java.lang.String>` | `getCategories()` |
    `java.util.List<PlanItem>` | `getChildren()` |
    `java.util.List<Variable>` | `getCiPropertyVariables()` |
    `java.lang.Integer` | `getCiUid()` |
    `Phase` | `getCurrentPhase()` |
    `Task` | `getCurrentTask()` |
    `java.lang.String` | `getDefaultTargetFolderId()` |
    `java.lang.String` | `getDisplayPath()` |
    `java.util.List<ReleaseExtension>` | `getExtensions()` |
    `FolderVariables` | `getFolderVariables()` |
    `GlobalVariables` | `getGlobalVariables()` |
    `ReleaseKind` | `getKind()` |
    `TemplateLogo` | `getLogo()` |
    `int` | `getMaxAutomatedResumes()` |
    `int` | `getMaxConcurrentReleases()` |
    `Phase` | `getNextPhase​(Phase currentPhase)` |
    `java.lang.String` | `getOriginTemplateId()` |
    `java.lang.String` | `getParentReleaseId()` |
    `java.util.Map<java.lang.String,​java.lang.String>` | `getPasswordVariableValues()` | This method is kept for backwards compatibility.
    `java.util.Set<java.lang.String>` | `getPermissions​(java.lang.String user, java.util.List<com.xebialabs.deployit.security.Role> userRoles)` |
    `java.util.Set<java.lang.String>` | `getPermissions​(java.util.Collection<java.lang.String> principals, java.util.List<com.xebialabs.deployit.security.Role> userRoles)` |
    `Phase` | `getPhase​(java.lang.Integer index)` |
    `Phase` | `getPhase​(java.lang.String phaseId)` |
    `java.util.List<Phase>` | `getPhases()` |
    `java.util.List<Phase>` | `getPhasesByTitle​(java.lang.String phaseTitle)` |
    `java.util.List<Phase>` | `getPhasesContainingInTitle​(java.lang.String partialTitleToLookFor)` |
    `java.util.Date` | `getQueryableEndDate()` |
    `java.util.Date` | `getQueryableStartDate()` |
    `FlagStatus` | `getRealFlagStatus()` |
    `Release` | `getRelease()` |
    `java.util.List<Attachment>` | `getReleaseAttachments()` |
    `java.util.Optional<ReleaseTrigger>` | `getReleaseTriggerById​(java.lang.String releaseTriggerId)` | Deprecated.
    `java.util.List<ReleaseTrigger>` | `getReleaseTriggers()` | Deprecated.
    `java.lang.Integer` | `getReleaseUid()` |
    `RiskProfile` | `getRiskProfile()` |
    `java.lang.String` | `getRootReleaseId()` |
    `java.lang.String` | `getScriptUsername()` |
    `java.lang.String` | `getScriptUserPassword()` |
    `java.lang.String` | `getStartedFromTaskId()` |
    `ReleaseStatus` | `getStatus()` |
    `java.util.List<java.lang.String>` | `getTags()` |
    `Task` | `getTask​(java.lang.String taskId)` |
    `java.util.List<Task>` | `getTasksByTitle​(java.lang.String phaseTitle, java.lang.String taskTitle)` |
    `java.util.Set<Task>` | `getTasksUsingAttachment​(java.lang.String attachmentId)` |
    `java.util.List<Team>` | `getTeams()` |
    `java.util.Set<java.lang.String>` | `getTeamsOf​(java.lang.String username, java.util.List<com.xebialabs.deployit.security.Role> userRoles)` |
    `Team` | `getTeamWithId​(java.lang.String id)` |
    `java.lang.String` | `getUrl()` |
    `java.util.Optional<Variable>` | `getVariableById​(java.lang.String variableId)` |
    `java.util.Map<java.lang.String,​java.lang.String>` | `getVariableMapping()` |
    `java.util.List<Variable>` | `getVariables()` |
    `java.util.Map<java.lang.String,​Variable>` | `getVariablesByKeys()` |
    `java.util.Set<java.lang.String>` | `getVariablesKeysInNonInterpolatableVariableValues()` |
    `java.util.List<UsagePoint>` | `getVariableUsages()` |
    `java.util.Map<java.lang.String,​java.lang.String>` | `getVariableValues()` | This method is kept for backwards compatibility.
    `boolean` | `hasBeenStarted()` |
    `boolean` | `hasCurrentPhase()` |
    `boolean` | `hasNextPhase​(Phase phase)` |
    `boolean` | `hasNoAutomatedTaskRunning()` |
    `boolean` | `hasPhase​(java.lang.String phaseId)` |
    `boolean` | `hasScriptUsername()` |
    `boolean` | `hasTeam​(java.lang.String teamName)` |
    `boolean` | `isAborted()` |
    `boolean` | `isAbortOnFailure()` |
    `boolean` | `isActive()` |
    `boolean` | `isAllowConcurrentReleasesFromTrigger()` |
    `boolean` | `isAllowPasswordsInAllFields()` |
    `boolean` | `isArchived()` |
    `boolean` | `isArchiveRelease()` |
    `boolean` | `isAutoStart()` |
    `boolean` | `isCalendarPublished()` |
    `boolean` | `isCreatedFromTrigger()` |
    `boolean` | `isDefunct()` |
    `boolean` | `isDisableNotifications()` |
    `boolean` | `isDone()` |
    `boolean` | `isFailed()` |
    `boolean` | `isFailing()` |
    `boolean` | `isInProgress()` |
    `boolean` | `isPaused()` |
    `boolean` | `isPending()` |
    `boolean` | `isPlanned()` |
    `boolean` | `isPlannedOrActive()` |
    `boolean` | `isTemplate()` |
    `boolean` | `isTutorial()` |
    `boolean` | `isUpdatable()` |
    `boolean` | `isVariableUsed​(Variable variable)` |
    `boolean` | `isWorkflow()` |
    `Changes` | `markTaskAsDone​(java.lang.String taskId, TaskStatus status)` |
    `Phase` | `movePhase​(java.lang.Integer originIndex, java.lang.Integer targetIndex)` |
    `Changes` | `removeVariable​(java.lang.String variableId)` |
    `void` | `replaceTask​(Task task)` |
    `void` | `replaceTrigger​(ReleaseTrigger releaseTrigger)` | Deprecated.
    `void` | `replaceVariable​(Variable current, Variable replacement)` |
    `Changes` | `restorePhases​(java.util.List<Phase> phases)` |
    `Changes` | `resume()` |
    `Changes` | `retryTask​(java.lang.String taskId)` |
    `java.util.List<Variable>` | `scanAndAddNewVariables()` |
    `java.util.List<Variable>` | `scanAndAddNewVariables​(VisitableItem updated)` |
    `void` | `setAbortOnFailure​(boolean abortOnFailure)` |
    `void` | `setAllowConcurrentReleasesFromTrigger​(boolean allowConcurrentReleasesFromTrigger)` |
    `void` | `setAllowPasswordsInAllFields​(boolean allowPasswordsInAllFields)` |
    `void` | `setAllowTargetFolderOverride​(boolean allowTargetFolderOverride)` |
    `void` | `setArchived​(boolean isArchived)` |
    `void` | `setArchiveRelease​(boolean archiveRelease)` |
    `void` | `setAttachments​(java.util.List<Attachment> attachments)` |
    `void` | `setAuthor​(java.lang.String author)` |
    `void` | `setAutomatedResumeCount​(int automatedResumeCount)` |
    `void` | `setAutoStart​(boolean autoStart)` |
    `void` | `setCalendarLinkToken​(java.lang.String calendarLinkToken)` |
    `void` | `setCalendarPublished​(boolean calendarPublished)` |
    `void` | `setCategories​(java.util.Set<java.lang.String> categories)` |
    `void` | `setCiUid​(java.lang.Integer ciUid)` |
    `void` | `setCreatedFromTrigger​(boolean createdFromTrigger)` |
    `void` | `setDefaultTargetFolderId​(java.lang.String defaultTargetFolderId)` |
    `void` | `setDisableNotifications​(boolean disableNotifications)` |
    `void` | `setDueDate​(java.util.Date value)` |
    `void` | `setEndDate​(java.util.Date value)` |
    `void` | `setExtensions​(java.util.List<ReleaseExtension> extensions)` |
    `void` | `setFolderVariables​(FolderVariables folderVariables)` |
    `void` | `setGlobalVariables​(GlobalVariables globalVariables)` |
    `void` | `setKind​(ReleaseKind kind)` |
    `void` | `setLogo​(TemplateLogo logo)` |
    `void` | `setMaxAutomatedResumes​(int maxAutomatedResumes)` |
    `void` | `setMaxConcurrentReleases​(int maxConcurrentReleases)` |
    `void` | `setOriginTemplateId​(java.lang.String originTemplateId)` |
    `void` | `setParentReleaseId​(java.lang.String parentReleaseId)` |
    `void` | `setPasswordVariableValues​(java.util.Map<java.lang.String,​?> variableValues)` | This method is kept for backwards compatibility.
    `void` | `setPhases​(java.util.List<Phase> phases)` |
    `void` | `setQueryableEndDate​(java.util.Date queryableEndDate)` |
    `void` | `setQueryableStartDate​(java.util.Date queryableStartDate)` |
    `void` | `setReleaseTriggers​(java.util.List<ReleaseTrigger> releaseTriggers)` | Deprecated.
    `void` | `setReleaseUid​(java.lang.Integer releaseUid)` |
    `void` | `setRiskProfile​(RiskProfile riskProfile)` |
    `void` | `setRootReleaseId​(java.lang.String rootReleaseId)` |
    `void` | `setScheduledStartDate​(java.util.Date scheduledStartDate)` |
    `void` | `setScriptUsername​(java.lang.String scriptUsername)` |
    `void` | `setScriptUserPassword​(java.lang.String scriptUserPassword)` |
    `void` | `setStartDate​(java.util.Date value)` |
    `void` | `setStartedFromTaskId​(java.lang.String startedFromTaskId)` |
    `void` | `setStatus​(ReleaseStatus value)` |
    `void` | `setTags​(java.util.List<java.lang.String> tags)` |
    `void` | `setTeams​(java.util.List<Team> teams)` |
    `void` | `setTutorial​(boolean tutorial)` |
    `void` | `setVariableMapping​(java.util.Map<java.lang.String,​java.lang.String> variableMapping)` |
    `void` | `setVariables​(java.util.List<Variable> variables)` |
    `void` | `setVariableValues​(java.util.Map<java.lang.String,​?> variableValues)` | This method is kept for backwards compatibility.
    `Changes` | `start()` |
    `Changes` | `start​(boolean releaseStartedImmediatelyAfterBeingCreated)` |
    `Changes` | `startAsPartOfBulkOperation()` |
    `Changes` | `startPendingTask​(java.lang.String taskId)` |
    `Changes` | `startWithInput​(java.lang.String taskId)` |
    `Changes` | `taskPreconditionValidated​(java.lang.String taskId)` |
    `java.lang.String` | `toString()` |
    `void` | `updateDatesForRelease​(java.util.Date scheduledStartDate, java.util.Date dueDate, java.lang.Integer plannedDuration)` |
    `void` | `updateDatesForTemplate​(java.util.Date scheduledStartDate, java.util.Date dueDate, java.lang.Integer plannedDuration)` |
    `void` | `updateRealFlagStatus()` |
    `void` | `updateTeam​(Team newTeam)` |

    - ### Methods inherited from class com.xebialabs.xlrelease.domain.PlanItem

      `calculateDueDate, checkDatesValidity, getActualDuration, getComputedPlannedDuration, getDescription, getDueDate, getEndDate, getEndOrDueDate, getFlagComment, getFlagStatus, getOrCalculateDueDate, getOwner, getPlannedDuration, getScheduledStartDate, getStartDate, getStartOrScheduledDate, getTitle, hasDueDate, hasEndDate, hasEndOrDueDate, hasOwner, hasOwner, hasPlannedDuration, hasScheduledStartDate, hasStartDate, hasStartOrScheduledDate, hasTitle, hasTitle, hasValidStartDates, isFlagged, isOverdue, isOverdueNotified, isTitleContaining, moveChildren, setDates, setDescription, setFlagComment, setFlagStatus, setOverdueNotified, setOwner, setPlannedDuration, setStartAndEndDatesIfEmpty, setTitle, shouldNotifyOverdue, updateDates, updateDuration`

    - ### 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`

    - ### 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 Detail

    - #### SCRIPT_USER_PASSWORD_VARIABLE_MAPPING_KEY

          public static final java.lang.String SCRIPT_USER_PASSWORD_VARIABLE_MAPPING_KEY

      See Also:
        Constant Field Values

    - #### DEFAULT_TARGET_FOLDER_ID_PROPERTY_NAME

          public static final java.lang.String DEFAULT_TARGET_FOLDER_ID_PROPERTY_NAME

      See Also:
        Constant Field Values

    - #### releaseTriggers

          @Deprecated
          @Property(asContainment=true,
                    required=false,
                    description="The triggers that may start a release from a template. (Templates only)",
                    isTransient=true)
          protected java.util.List<ReleaseTrigger> releaseTriggers

      Deprecated.

    - #### teams

          @Property(asContainment=true,
                    required=false,
                    description="The teams configured on the release.",
                    isTransient=true)
          protected java.util.List<Team> teams

      The Digital.ai Release teams are transient CIs and are kept for backwards-compatibility. The teams' data is stored using platform's `Role`. The teams need to be exported to template JSONs so they have to be a UDM property.

    - #### phases

          @Property(asContainment=true,
                    required=false,
                    description="The list of phases in the release.")
          protected java.util.List<Phase> phases

    - #### queryableStartDate

          @Property(required=false,
                    category="internal")
          protected java.util.Date queryableStartDate

    - #### queryableEndDate

          @Property(required=false,
                    category="internal")
          protected java.util.Date queryableEndDate

    - #### realFlagStatus

          @Property(description="The calculated flag status, derived from the flags from the release and its tasks.",
                    defaultValue="OK")
          protected FlagStatus realFlagStatus

    - #### status

          @Property(description="The state the release is in.")
          protected ReleaseStatus status

    - #### kind

          @Property(defaultValue="RELEASE",
                    label="Kind",
                    description="The kind of a template.")
          protected ReleaseKind kind

    - #### tags

          @Property(required=false,
                    description="The tags of the release. Tags can be used for grouping and querying.")
          protected java.util.List<java.lang.String> tags

    - #### categories

          @Property(required=false,
                    description="The categories for the release.")
          protected java.util.Set<java.lang.String> categories

    - #### variables

          @Property(asContainment=true,
                    required=false,
                    description="List of variable CIs representing variables in this release or template")
          protected java.util.List<Variable> variables

    - #### calendarLinkToken

          @Property(required=false,
                    category="internal")
          protected java.lang.String calendarLinkToken

    - #### calendarPublished

          @Property(required=false,
                    category="internal")
          protected boolean calendarPublished

    - #### tutorial

          @Property(required=false,
                    category="internal")
          protected boolean tutorial

    - #### abortOnFailure

          @Property(required=false,
                    description="Releases automatically abort when a task fails if this property is set to true.")
          protected boolean abortOnFailure

    - #### archiveRelease

          @Property(required=false,
                    defaultValue="true",
                    description="Archive release")
          protected boolean archiveRelease

    - #### allowPasswordsInAllFields

          @Property(required=false,
                    description="Allows the usage of passwords in non-password fields. Passwords values are masked in the UI and logging output but are decrypted before the task execution.")
          protected boolean allowPasswordsInAllFields

    - #### disableNotifications

          @Property(required=false,
                    description="Disable all notifications for this release.")
          protected boolean disableNotifications

    - #### allowConcurrentReleasesFromTrigger

          @Property(required=false,
                    description="If set to false, a trigger can\'t create a release if the previous one it created is still running.")
          protected boolean allowConcurrentReleasesFromTrigger

    - #### originTemplateId

          @Property(required=false,
                    description="The ID of the template that created this release.")
          protected java.lang.String originTemplateId

    - #### createdFromTrigger

          @Property(required=false,
                    description="True if release was created by a trigger.")
          protected boolean createdFromTrigger

    - #### scriptUsername

          @Property(required=false,
                    description="The credentials of this user are used to run automated scripts in this release.")
          protected java.lang.String scriptUsername

    - #### scriptUserPassword

          @Property(required=false,
                    password=true,
                    description="The password of the user that lends his credentials to run the scripts.")
          protected java.lang.String scriptUserPassword

    - #### extensions

          @Property(required=false,
                    asContainment=true,
                    description="Extensions of this release, e.g. \'Release contents dashboard\'")
          protected java.util.List<ReleaseExtension> extensions

    - #### startedFromTaskId

          @Property(required=false,
                    description="The Create Release task from which this release was created, if any")
          protected java.lang.String startedFromTaskId

    - #### autoStart

          @Property(required=false,
                    defaultValue="false",
                    description="If true, the release will automatically start at scheduledStartDate.")
          protected boolean autoStart

    - #### automatedResumeCount

          @Property(category="internal")
          protected int automatedResumeCount

    - #### maxAutomatedResumes

          @Property(category="internal",
                    hidden=true,
                    defaultValue="50",
                    description="The maximum number of automatic release resumes performed during phase restarts.")
          protected int maxAutomatedResumes

    - #### riskProfile

          @Property(required=false,
                    description="Risk profile used in risk calculations")
          protected RiskProfile riskProfile

    - #### author

          @Property(required=false,
                    description="The author of the template")
          protected java.lang.String author

    - #### logo

          @Property(nested=true,
                    required=false,
                    description="The logo of the template")
          protected TemplateLogo logo

  - ### Constructor Detail

    - #### Release

          public Release()

  - ### Method Detail

    - #### getPhases

          public java.util.List<Phase> getPhases()

    - #### setPhases

          public void setPhases​(java.util.List<Phase> phases)

    - #### getReleaseTriggers

          @Deprecated
          public java.util.List<ReleaseTrigger> getReleaseTriggers()

      Deprecated.

    - #### getReleaseTriggerById

          @Deprecated
          public java.util.Optional<ReleaseTrigger> getReleaseTriggerById​(java.lang.String releaseTriggerId)

      Deprecated.

    - #### setReleaseTriggers

          @Deprecated
          public void setReleaseTriggers​(java.util.List<ReleaseTrigger> releaseTriggers)

      Deprecated.

    - #### deleteReleaseTriggerById

          @Deprecated
          public void deleteReleaseTriggerById​(java.lang.String triggerId)

      Deprecated.

    - #### replaceTrigger

          @Deprecated
          public void replaceTrigger​(ReleaseTrigger releaseTrigger)

      Deprecated.

    - #### getRootReleaseId

          public java.lang.String getRootReleaseId()

    - #### setRootReleaseId

          public void setRootReleaseId​(java.lang.String rootReleaseId)

    - #### getParentReleaseId

          public java.lang.String getParentReleaseId()

    - #### setParentReleaseId

          public void setParentReleaseId​(java.lang.String parentReleaseId)

    - #### getMaxConcurrentReleases

          public int getMaxConcurrentReleases()

    - #### setMaxConcurrentReleases

          public void setMaxConcurrentReleases​(int maxConcurrentReleases)

    - #### getCiUid

          public java.lang.Integer getCiUid()

      Specified by:
        `getCiUid` in interface `CiWithUid`

    - #### setCiUid

          public void setCiUid​(java.lang.Integer ciUid)

      Specified by:
        `setCiUid` in interface `CiWithUid`

    - #### getAutomatedResumeCount

          public int getAutomatedResumeCount()

    - #### setAutomatedResumeCount

          public void setAutomatedResumeCount​(int automatedResumeCount)

    - #### getMaxAutomatedResumes

          public int getMaxAutomatedResumes()

    - #### setMaxAutomatedResumes

          public void setMaxAutomatedResumes​(int maxAutomatedResumes)

    - #### getAbortComment

          public java.lang.String getAbortComment()

    - #### getVariableValues

          public java.util.Map<java.lang.String,​java.lang.String> getVariableValues()

      This method is kept for backwards compatibility. `getVariables()` method provides richer access to the variable management.
      Returns:
        mapping from variable name to variable value containing only variables with string values. Variable names are in `${key}` format.

    - #### getPasswordVariableValues

          public java.util.Map<java.lang.String,​java.lang.String> getPasswordVariableValues()

      This method is kept for backwards compatibility. `getVariables()` method provides richer access to the variable management.
      Returns:
        mapping from variable name to variable value containing only variables with single password values. Variable names are in `${key}` format.

    - #### getCiPropertyVariables

          public java.util.List<Variable> getCiPropertyVariables()

    - #### getAllStringVariableValues

          public java.util.Map<java.lang.String,​java.lang.String> getAllStringVariableValues()

    - #### getAllVariableValuesAsStringsWithInterpolationInfo

          public java.util.Map<java.lang.String,​ValueWithInterpolation> getAllVariableValuesAsStringsWithInterpolationInfo()

    - #### getVariablesKeysInNonInterpolatableVariableValues

          public java.util.Set<java.lang.String> getVariablesKeysInNonInterpolatableVariableValues()

    - #### getVariablesByKeys

          public java.util.Map<java.lang.String,​Variable> getVariablesByKeys()

    - #### setVariableValues

          public void setVariableValues​(java.util.Map<java.lang.String,​?> variableValues)

      This method is kept for backwards compatibility. `setVariables(List)` method provides richer access to the variable management.
      Parameters:
        `variableValues` - mapping from variable name to variable value containing only variables with string values. Variable names are in `${key}` or `key` format.

    - #### setPasswordVariableValues

          public void setPasswordVariableValues​(java.util.Map<java.lang.String,​?> variableValues)

      This method is kept for backwards compatibility. `setVariables(List)` method provides richer access to the variable management.
      Parameters:
        `variableValues` - mapping from password variable name to password variable value. Variable names are in `${key}` or `key` format.

    - #### scanAndAddNewVariables

          public java.util.List<Variable> scanAndAddNewVariables​(VisitableItem updated)

    - #### scanAndAddNewVariables

          public java.util.List<Variable> scanAndAddNewVariables()

    - #### getAllVariables

          public java.util.List<Variable> getAllVariables()

      Specified by:
        `getAllVariables` in interface `VariableContainer`

    - #### getVariables

          public java.util.List<Variable> getVariables()

    - #### addVariables

          public void addVariables​(java.util.List<Variable> newVariables)

    - #### replaceVariable

          public void replaceVariable​(Variable current,
                                      Variable replacement)

    - #### setVariables

          public void setVariables​(java.util.List<Variable> variables)

    - #### getVariableById

          public java.util.Optional<Variable> getVariableById​(java.lang.String variableId)

    - #### addVariable

          public Variable addVariable​(Variable variable)

    - #### checkVariableCanBeAdded

          public void checkVariableCanBeAdded​(Variable variable)

    - #### getGlobalVariables

          public GlobalVariables getGlobalVariables()

    - #### setGlobalVariables

          public void setGlobalVariables​(GlobalVariables globalVariables)

    - #### getFolderVariables

          public FolderVariables getFolderVariables()

    - #### setFolderVariables

          public void setFolderVariables​(FolderVariables folderVariables)

    - #### removeVariable

          public Changes removeVariable​(java.lang.String variableId)

    - #### isVariableUsed

          public boolean isVariableUsed​(Variable variable)

    - #### getStatus

          public ReleaseStatus getStatus()

    - #### setStatus

          public void setStatus​(ReleaseStatus value)

    - #### getAdminTeam

          public Team getAdminTeam()

    - #### getTeams

          public java.util.List<Team> getTeams()

    - #### setTeams

          public void setTeams​(java.util.List<Team> teams)

    - #### getCategories

          public java.util.Set<java.lang.String> getCategories()

    - #### setCategories

          public void setCategories​(java.util.Set<java.lang.String> categories)

    - #### getTags

          public java.util.List<java.lang.String> getTags()

    - #### setTags

          public void setTags​(java.util.List<java.lang.String> tags)

    - #### getAttachments

          public java.util.List<Attachment> getAttachments()

    - #### setAttachments

          public void setAttachments​(java.util.List<Attachment> attachments)

    - #### deleteAttachment

          public void deleteAttachment​(java.lang.String attachmentId)

    - #### getTasksUsingAttachment

          public java.util.Set<Task> getTasksUsingAttachment​(java.lang.String attachmentId)

    - #### hasBeenStarted

          public boolean hasBeenStarted()

      Specified by:
        `hasBeenStarted` in class `PlanItem`

    - #### getReleaseAttachments

          public java.util.List<Attachment> getReleaseAttachments()

    - #### getCalendarLinkToken

          public java.lang.String getCalendarLinkToken()

    - #### setCalendarLinkToken

          public void setCalendarLinkToken​(java.lang.String calendarLinkToken)

    - #### isCalendarPublished

          public boolean isCalendarPublished()

    - #### setCalendarPublished

          public void setCalendarPublished​(boolean calendarPublished)

    - #### getExtensions

          public java.util.List<ReleaseExtension> getExtensions()

    - #### setExtensions

          public void setExtensions​(java.util.List<ReleaseExtension> extensions)

    - #### getRealFlagStatus

          public FlagStatus getRealFlagStatus()

    - #### getCurrentPhase

          public Phase getCurrentPhase()

    - #### getCurrentTask

          public Task getCurrentTask()

    - #### hasCurrentPhase

          public boolean hasCurrentPhase()

    - #### start

          public Changes start()

    - #### start

          public Changes start​(boolean releaseStartedImmediatelyAfterBeingCreated)

    - #### startAsPartOfBulkOperation

          public Changes startAsPartOfBulkOperation()

    - #### resume

          public Changes resume()

    - #### markTaskAsDone

          public Changes markTaskAsDone​(java.lang.String taskId,
                                        TaskStatus status)

    - #### startPendingTask

          public Changes startPendingTask​(java.lang.String taskId)

    - #### startWithInput

          public Changes startWithInput​(java.lang.String taskId)

    - #### taskPreconditionValidated

          public Changes taskPreconditionValidated​(java.lang.String taskId)

    - #### failTask

          public Changes failTask​(java.lang.String taskId,
                                  java.lang.String failReason)

    - #### failTask

          public Changes failTask​(java.lang.String taskId,
                                  java.lang.String failReason,
                                  boolean fromAbort)

    - #### failTask

          public Changes failTask​(java.lang.String taskId,
                                  java.lang.String failReason,
                                  User user,
                                  boolean fromAbort)

    - #### abort

          public Changes abort​(java.lang.String abortComment)

    - #### abortAsPartOfBulkOperation

          public Changes abortAsPartOfBulkOperation​(java.lang.String abortComment)

    - #### retryTask

          public Changes retryTask​(java.lang.String taskId)

    - #### getNextPhase

          public Phase getNextPhase​(Phase currentPhase)

    - #### hasNextPhase

          public boolean hasNextPhase​(Phase phase)

    - #### addPhase

          public void addPhase​(Phase phase)

    - #### addPhase

          public void addPhase​(Phase phase,
                               int position)

    - #### deletePhase

          public void deletePhase​(Phase phase)

    - #### getAllTasks

          public java.util.List<Task> getAllTasks()

    - #### getTask

          public Task getTask​(java.lang.String taskId)

    - #### getAttachment

          public Attachment getAttachment​(java.lang.String attachmentId)

    - #### movePhase

          public Phase movePhase​(java.lang.Integer originIndex,
                                 java.lang.Integer targetIndex)

    - #### getPhase

          public Phase getPhase​(java.lang.Integer index)

    - #### getPhase

          public Phase getPhase​(java.lang.String phaseId)

    - #### hasPhase

          public boolean hasPhase​(java.lang.String phaseId)

    - #### addTeam

          public void addTeam​(Team team)

    - #### deleteTeam

          public void deleteTeam​(java.lang.String teamId)

    - #### addBelow

          public void addBelow​(java.lang.String phaseId,
                               Phase addedPhase)

    - #### collectVariableReferences

          public java.util.Set<VariableReference> collectVariableReferences()

    - #### collectVariableReferences

          public java.util.Set<VariableReference> collectVariableReferences​(VisitableItem updated)

    - #### getAllGates

          public java.util.List<GateTask> getAllGates()

    - #### getAllUserInputTasks

          public java.util.List<UserInputTask> getAllUserInputTasks()

    - #### getAllTasksOfType

          public <T> java.util.List<T> getAllTasksOfType​(java.lang.Class<T> clazz)

    - #### findFirstSetDate

          public java.util.Date findFirstSetDate()

    - #### clearComments

          public void clearComments()

    - #### hasNoAutomatedTaskRunning

          public boolean hasNoAutomatedTaskRunning()

    - #### isDone

          public boolean isDone()

      Specified by:
        `isDone` in class `PlanItem`

    - #### isPlannedOrActive

          public boolean isPlannedOrActive()

    - #### isActive

          public boolean isActive()

      Specified by:
        `isActive` in class `PlanItem`

    - #### isDefunct

          public boolean isDefunct()

    - #### isUpdatable

          public boolean isUpdatable()

      Specified by:
        `isUpdatable` in class `PlanItem`

    - #### isAborted

          public boolean isAborted()

      Specified by:
        `isAborted` in class `PlanItem`

    - #### isFailing

          public boolean isFailing()

    - #### isFailed

          public boolean isFailed()

    - #### isPaused

          public boolean isPaused()

    - #### isTemplate

          public boolean isTemplate()

    - #### isWorkflow

          public boolean isWorkflow()

    - #### isPlanned

          public boolean isPlanned()

    - #### isInProgress

          public boolean isInProgress()

    - #### isTutorial

          public boolean isTutorial()

    - #### setTutorial

          public void setTutorial​(boolean tutorial)

    - #### isAbortOnFailure

          public boolean isAbortOnFailure()

    - #### setAbortOnFailure

          public void setAbortOnFailure​(boolean abortOnFailure)

    - #### isArchiveRelease

          public boolean isArchiveRelease()

    - #### setArchiveRelease

          public void setArchiveRelease​(boolean archiveRelease)

    - #### isAllowPasswordsInAllFields

          public boolean isAllowPasswordsInAllFields()

    - #### setAllowPasswordsInAllFields

          public void setAllowPasswordsInAllFields​(boolean allowPasswordsInAllFields)

    - #### isDisableNotifications

          public boolean isDisableNotifications()

    - #### setDisableNotifications

          public void setDisableNotifications​(boolean disableNotifications)

    - #### isAllowConcurrentReleasesFromTrigger

          public boolean isAllowConcurrentReleasesFromTrigger()

    - #### setAllowConcurrentReleasesFromTrigger

          public void setAllowConcurrentReleasesFromTrigger​(boolean allowConcurrentReleasesFromTrigger)

    - #### getOriginTemplateId

          public java.lang.String getOriginTemplateId()

    - #### setOriginTemplateId

          public void setOriginTemplateId​(java.lang.String originTemplateId)

    - #### isCreatedFromTrigger

          public boolean isCreatedFromTrigger()

    - #### setCreatedFromTrigger

          public void setCreatedFromTrigger​(boolean createdFromTrigger)

    - #### getRelease

          public Release getRelease()

      Specified by:
        `getRelease` in class `PlanItem`

    - #### getReleaseUid

          public java.lang.Integer getReleaseUid()

      Specified by:
        `getReleaseUid` in class `PlanItem`

    - #### setReleaseUid

          public void setReleaseUid​(java.lang.Integer releaseUid)

      Specified by:
        `setReleaseUid` in class `PlanItem`

    - #### getDisplayPath

          public java.lang.String getDisplayPath()

      Specified by:
        `getDisplayPath` in class `PlanItem`

    - #### getTeamWithId

          public Team getTeamWithId​(java.lang.String id)

    - #### getChildren

          public java.util.List<PlanItem> getChildren()

      Specified by:
        `getChildren` in class `PlanItem`

    - #### getAllPlanItems

          public java.util.List<PlanItem> getAllPlanItems()

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `BaseConfigurationItem`

    - #### checkDatesValidityForRelease

          public void checkDatesValidityForRelease()

    - #### checkDatesValidityForTemplate

          public void checkDatesValidityForTemplate()

    - #### checkDatesValidity

          public void checkDatesValidity()

    - #### updateDatesForRelease

          public void updateDatesForRelease​(java.util.Date scheduledStartDate,
                                            java.util.Date dueDate,
                                            java.lang.Integer plannedDuration)

    - #### updateDatesForTemplate

          public void updateDatesForTemplate​(java.util.Date scheduledStartDate,
                                             java.util.Date dueDate,
                                             java.lang.Integer plannedDuration)

    - #### getQueryableStartDate

          public java.util.Date getQueryableStartDate()

    - #### setQueryableStartDate

          public void setQueryableStartDate​(java.util.Date queryableStartDate)

    - #### getQueryableEndDate

          public java.util.Date getQueryableEndDate()

    - #### setQueryableEndDate

          public void setQueryableEndDate​(java.util.Date queryableEndDate)

    - #### getScriptUsername

          public java.lang.String getScriptUsername()

    - #### setScriptUsername

          public void setScriptUsername​(java.lang.String scriptUsername)

    - #### getScriptUserPassword

          public java.lang.String getScriptUserPassword()

    - #### setScriptUserPassword

          public void setScriptUserPassword​(java.lang.String scriptUserPassword)

    - #### getUrl

          public java.lang.String getUrl()

    - #### getVariableMapping

          public java.util.Map<java.lang.String,​java.lang.String> getVariableMapping()

    - #### setVariableMapping

          public void setVariableMapping​(java.util.Map<java.lang.String,​java.lang.String> variableMapping)

    - #### getRiskProfile

          public RiskProfile getRiskProfile()

    - #### setRiskProfile

          public void setRiskProfile​(RiskProfile riskProfile)

    - #### getStartedFromTaskId

          public java.lang.String getStartedFromTaskId()

    - #### setStartedFromTaskId

          public void setStartedFromTaskId​(java.lang.String startedFromTaskId)

    - #### setStartDate

          public void setStartDate​(java.util.Date value)

      Overrides:
        `setStartDate` in class `PlanItem`

    - #### setScheduledStartDate

          public void setScheduledStartDate​(java.util.Date scheduledStartDate)

      Overrides:
        `setScheduledStartDate` in class `PlanItem`

    - #### setEndDate

          public void setEndDate​(java.util.Date value)

      Overrides:
        `setEndDate` in class `PlanItem`

    - #### setDueDate

          public void setDueDate​(java.util.Date value)

      Overrides:
        `setDueDate` in class `PlanItem`

    - #### getKind

          public ReleaseKind getKind()

    - #### setKind

          public void setKind​(ReleaseKind kind)

    - #### getAuthor

          public java.lang.String getAuthor()

    - #### setAuthor

          public void setAuthor​(java.lang.String author)

    - #### getLogo

          public TemplateLogo getLogo()

    - #### setLogo

          public void setLogo​(TemplateLogo logo)

    - #### getDefaultTargetFolderId

          public java.lang.String getDefaultTargetFolderId()

    - #### setDefaultTargetFolderId

          public void setDefaultTargetFolderId​(java.lang.String defaultTargetFolderId)

    - #### getAllowTargetFolderOverride

          public boolean getAllowTargetFolderOverride()

    - #### setAllowTargetFolderOverride

          public void setAllowTargetFolderOverride​(boolean allowTargetFolderOverride)

    - #### updateTeam

          public void updateTeam​(Team newTeam)

    - #### updateRealFlagStatus

          public void updateRealFlagStatus()

    - #### hasScriptUsername

          public boolean hasScriptUsername()

    - #### getActiveTasks

          public java.util.List<Task> getActiveTasks()

    - #### isArchived

          public boolean isArchived()

    - #### setArchived

          public void setArchived​(boolean isArchived)

    - #### accept

          public void accept​(ReleaseVisitor visitor)

      Specified by:
        `accept` in interface `VisitableItem`

    - #### getVariableUsages

          public java.util.List<UsagePoint> getVariableUsages()

      Specified by:
        `getVariableUsages` in class `PlanItem`

    - #### get$metadata

          public java.util.Map<java.lang.String,​InternalMetadata> get$metadata()

      Specified by:
        `get$metadata` in interface `CiWithInternalMetadata`

    - #### findFolderId

          public java.lang.String findFolderId()

    - #### hasTeam

          public boolean hasTeam​(java.lang.String teamName)

    - #### getTeamsOf

          public java.util.Set<java.lang.String> getTeamsOf​(java.lang.String username,
                                                            java.util.List<com.xebialabs.deployit.security.Role> userRoles)

    - #### getPermissions

          public java.util.Set<java.lang.String> getPermissions​(java.lang.String user,
                                                                java.util.List<com.xebialabs.deployit.security.Role> userRoles)

    - #### getPermissions

          public java.util.Set<java.lang.String> getPermissions​(java.util.Collection<java.lang.String> principals,
                                                                java.util.List<com.xebialabs.deployit.security.Role> userRoles)

    - #### isAutoStart

          public boolean isAutoStart()

    - #### setAutoStart

          public void setAutoStart​(boolean autoStart)

    - #### canAutomaticallyStartReleaseNow

          public boolean canAutomaticallyStartReleaseNow()

    - #### canScheduleReleaseStart

          public boolean canScheduleReleaseStart()

    - #### isPending

          public boolean isPending()

    - #### deleteTask

          public void deleteTask​(Task task)

    - #### replaceTask

          public void replaceTask​(Task task)

    - #### getPhasesByTitle

          public java.util.List<Phase> getPhasesByTitle​(java.lang.String phaseTitle)

    - #### getPhasesContainingInTitle

          public java.util.List<Phase> getPhasesContainingInTitle​(java.lang.String partialTitleToLookFor)

    - #### filterPhasesContainingInTitle

          public java.util.List<Phase> filterPhasesContainingInTitle​(java.util.List<Phase> phases,
                                                                     java.lang.String partialTitleToLookFor)

    - #### getTasksByTitle

          public java.util.List<Task> getTasksByTitle​(java.lang.String phaseTitle,
                                                      java.lang.String taskTitle)

    - #### restorePhases

          public Changes restorePhases​(java.util.List<Phase> phases)

    - #### fixId

          public void fixId​(java.lang.String folderId)