@PublicApi public final class CoreEffects extends Object
effect descriptions
for common effects provided by Structure.Modifier and Type | Method and Description |
---|---|
static StoredEffect |
addCustomFieldGroups(Issue issue,
CustomField customField,
Collection<Group> groups)
Returns a description of an effect that would add the given groups to a multi group custom field.
|
static StoredEffect |
addCustomFieldLabels(Issue issue,
CustomField customField,
Collection<String> labels)
Returns a description of an effect that would add the given labels to a labels custom field.
|
static StoredEffect |
addCustomFieldOptions(Issue issue,
CustomField customField,
Collection<Option> options)
Returns a description of an effect that would add the given options to a multi select custom field.
|
static StoredEffect |
addCustomFieldUsers(Issue issue,
CustomField customField,
Collection<ApplicationUser> users)
Returns a description of an effect that would add the given users to a multi user custom field.
|
static StoredEffect |
addCustomFieldVersions(Issue issue,
CustomField customField,
Collection<Version> versions)
Returns a description of an effect that would add the given versions to a multi version custom field.
|
static StoredEffect |
addIssueAffectedVersions(Issue issue,
Collection<Version> versions)
Returns a description of an effect that would add affected versions to the issue.
|
static StoredEffect |
addIssueComment(Issue issue,
String commentBody)
Returns a description of an effect that would add a comment.
|
static StoredEffect |
addIssueComponents(Issue issue,
Collection<ProjectComponent> components)
Returns a description of an effect that would add components to the issue.
|
static StoredEffect |
addIssueFixVersions(Issue issue,
Collection<Version> versions)
Returns a description of an effect that would add fix versions to the issue.
|
static StoredEffect |
addIssueLabels(Issue issue,
Collection<String> labels)
Returns a description of an effect that would add labels to the issue.
|
static StoredEffect |
assignIssue(Issue issue,
ApplicationUser assignee)
Returns a description of an effect that would assign an issue to the given user.
|
static StoredEffect |
deleteIssueComment(Issue issue,
Comment comment)
Returns a description of an effect that would delete a comment.
|
static StoredEffect |
emitWarning(I18nText i18nText,
List<ItemIdentity> itemIdentities)
Returns a description of an effect that can't be deserialized successfully but used to describe a specific problem.
|
static StoredEffect |
removeCustomFieldGroups(Issue issue,
CustomField customField,
Collection<Group> groups)
Returns a description of an effect that would remove the given groups from a multi group custom field.
|
static StoredEffect |
removeCustomFieldLabels(Issue issue,
CustomField customField,
Collection<String> labels)
Returns a description of an effect that would remove the given labels from a labels custom field.
|
static StoredEffect |
removeCustomFieldOptions(Issue issue,
CustomField customField,
Collection<Option> options)
Returns a description of an effect that would remove the given options from a multi select custom field.
|
static StoredEffect |
removeCustomFieldUsers(Issue issue,
CustomField customField,
Collection<ApplicationUser> users)
Returns a description of an effect that would remove the given users from a multi user custom field.
|
static StoredEffect |
removeCustomFieldVersions(Issue issue,
CustomField customField,
Collection<Version> versions)
Returns a description of an effect that would remove the given versions from a multi version custom field.
|
static StoredEffect |
removeIssueAffectedVersions(Issue issue,
Collection<Version> versions)
Returns a description of an effect that would remove affected versions from the issue.
|
static StoredEffect |
removeIssueComponents(Issue issue,
Collection<ProjectComponent> components)
Returns a description of an effect that would remove components from the issue.
|
static StoredEffect |
removeIssueFixVersions(Issue issue,
Collection<Version> versions)
Returns a description of an effect that would remove fix versions from the issue.
|
static StoredEffect |
removeIssueLabels(Issue issue,
Collection<String> labels)
Returns a description of an effect that would remove labels from the issue.
|
static StoredEffect |
setCascadeCustomField(Issue issue,
CustomField customField,
Option value)
Returns a description of an effect that would set a cascading select custom
field to the given option.
|
static StoredEffect |
setCustomFieldGroups(Issue issue,
CustomField customField,
Collection<Group> groups)
Returns a description of an effect that would set a multi group custom
field to the given groups.
|
static StoredEffect |
setCustomFieldLabels(Issue issue,
CustomField customField,
Collection<String> labels)
Returns a description of an effect that would set a labels custom
field to the given labels.
|
static StoredEffect |
setCustomFieldOptions(Issue issue,
CustomField customField,
Collection<Option> options)
Returns a description of an effect that would set a multi select custom
field to the given options.
|
static StoredEffect |
setCustomFieldUsers(Issue issue,
CustomField customField,
Collection<ApplicationUser> users)
Returns a description of an effect that would set a multi user custom
field to the given users.
|
static StoredEffect |
setCustomFieldVersions(Issue issue,
CustomField customField,
Collection<Version> versions)
Returns a description of an effect that would set a multi version custom
field to the given versions.
|
static StoredEffect |
setDateCustomField(Issue issue,
CustomField customField,
Date value)
Returns a description of an effect that would set a date custom
field to the given value.
|
static StoredEffect |
setDateTimeCustomField(Issue issue,
CustomField customField,
Date value)
Returns a description of an effect that would set a date time custom
field to the given value.
|
static StoredEffect |
setIssueAffectedVersions(Issue issue,
Collection<Version> versions)
Returns a description of an effect that would replace issue affected versions with the given values.
|
static StoredEffect |
setIssueComponents(Issue issue,
Collection<ProjectComponent> components)
Returns a description of an effect that would replace issue components with the given values.
|
static StoredEffect |
setIssueDescription(Issue issue,
String description)
Returns a description of an effect that would change an issue Description field to the given value.
|
static StoredEffect |
setIssueDueDate(Issue issue,
Date date)
Returns a description of an effect that would change an issue due date to the given value.
|
static StoredEffect |
setIssueEnvironment(Issue issue,
String environment)
Returns a description of an effect that would change an issue Environment field to the given value.
|
static StoredEffect |
setIssueFixVersions(Issue issue,
Collection<Version> versions)
Returns a description of an effect that would replace issue fix versions with the given values.
|
static StoredEffect |
setIssueLabels(Issue issue,
Collection<String> labels)
Returns a description of an effect that would replace issue labels with the given values.
|
static StoredEffect |
setIssuePriority(Issue issue,
Priority priority)
Returns a description of an effect that would change an issue priority to the given value.
|
static StoredEffect |
setIssueReporter(Issue issue,
ApplicationUser reporter)
Returns a description of an effect that would set an issue reporter to the given user.
|
static StoredEffect |
setIssueResolution(Issue issue,
Resolution resolution)
Returns a description of an effect that would change an issue Resolution field to the given value.
|
static StoredEffect |
setIssueResolutionDate(Issue issue,
Date date)
Deprecated.
The "Resolved" field in Jira is not editable, and this method
should not be used. There is no corresponding effect provider in Structure.
|
static StoredEffect |
setIssueStatus(Issue issue,
Status status)
Returns a description of an effect that would transition an issue to the given
status.
|
static StoredEffect |
setIssueSummary(Issue issue,
String summary)
Returns a description of an effect that would change an issue summary to the given value.
|
static StoredEffect |
setNumberCustomField(Issue issue,
CustomField customField,
Number value)
Returns a description of an effect that would set a number custom
field to the given value.
|
static StoredEffect |
setOriginalEstimate(Issue issue,
Long originalEstimate)
Returns a description of an effect that would change an issue original estimate to the given value.
|
static StoredEffect |
setProjectPickerCustomField(Issue issue,
CustomField customField,
Project value)
Returns a description of an effect that would set a project picker custom
field to the given value.
|
static StoredEffect |
setRemainingEstimate(Issue issue,
Long remainingEstimate)
Returns a description of an effect that would change an issue remaining estimate to the given value.
|
static StoredEffect |
setSingleGroupCustomField(Issue issue,
CustomField customField,
Group value)
Returns a description of an effect that would set a single group custom
field to the given value.
|
static StoredEffect |
setSingleSelectCustomField(Issue issue,
CustomField customField,
Option value)
Returns a description of an effect that would set a single select custom
field to the given option.
|
static StoredEffect |
setSingleUserCustomField(Issue issue,
CustomField customField,
ApplicationUser value)
Returns a description of an effect that would set a single user custom
field to the given value.
|
static StoredEffect |
setSingleVersionCustomField(Issue issue,
CustomField customField,
Version value)
Returns a description of an effect that would set a single version custom
field to the given value.
|
static StoredEffect |
setSprint(Issue issue,
Long sprintId)
Returns a description of an effect that would move an issue to the sprint with the given id.
|
static StoredEffect |
setTextCustomField(Issue issue,
CustomField customField,
String value)
Returns a description of an effect that would set a text custom
field to the given value.
|
@NotNull public static StoredEffect emitWarning(@NotNull I18nText i18nText, @NotNull List<ItemIdentity> itemIdentities)
i18nText
- The warning message.itemIdentities
- An ID list of items to which the warning message is related.@NotNull public static StoredEffect assignIssue(@NotNull Issue issue, @Nullable ApplicationUser assignee)
issue
- The issue.assignee
- The user to set. Passing null
will make the issue unassigned.@NotNull public static StoredEffect setIssueReporter(@NotNull Issue issue, @Nullable ApplicationUser reporter)
issue
- The issue.reporter
- The user to set. Passing null
will clear the reporter value.@NotNull public static StoredEffect setIssuePriority(@NotNull Issue issue, @Nullable Priority priority)
issue
- The issue.priority
- The priority to set. Passing null
will clear the priority value.@NotNull public static StoredEffect setIssueDescription(@NotNull Issue issue, @Nullable String description)
issue
- The issue.description
- The description value to set. Passing null
will clear an issue description.@NotNull public static StoredEffect setIssueEnvironment(@NotNull Issue issue, @Nullable String environment)
issue
- The issue.environment
- The environment value to set. Passing null
will clear the Environment field value.@NotNull public static StoredEffect setIssueResolution(@NotNull Issue issue, @Nullable Resolution resolution)
issue
- The issue.resolution
- The resolution to set. Passing null
will clear the Resolution field value.@NotNull public static StoredEffect setIssueSummary(@NotNull Issue issue, @Nullable String summary)
issue
- The issue.summary
- The summary value to set. Passing null
will clear the issue summary.@NotNull public static StoredEffect setIssueDueDate(@NotNull Issue issue, @Nullable Date date)
issue
- The issue.date
- The due date to set. Passing null
will clear the issue due date.@NotNull @Deprecated public static StoredEffect setIssueResolutionDate(@NotNull Issue issue, @Nullable Date date)
issue
- The issue.date
- The resolution date to set. Passing null
will clear the issue resolution date.@NotNull public static StoredEffect setIssueStatus(@NotNull Issue issue, @Nullable Status status)
issue
- The issue.status
- The status. Passing null
is allowed, but would produce
an effect that would always deserialize with an error.@NotNull public static StoredEffect setOriginalEstimate(@NotNull Issue issue, @Nullable Long originalEstimate)
issue
- The issue.originalEstimate
- The original estimate to set. Passing null
will clear the issue original estimate.@NotNull public static StoredEffect setRemainingEstimate(@NotNull Issue issue, @Nullable Long remainingEstimate)
issue
- The issue.remainingEstimate
- The remaining estimate to set. Passing null
will clear the issue remaining estimate.@NotNull public static StoredEffect setSprint(@NotNull Issue issue, @Nullable Long sprintId)
issue
- The issue.sprintId
- The id of the sprint to move issue to. Passing null
will remove the issue from its current sprint.@NotNull public static StoredEffect setSingleSelectCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Option value)
issue
- The issue.customField
- The custom field, must be a single select custom field.value
- The option to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a single select field.@NotNull public static StoredEffect setProjectPickerCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Project value)
issue
- The issue.customField
- The custom field, must be a project picker custom field.value
- The project value to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a project picker field.@NotNull public static StoredEffect setSingleUserCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable ApplicationUser value)
issue
- The issue.customField
- The custom field, must be a single user custom field.value
- The user to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a single user field.@NotNull public static StoredEffect setSingleVersionCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Version value)
issue
- The issue.customField
- The custom field, must be a single version custom field.value
- The version to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a single version field.@NotNull public static StoredEffect setTextCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable String value)
issue
- The issue.customField
- The custom field, must be a text custom field.value
- The text value to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a text field.@NotNull public static StoredEffect setNumberCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Number value)
issue
- The issue.customField
- The custom field, must be a number custom field.value
- The number value to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a number field.@NotNull public static StoredEffect setDateCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Date value)
issue
- The issue.customField
- The custom field, must be a date custom field.value
- The date value to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a date field.@NotNull public static StoredEffect setDateTimeCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Date value)
issue
- The issue.customField
- The custom field, must be a date time custom field.value
- The date time value to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a date time field.@NotNull public static StoredEffect setSingleGroupCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Group value)
issue
- The issue.customField
- The custom field, must be a single group custom field.value
- The group value to set. Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a single group field.@NotNull public static StoredEffect setCascadeCustomField(@NotNull Issue issue, @NotNull CustomField customField, @Nullable Option value)
issue
- The issue.customField
- The custom field, must be a cascading select custom field.value
- The option to set. Can be a parent or a child option.
Passing null
will clear the field value.IllegalArgumentException
- if the given custom field is not a cascading select field.public static StoredEffect setIssueLabels(Issue issue, Collection<String> labels)
issue
- The issue.labels
- The labels to set.public static StoredEffect addIssueLabels(Issue issue, Collection<String> labels)
issue
- The issue.labels
- The labels to add.public static StoredEffect removeIssueLabels(Issue issue, Collection<String> labels)
issue
- The issue.labels
- The labels to remove.@NotNull public static StoredEffect setIssueComponents(@NotNull Issue issue, @NotNull Collection<ProjectComponent> components)
issue
- The issue.components
- The components to set.@NotNull public static StoredEffect addIssueComponents(@NotNull Issue issue, @NotNull Collection<ProjectComponent> components)
issue
- The issue.components
- The components to add.@NotNull public static StoredEffect removeIssueComponents(@NotNull Issue issue, @NotNull Collection<ProjectComponent> components)
issue
- The issue.components
- The components to remove.@NotNull public static StoredEffect setIssueAffectedVersions(@NotNull Issue issue, @NotNull Collection<Version> versions)
issue
- The issue.versions
- The versions to set.@NotNull public static StoredEffect addIssueAffectedVersions(@NotNull Issue issue, @NotNull Collection<Version> versions)
issue
- The issue.versions
- The versions to add.@NotNull public static StoredEffect removeIssueAffectedVersions(@NotNull Issue issue, @NotNull Collection<Version> versions)
issue
- The issue.versions
- The versions to remove.@NotNull public static StoredEffect setIssueFixVersions(@NotNull Issue issue, @NotNull Collection<Version> versions)
issue
- The issue.versions
- The versions to set.@NotNull public static StoredEffect addIssueFixVersions(@NotNull Issue issue, @NotNull Collection<Version> versions)
issue
- The issue.versions
- The versions to add.@NotNull public static StoredEffect removeIssueFixVersions(@NotNull Issue issue, @NotNull Collection<Version> versions)
issue
- The issue.versions
- The versions to remove.@NotNull public static StoredEffect setCustomFieldVersions(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Version> versions)
issue
- The issue.customField
- The custom field, must be a multi version custom field.versions
- The versions to set.IllegalArgumentException
- if the given custom field is not a multi version field.@NotNull public static StoredEffect addCustomFieldVersions(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Version> versions)
issue
- The issue.customField
- The custom field, must be a multi version custom field.versions
- The versions to add.IllegalArgumentException
- if the given custom field is not a multi version field.@NotNull public static StoredEffect removeCustomFieldVersions(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Version> versions)
issue
- The issue.customField
- The custom field, must be a multi version custom field.versions
- The versions to remove.IllegalArgumentException
- if the given custom field is not a multi version field.@NotNull public static StoredEffect setCustomFieldOptions(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Option> options)
issue
- The issue.customField
- The custom field, must be a multi select custom field.options
- The options to set.IllegalArgumentException
- if the given custom field is not a multi select field.@NotNull public static StoredEffect addCustomFieldOptions(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Option> options)
issue
- The issue.customField
- The custom field, must be a multi select custom field.options
- The options to add.IllegalArgumentException
- if the given custom field is not a multi select field.@NotNull public static StoredEffect removeCustomFieldOptions(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Option> options)
issue
- The issue.customField
- The custom field, must be a multi select custom field.options
- The options to remove.IllegalArgumentException
- if the given custom field is not a multi select field.@NotNull public static StoredEffect setCustomFieldUsers(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<ApplicationUser> users)
issue
- The issue.customField
- The custom field, must be a multi user custom field.users
- The users to set.IllegalArgumentException
- if the given custom field is not a multi user field.@NotNull public static StoredEffect addCustomFieldUsers(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<ApplicationUser> users)
issue
- The issue.customField
- The custom field, must be a multi user custom field.users
- The users to add.IllegalArgumentException
- if the given custom field is not a multi user field.@NotNull public static StoredEffect removeCustomFieldUsers(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<ApplicationUser> users)
issue
- The issue.customField
- The custom field, must be a multi user custom field.users
- The users to remove.IllegalArgumentException
- if the given custom field is not a multi user field.@NotNull public static StoredEffect setCustomFieldGroups(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Group> groups)
issue
- The issue.customField
- The custom field, must be a multi group custom field.groups
- The groups to set.IllegalArgumentException
- if the given custom field is not a multi group field.@NotNull public static StoredEffect addCustomFieldGroups(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Group> groups)
issue
- The issue.customField
- The custom field, must be a multi group custom field.groups
- The groups to add.IllegalArgumentException
- if the given custom field is not a multi group field.@NotNull public static StoredEffect removeCustomFieldGroups(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<Group> groups)
issue
- The issue.customField
- The custom field, must be a multi group custom field.groups
- The groups to remove.IllegalArgumentException
- if the given custom field is not a multi group field.@NotNull public static StoredEffect setCustomFieldLabels(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<String> labels)
issue
- The issue.customField
- The custom field, must be a labels custom field.labels
- The labels to set.IllegalArgumentException
- if the given custom field is not a labels field.@NotNull public static StoredEffect addCustomFieldLabels(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<String> labels)
issue
- The issue.customField
- The custom field, must be a labels custom field.labels
- The labels to add.IllegalArgumentException
- if the given custom field is not a labels field.@NotNull public static StoredEffect removeCustomFieldLabels(@NotNull Issue issue, @NotNull CustomField customField, @NotNull Collection<String> labels)
issue
- The issue.customField
- The custom field, must be a labels custom field.labels
- The labels to remove.IllegalArgumentException
- if the given custom field is not a labels field.@NotNull public static StoredEffect addIssueComment(@NotNull Issue issue, @Nullable String commentBody)
issue
- The issue.commentBody
- The comment body.@NotNull public static StoredEffect deleteIssueComment(@NotNull Issue issue, @NotNull Comment comment)
issue
- The issue.comment
- The comment to be deleted.Copyright © 2024 Tempo Software. All Rights Reserved.