Package com.atlassian.jira.issue
Class GenericMutableIssueWrapper
java.lang.Object
com.atlassian.jira.issue.GenericIssueWrapper
com.atlassian.jira.issue.GenericMutableIssueWrapper
- All Implemented Interfaces:
WithId
,WithKey
,IssueContext
,Issue
,MutableIssue
,OfBizValueWrapper
,Serializable
- See Also:
-
Field Summary
Fields inherited from interface com.atlassian.jira.issue.context.IssueContext
GLOBAL
Fields inherited from interface com.atlassian.jira.entity.WithId
ID_COMPARATOR
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionRetrieve a map of issue fields whose values have been set (since object creation or lastMutableIssue.resetModifiedFields()
call.void
Reset the internal list of modified fields.void
setAffectedVersions
(Collection<Version> affectedVersions) void
setArchived
(boolean isArchived) void
setAssignee
(ApplicationUser assignee) void
setAssigneeId
(String assigneeId) Sets the user that this issue is assigned to.void
setComponent
(Collection<ProjectComponent> components) Sets the components for this Issue.void
setCreated
(Timestamp created) void
setCustomFieldValue
(CustomField customField, Object value) Sets a custom field value on this Issue Object, but does not write it to the database.void
setDescription
(String description) void
setDueDate
(Timestamp dueDate) void
setEnvironment
(String environment) void
setEstimate
(Long estimate) void
setExternalFieldValue
(String fieldId, Object newValue) This can be used by a field to "place" a custom object into the MutableIssue so that it can be retrieved by key at a later point via theMutableIssue.getModifiedFields()
andIssue.getExternalFieldValue(String)
.void
setExternalFieldValue
(String fieldId, Object oldValue, Object newValue) This can be used bya field to "place" a custom object into the MutableIssue so that it can be retrieved by key at a later point via theMutableIssue.getModifiedFields()
andIssue.getExternalFieldValue(String)
.void
setFixVersions
(Collection<Version> fixVersions) void
setIssueType
(IssueType issueType) void
setIssueTypeId
(String issueTypeId) void
setIssueTypeObject
(IssueType issueType) Sets the IssueType for this Issue.void
void
Set the labels for this issue.void
void
setOriginalEstimate
(Long estimate) void
setParentId
(Long parentId) Sets the ParentId of this Issue.void
setParentObject
(Issue parentIssue) Sets the parent Issue Object for this Issue (subtask).void
setPriority
(Priority priority) Sets the priority for this Issue.void
setPriorityId
(String priorityId) Sets the priority for this Issue.void
setPriorityObject
(Priority priority) Sets the priority for this Issue.void
setProject
(org.ofbiz.core.entity.GenericValue project) Sets the Project for this Issue.void
setProjectId
(Long projectId) Sets the project by id.void
setProjectObject
(Project project) Sets the Project for this Issue.void
setReporter
(ApplicationUser reporter) void
setReporterId
(String reporterId) Sets the reporter in this issue.void
setResolution
(Resolution resolution) Sets the resolution for this Issue.void
setResolutionDate
(Timestamp resolutionDate) void
setResolutionId
(String resolutionId) void
setResolutionObject
(Resolution resolution) Sets the resolution for this Issue.void
setSecurityLevel
(org.ofbiz.core.entity.GenericValue securityLevel) Sets the SecurityLevel for this Issue.void
setSecurityLevelId
(Long securityLevelId) Sets the SecurityLevel for this Issue.void
Sets the status for this Issue.void
setStatusId
(String statusId) Set issue's status by status id ("1", "2" etc).void
setStatusObject
(Status status) Sets the status for this Issue.void
setSummary
(String summary) void
setTimeSpent
(Long timespent) void
setUpdated
(Timestamp updated) void
void
setWatches
(Long votes) void
setWorkflowId
(Long workflowId) Methods inherited from class com.atlassian.jira.issue.GenericIssueWrapper
getAffectedVersions, getArchivedById, getArchivedByUser, getArchivedDate, getAssignee, getAssigneeId, getAssigneeUser, getAttachments, getComponentObjects, getComponents, getCreated, getCreator, getCreatorId, getCustomFieldValue, getDescription, getDueDate, getEnvironment, getEstimate, getExternalFieldValue, getFixVersions, getGenericValue, getId, getIssueRenderContext, getIssueType, getIssueTypeId, getIssueTypeObject, getKey, getLabels, getLong, getNumber, getOriginalEstimate, getParent, getParentId, getParentObject, getPriority, getPriorityObject, getProject, getProjectId, getProjectObject, getReporter, getReporterId, getReporterUser, getResolution, getResolutionDate, getResolutionId, getResolutionObject, getSecurityLevel, getSecurityLevelId, getStatus, getStatusId, getStatusObject, getString, getSubTaskObjects, getSubTasks, getSummary, getTimeSpent, getTimestamp, getUpdated, getVotes, getWatches, getWorkflowId, isArchived, isCreated, isEditable, isSubTask, store
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.jira.issue.Issue
equals, getAffectedVersions, getArchivedById, getArchivedByUser, getArchivedDate, getAssignee, getAssigneeId, getAssigneeUser, getAttachments, getComponentObjects, getComponents, getCreated, getCreator, getCreatorId, getCustomFieldValue, getDescription, getDueDate, getEnvironment, getEstimate, getExternalFieldValue, getFixVersions, getGenericValue, getId, getIssueRenderContext, getIssueType, getIssueTypeId, getIssueTypeObject, getKey, getLabels, getNumber, getOriginalEstimate, getParent, getParentId, getParentObject, getPriority, getPriorityObject, getProject, getProjectId, getProjectObject, getReporter, getReporterId, getReporterUser, getResolution, getResolutionDate, getResolutionId, getResolutionObject, getSecurityLevel, getSecurityLevelId, getStatus, getStatusId, getStatusObject, getSubTaskObjects, getSubTasks, getSummary, getTimeSpent, getUpdated, getVotes, getWatches, getWorkflowId, hashCode, isArchived, isCreated, isEditable, isSubTask
Methods inherited from interface com.atlassian.jira.issue.MutableIssue
store
Methods inherited from interface com.atlassian.jira.ofbiz.OfBizValueWrapper
getLong, getString, getTimestamp
-
Constructor Details
-
GenericMutableIssueWrapper
-
-
Method Details
-
getDelegate
- Overrides:
getDelegate
in classGenericIssueWrapper
-
setProject
public void setProject(org.ofbiz.core.entity.GenericValue project) Description copied from interface:MutableIssue
Sets the Project for this Issue.- Specified by:
setProject
in interfaceMutableIssue
- Parameters:
project
- the new Project
-
setProjectObject
Description copied from interface:MutableIssue
Sets the Project for this Issue.- Specified by:
setProjectObject
in interfaceMutableIssue
- Parameters:
project
- the new Project
-
setProjectId
Description copied from interface:MutableIssue
Sets the project by id.- Specified by:
setProjectId
in interfaceMutableIssue
- Parameters:
projectId
- The id of the project- Throws:
IllegalArgumentException
- If no project exists for the given projectId.
-
setIssueType
- Specified by:
setIssueType
in interfaceMutableIssue
-
setIssueTypeObject
Description copied from interface:MutableIssue
Sets the IssueType for this Issue.- Specified by:
setIssueTypeObject
in interfaceMutableIssue
- Parameters:
issueType
- the new IssueType
-
setIssueTypeId
- Specified by:
setIssueTypeId
in interfaceMutableIssue
-
setSummary
- Specified by:
setSummary
in interfaceMutableIssue
-
setAssignee
- Specified by:
setAssignee
in interfaceMutableIssue
-
setComponent
Description copied from interface:MutableIssue
Sets the components for this Issue.- Specified by:
setComponent
in interfaceMutableIssue
- Parameters:
components
- the new components value
-
setAssigneeId
Description copied from interface:MutableIssue
Sets the user that this issue is assigned to. Note that this should be the userkey, not the username.- Specified by:
setAssigneeId
in interfaceMutableIssue
- Parameters:
assigneeId
- The user key.
-
setReporter
- Specified by:
setReporter
in interfaceMutableIssue
-
setReporterId
Description copied from interface:MutableIssue
Sets the reporter in this issue. Note that this should be the userkey, not the username.- Specified by:
setReporterId
in interfaceMutableIssue
- Parameters:
reporterId
- userkey of the desired reporter.- See Also:
-
setDescription
- Specified by:
setDescription
in interfaceMutableIssue
-
setEnvironment
- Specified by:
setEnvironment
in interfaceMutableIssue
-
setAffectedVersions
- Specified by:
setAffectedVersions
in interfaceMutableIssue
- Parameters:
affectedVersions
- A collection of 'affects'Version
objects.
-
setFixVersions
- Specified by:
setFixVersions
in interfaceMutableIssue
- Parameters:
fixVersions
- A collection of fix-forVersion
objects.
-
setDueDate
- Specified by:
setDueDate
in interfaceMutableIssue
-
setSecurityLevelId
Description copied from interface:MutableIssue
Sets the SecurityLevel for this Issue.- Specified by:
setSecurityLevelId
in interfaceMutableIssue
- Parameters:
securityLevelId
- the new SecurityLevel value
-
setSecurityLevel
public void setSecurityLevel(org.ofbiz.core.entity.GenericValue securityLevel) Description copied from interface:MutableIssue
Sets the SecurityLevel for this Issue.- Specified by:
setSecurityLevel
in interfaceMutableIssue
- Parameters:
securityLevel
- the new SecurityLevel value
-
setPriority
Description copied from interface:MutableIssue
Sets the priority for this Issue.- Specified by:
setPriority
in interfaceMutableIssue
- Parameters:
priority
- the new priority value
-
setPriorityObject
Description copied from interface:MutableIssue
Sets the priority for this Issue.- Specified by:
setPriorityObject
in interfaceMutableIssue
- Parameters:
priority
- the new priority value
-
setPriorityId
Description copied from interface:MutableIssue
Sets the priority for this Issue.- Specified by:
setPriorityId
in interfaceMutableIssue
- Parameters:
priorityId
- the new priority value
-
setResolution
Description copied from interface:MutableIssue
Sets the resolution for this Issue.- Specified by:
setResolution
in interfaceMutableIssue
-
setResolutionObject
Description copied from interface:MutableIssue
Sets the resolution for this Issue.- Specified by:
setResolutionObject
in interfaceMutableIssue
- Parameters:
resolution
- the new resolution value
-
setKey
- Specified by:
setKey
in interfaceMutableIssue
-
setNumber
- Specified by:
setNumber
in interfaceMutableIssue
-
setVotes
- Specified by:
setVotes
in interfaceMutableIssue
-
setWatches
- Specified by:
setWatches
in interfaceMutableIssue
-
setCreated
- Specified by:
setCreated
in interfaceMutableIssue
-
setUpdated
- Specified by:
setUpdated
in interfaceMutableIssue
-
setResolutionDate
- Specified by:
setResolutionDate
in interfaceMutableIssue
-
setWorkflowId
- Specified by:
setWorkflowId
in interfaceMutableIssue
-
setCustomFieldValue
Description copied from interface:MutableIssue
Sets a custom field value on this Issue Object, but does not write it to the database. This is highly misleading.
To actually set a custom field value, useOrderableField.updateIssue(com.atlassian.jira.issue.fields.layout.field.FieldLayoutItem, MutableIssue, java.util.Map)
- Specified by:
setCustomFieldValue
in interfaceMutableIssue
- Parameters:
customField
- the CustomFieldvalue
- the value.
-
setStatus
Description copied from interface:MutableIssue
Sets the status for this Issue.- Specified by:
setStatus
in interfaceMutableIssue
- Parameters:
status
- the new status value
-
setStatusObject
Description copied from interface:MutableIssue
Sets the status for this Issue.- Specified by:
setStatusObject
in interfaceMutableIssue
- Parameters:
status
- the new status value
-
setStatusId
Description copied from interface:MutableIssue
Set issue's status by status id ("1", "2" etc).- Specified by:
setStatusId
in interfaceMutableIssue
- Parameters:
statusId
- the new StatusId.
-
resetModifiedFields
public void resetModifiedFields()Description copied from interface:MutableIssue
Reset the internal list of modified fields.- Specified by:
resetModifiedFields
in interfaceMutableIssue
- See Also:
-
setOriginalEstimate
- Specified by:
setOriginalEstimate
in interfaceMutableIssue
-
setTimeSpent
- Specified by:
setTimeSpent
in interfaceMutableIssue
-
setEstimate
- Specified by:
setEstimate
in interfaceMutableIssue
-
setExternalFieldValue
Description copied from interface:MutableIssue
This can be used by a field to "place" a custom object into the MutableIssue so that it can be retrieved by key at a later point via theMutableIssue.getModifiedFields()
andIssue.getExternalFieldValue(String)
.The passed in newValue will be wrapped in the
ModifiedValue.getNewValue()
TheModifiedValue.getOldValue()
will be null.- Specified by:
setExternalFieldValue
in interfaceMutableIssue
- Parameters:
fieldId
- the field id to use as a keynewValue
- the new value to place in aModifiedValue
-
setExternalFieldValue
Description copied from interface:MutableIssue
This can be used bya field to "place" a custom object into the MutableIssue so that it can be retrieved by key at a later point via theMutableIssue.getModifiedFields()
andIssue.getExternalFieldValue(String)
.The passed in newValue will be wrapped in the
ModifiedValue.getNewValue()
and the oldValue will be placed inModifiedValue.getOldValue()
- Specified by:
setExternalFieldValue
in interfaceMutableIssue
- Parameters:
fieldId
- the field id to use as a keyoldValue
- the old value to place in aModifiedValue
newValue
- the new value to place in aModifiedValue
-
setParentId
Description copied from interface:MutableIssue
Sets the ParentId of this Issue.- Specified by:
setParentId
in interfaceMutableIssue
- Parameters:
parentId
- The new parentId.- See Also:
-
setParentObject
Description copied from interface:MutableIssue
Sets the parent Issue Object for this Issue (subtask).Normally a subtask just has the ID of the parent set using
setParentId()
. In this case, the getParentObject() method will look up the parent object from the DB (or cache). However, when you are editing a parent and its subtask within a transaction (eg a Bulk Move), it is useful to be able to link the subtask to the pending parent object in order that it can see the new values for the parent.- Specified by:
setParentObject
in interfaceMutableIssue
- Parameters:
parentIssue
- the required parent Issue for this subtask.- See Also:
-
setResolutionId
- Specified by:
setResolutionId
in interfaceMutableIssue
-
setArchived
public void setArchived(boolean isArchived) - Specified by:
setArchived
in interfaceMutableIssue
-
setLabels
Description copied from interface:MutableIssue
Set the labels for this issue.- Specified by:
setLabels
in interfaceMutableIssue
- Parameters:
labels
- the labels for this issue
-
getModifiedFields
Description copied from interface:MutableIssue
Retrieve a map of issue fields whose values have been set (since object creation or lastMutableIssue.resetModifiedFields()
call.- Specified by:
getModifiedFields
in interfaceMutableIssue
- Returns:
- A Map of key -> ModifiedValue pairs, where keys are defined in
IssueFieldConstants
and the value objects in the ModifiedValue are field-specific.
-