com.atlassian.jira.issue
Class IssueInputParametersImpl

java.lang.Object
  extended by com.atlassian.jira.issue.IssueInputParametersImpl
All Implemented Interfaces:
IssueInputParameters

public class IssueInputParametersImpl
extends Object
implements IssueInputParameters

Default implementation of IssueInputParameters.

Plugin developers should call IssueService.newIssueInputParameters() or IssueService.newIssueInputParameters(java.util.Map).

Since:
v4.1

Constructor Summary
IssueInputParametersImpl()
           
IssueInputParametersImpl(Map<String,String[]> actionParameters)
          Can be used to quickly convert some "web-style" parameters (which can be the result of a form submit with the fields rendered create/edit html) to an IssueInputParameters object.
 
Method Summary
 IssueInputParameters addCustomFieldValue(Long customFieldId, String... values)
          Adds a value for a custom field with the specified id.
 IssueInputParameters addCustomFieldValue(String fullCustomFieldKey, String... values)
          Adds a value for a custom field with the specified full key.
 boolean applyDefaultValuesWhenParameterNotProvided()
           
 Map<String,String[]> getActionParameters()
          This provides the "web-style" parameters that JIRA fields expect to perform their functions.
 Long[] getAffectedVersionIds()
           
 String getAssigneeId()
           
 String getCommentValue()
           
 Long[] getComponentIds()
           
 String[] getCustomFieldValue(Long customFieldId)
           
 String[] getCustomFieldValue(String fullCustomFieldKey)
           
 String getDescription()
           
 String getDueDate()
           
 String getEnvironment()
           
 Map<String,Object> getFieldValuesHolder()
           
 Long[] getFixVersionIds()
           
 String getIssueTypeId()
           
 Long getOriginalEstimate()
          Gets the original estimate set.
 String getOriginalEstimateAsDurationString()
          Gets the original estimate set.
 String getPriorityId()
           
 Long getProjectId()
           
 Collection<String> getProvidedFields()
           
 Long getRemainingEstimate()
          Gets the remaining estimate set.
 String getRemainingEstimateAsDurationString()
          Gets the remaining estimate provided If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this will return the same as IssueInputParameters.getOriginalEstimateAsDurationString().
 String getReporterId()
           
 String getResolutionDate()
           
 String getResolutionId()
           
 Long getSecurityLevelId()
           
 String getStatusId()
           
 String getSummary()
           
 Long getTimeSpent()
           
 boolean isFieldPresent(String fieldId)
           
 boolean isFieldSet(String fieldId)
           
 boolean retainExistingValuesWhenParameterNotProvided()
           
 IssueInputParameters setAffectedVersionIds(Long... affectedVersionIds)
           
 void setApplyDefaultValuesWhenParameterNotProvided(boolean applyDefaultValuesWhenParameterNotProvided)
           
 IssueInputParameters setAssigneeId(String assigneeId)
           
 IssueInputParameters setComment(String comment)
          Set a comment value with no visibility restrictions.
 IssueInputParameters setComment(String comment, Long projectRoleId)
          Set a comment value with a project role restriction.
 IssueInputParameters setComment(String comment, String groupId)
          Set a comment value with a group restriction.
 IssueInputParameters setComponentIds(Long... componentIds)
           
 IssueInputParameters setDescription(String description)
           
 IssueInputParameters setDueDate(String dueDate)
           
 IssueInputParameters setEnvironment(String environment)
           
 void setFieldValuesHolder(Map<String,Object> fieldValuesHolder)
          If set the validation will use the seed values from this field values holder.
 IssueInputParameters setFixVersionIds(Long... fixVersionIds)
           
 IssueInputParameters setIssueTypeId(String issueTypeId)
           
 IssueInputParameters setOriginalAndRemainingEstimate(Long originalEstimate, Long remainingEstimate)
          Sets both the original and remaining estimate on the issue.
 IssueInputParameters setOriginalAndRemainingEstimate(String originalEstimate, String remainingEstimate)
          Sets both the original and remaining estimate on the issue.
 IssueInputParameters setOriginalEstimate(Long originalEstimate)
          Sets the original estimate on the issue.
 IssueInputParameters setOriginalEstimate(String originalEstimate)
          Sets the original estimate on the issue.
 IssueInputParameters setPriorityId(String priorityId)
           
 IssueInputParameters setProjectId(Long projectId)
           
 void setProvidedFields(Collection<String> providedFields)
          Use this to indicate which fields validation should be performed on, if left alone then the systems configured fields for either create/update will be used.
 IssueInputParameters setRemainingEstimate(Long remainingEstimate)
          Sets the remaining estimate on the issue If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method behaves differently.
 IssueInputParameters setRemainingEstimate(String remainingEstimate)
          Sets the remaining estimate on the issue If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method behaves differently.
 IssueInputParameters setReporterId(String reporterId)
           
 IssueInputParameters setResolutionDate(String resolutionDate)
           
 IssueInputParameters setResolutionId(String resolutionId)
           
 void setRetainExistingValuesWhenParameterNotProvided(boolean retain)
           
 IssueInputParameters setSecurityLevelId(Long securityLevelId)
           
 void setSkipScreenCheck(boolean skipScreenCheck)
          Set the flag to skip screen checks during update.
 IssueInputParameters setStatusId(String statusId)
           
 IssueInputParameters setSummary(String summary)
           
 IssueInputParameters setTimeSpent(Long timeSpent)
           
 boolean skipScreenCheck()
          Get the flag to skip screen checks during update.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IssueInputParametersImpl

public IssueInputParametersImpl()

IssueInputParametersImpl

public IssueInputParametersImpl(Map<String,String[]> actionParameters)
Can be used to quickly convert some "web-style" parameters (which can be the result of a form submit with the fields rendered create/edit html) to an IssueInputParameters object.

Parameters:
actionParameters - provides the default starting values for this object.
Method Detail

setProjectId

public IssueInputParameters setProjectId(Long projectId)
Specified by:
setProjectId in interface IssueInputParameters
Parameters:
projectId - sets the project id for the issue.
Returns:
this object.

getProjectId

public Long getProjectId()
Specified by:
getProjectId in interface IssueInputParameters
Returns:
the set project id, null if one does not exist or if it is not a valid number.

setIssueTypeId

public IssueInputParameters setIssueTypeId(String issueTypeId)
Specified by:
setIssueTypeId in interface IssueInputParameters
Parameters:
issueTypeId - sets the issue type for the issue.
Returns:
this object.

getIssueTypeId

public String getIssueTypeId()
Specified by:
getIssueTypeId in interface IssueInputParameters
Returns:
the set issue type id, null if one does not exist.

setPriorityId

public IssueInputParameters setPriorityId(String priorityId)
Specified by:
setPriorityId in interface IssueInputParameters
Parameters:
priorityId - sets the priority for the issue.
Returns:
this object.

getPriorityId

public String getPriorityId()
Specified by:
getPriorityId in interface IssueInputParameters
Returns:
the set priority id, null if one does not exist.

setResolutionId

public IssueInputParameters setResolutionId(String resolutionId)
Specified by:
setResolutionId in interface IssueInputParameters
Parameters:
resolutionId - sets the resolution for the issue.
Returns:
this object.

getResolutionId

public String getResolutionId()
Specified by:
getResolutionId in interface IssueInputParameters
Returns:
the set resolution id, null if one does not exist.

setStatusId

public IssueInputParameters setStatusId(String statusId)
Specified by:
setStatusId in interface IssueInputParameters
Parameters:
statusId - sets the status of the issue.
Returns:
this object.

getStatusId

public String getStatusId()
Specified by:
getStatusId in interface IssueInputParameters
Returns:
the set status id, null if one does not exist.

setSummary

public IssueInputParameters setSummary(String summary)
Specified by:
setSummary in interface IssueInputParameters
Parameters:
summary - sets the summary for the issue.
Returns:
this object.

getSummary

public String getSummary()
Specified by:
getSummary in interface IssueInputParameters
Returns:
the set summary, null if one does not exist.

setDescription

public IssueInputParameters setDescription(String description)
Specified by:
setDescription in interface IssueInputParameters
Parameters:
description - sets the description for the issue.
Returns:
this object.

getDescription

public String getDescription()
Specified by:
getDescription in interface IssueInputParameters
Returns:
the set description, null if one does not exist.

setEnvironment

public IssueInputParameters setEnvironment(String environment)
Specified by:
setEnvironment in interface IssueInputParameters
Parameters:
environment - sets the environment of the issue.
Returns:
this object.

getEnvironment

public String getEnvironment()
Specified by:
getEnvironment in interface IssueInputParameters
Returns:
the set environment, null if one does not exist.

setAssigneeId

public IssueInputParameters setAssigneeId(String assigneeId)
Specified by:
setAssigneeId in interface IssueInputParameters
Parameters:
assigneeId - sets the assignee id for the issue.
Returns:
this object.

getAssigneeId

public String getAssigneeId()
Specified by:
getAssigneeId in interface IssueInputParameters
Returns:
the set assginee, null if one does not exist.

setReporterId

public IssueInputParameters setReporterId(String reporterId)
Specified by:
setReporterId in interface IssueInputParameters
Parameters:
reporterId - sets the reporter id for the issue.
Returns:
this object.

getReporterId

public String getReporterId()
Specified by:
getReporterId in interface IssueInputParameters
Returns:
the set reporter, null if one does not exist.

setComponentIds

public IssueInputParameters setComponentIds(Long... componentIds)
Specified by:
setComponentIds in interface IssueInputParameters
Parameters:
componentIds - sets the components id's on the issue.
Returns:
this object.

getComponentIds

public Long[] getComponentIds()
Specified by:
getComponentIds in interface IssueInputParameters
Returns:
the set component id's, null if they do not exist or if they are not valid numbers.

setFixVersionIds

public IssueInputParameters setFixVersionIds(Long... fixVersionIds)
Specified by:
setFixVersionIds in interface IssueInputParameters
Parameters:
fixVersionIds - sets the fix version id's on the issue.
Returns:
this object.

getFixVersionIds

public Long[] getFixVersionIds()
Specified by:
getFixVersionIds in interface IssueInputParameters
Returns:
the set fix version id's, null if they do not exist or if they are not valid numbers.

setAffectedVersionIds

public IssueInputParameters setAffectedVersionIds(Long... affectedVersionIds)
Specified by:
setAffectedVersionIds in interface IssueInputParameters
Parameters:
affectedVersionIds - sets the affected version id's= on the issue.
Returns:
this object.

getAffectedVersionIds

public Long[] getAffectedVersionIds()
Specified by:
getAffectedVersionIds in interface IssueInputParameters
Returns:
the set affected version id's, null if they do not exist or if they are not valid numbers.

setDueDate

public IssueInputParameters setDueDate(String dueDate)
Specified by:
setDueDate in interface IssueInputParameters
Parameters:
dueDate - the formatted string that JIRA will accept as a date that will be set on the issue.
Returns:
this object.

getDueDate

public String getDueDate()
Specified by:
getDueDate in interface IssueInputParameters
Returns:
the set due date, null if one does not exist.

setResolutionDate

public IssueInputParameters setResolutionDate(String resolutionDate)
Specified by:
setResolutionDate in interface IssueInputParameters
Parameters:
resolutionDate - the formatted string that JIRA will accept as a date that will be set on the issue.
Returns:
this object.

getResolutionDate

public String getResolutionDate()
Specified by:
getResolutionDate in interface IssueInputParameters
Returns:
the set resolution date, null if one does not exist.

setSecurityLevelId

public IssueInputParameters setSecurityLevelId(Long securityLevelId)
Specified by:
setSecurityLevelId in interface IssueInputParameters
Parameters:
securityLevelId - sets the security level id on the issue.
Returns:
this object.

getSecurityLevelId

public Long getSecurityLevelId()
Specified by:
getSecurityLevelId in interface IssueInputParameters
Returns:
the set security level id, null if one does not exist or it is not a valid number.

setOriginalEstimate

public IssueInputParameters setOriginalEstimate(Long originalEstimate)
Description copied from interface: IssueInputParameters
Sets the original estimate on the issue. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method behaves differently. See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
setOriginalEstimate in interface IssueInputParameters
Parameters:
originalEstimate - the new original estimate on the issue. The units used are determined by APKeys.JIRA_TIMETRACKING_DEFAULT_UNIT.
Returns:
this object.

setOriginalEstimate

public IssueInputParameters setOriginalEstimate(String originalEstimate)
Description copied from interface: IssueInputParameters
Sets the original estimate on the issue. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method behaves differently. See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
setOriginalEstimate in interface IssueInputParameters
Parameters:
originalEstimate - the new original estimate on the issue, e.g. "1d 5h" for 1 day and 5 hours
Returns:
this object.

setRemainingEstimate

public IssueInputParameters setRemainingEstimate(Long remainingEstimate)
Description copied from interface: IssueInputParameters
Sets the remaining estimate on the issue If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method behaves differently. See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
setRemainingEstimate in interface IssueInputParameters
Parameters:
remainingEstimate - the remaining estimate on the issue. The units used are determined by APKeys.JIRA_TIMETRACKING_DEFAULT_UNIT.
Returns:
this object

setRemainingEstimate

public IssueInputParameters setRemainingEstimate(String remainingEstimate)
Description copied from interface: IssueInputParameters
Sets the remaining estimate on the issue If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method behaves differently. See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
setRemainingEstimate in interface IssueInputParameters
Parameters:
remainingEstimate - the remaining estimate on the issue, e.g. "1d 5h" for 1 day and 5 hours
Returns:
this object

setOriginalAndRemainingEstimate

public IssueInputParameters setOriginalAndRemainingEstimate(String originalEstimate,
                                                            String remainingEstimate)
Description copied from interface: IssueInputParameters
Sets both the original and remaining estimate on the issue. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method has no effect. See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
setOriginalAndRemainingEstimate in interface IssueInputParameters
Parameters:
originalEstimate - the new original estimate, e.g. "1d 5h" for 1 day and 5 hours
remainingEstimate - the new remaining estimate, e.g. "1d 5h" for 1 day and 5 hours
Returns:
this object

setOriginalAndRemainingEstimate

public IssueInputParameters setOriginalAndRemainingEstimate(Long originalEstimate,
                                                            Long remainingEstimate)
Description copied from interface: IssueInputParameters
Sets both the original and remaining estimate on the issue. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this method has no effect. See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
setOriginalAndRemainingEstimate in interface IssueInputParameters
Parameters:
originalEstimate - the new original estimate. The units used are determined by APKeys.JIRA_TIMETRACKING_DEFAULT_UNIT.
remainingEstimate - the new remaining estimate.The units used are determined by APKeys.JIRA_TIMETRACKING_DEFAULT_UNIT.
Returns:
this object

getOriginalEstimate

public Long getOriginalEstimate()
Description copied from interface: IssueInputParameters
Gets the original estimate set. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this will return the same as IssueInputParameters.getRemainingEstimate(). See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
getOriginalEstimate in interface IssueInputParameters
Returns:
the set original estimate, null if one does not exist or it is not a valid number.

getRemainingEstimate

public Long getRemainingEstimate()
Description copied from interface: IssueInputParameters
Gets the remaining estimate set. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this will return the same as IssueInputParameters.getOriginalEstimate() . See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
getRemainingEstimate in interface IssueInputParameters
Returns:
the set remaining estimate, null if one does not exist or it is not a valid number.

getRemainingEstimateAsDurationString

public String getRemainingEstimateAsDurationString()
Description copied from interface: IssueInputParameters
Gets the remaining estimate provided If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this will return the same as IssueInputParameters.getOriginalEstimateAsDurationString(). See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
getRemainingEstimateAsDurationString in interface IssueInputParameters
Returns:
the set remaining estimate, null if one does not exist.

getOriginalEstimateAsDurationString

public String getOriginalEstimateAsDurationString()
Description copied from interface: IssueInputParameters
Gets the original estimate set. If (APKeys.JIRA_OPTION_TIMETRACKING_ESTIMATES_LEGACY_BEHAVIOUR is set, we are in legacy time tracking mode and this will return the same as IssueInputParameters.getRemainingEstimateAsDurationString(). See http://confluence.atlassian.com/display/JIRA044/Configuring+Time+Tracking#ConfiguringTimeTracking-legacymode for more information on legacy mode.

Specified by:
getOriginalEstimateAsDurationString in interface IssueInputParameters
Returns:
the set original estimate, null if one does not exist.

setTimeSpent

public IssueInputParameters setTimeSpent(Long timeSpent)
Specified by:
setTimeSpent in interface IssueInputParameters
Parameters:
timeSpent - sets the time spent on the issue.
Returns:
this object.

getTimeSpent

public Long getTimeSpent()
Specified by:
getTimeSpent in interface IssueInputParameters
Returns:
the set time spent, null if one does not exist or it is not a valid number.

addCustomFieldValue

public IssueInputParameters addCustomFieldValue(Long customFieldId,
                                                String... values)
Description copied from interface: IssueInputParameters
Adds a value for a custom field with the specified id. This will put a value in the web-style parameters with a key of the form "customfield_PROVIDED_ID". If you want to specify the key then use the method IssueInputParameters.addCustomFieldValue(String, String...).

Specified by:
addCustomFieldValue in interface IssueInputParameters
Parameters:
customFieldId - the unique identifier of the custom field.
values - the custom field values, must be in the format the field expects.
Returns:
this object.

addCustomFieldValue

public IssueInputParameters addCustomFieldValue(String fullCustomFieldKey,
                                                String... values)
Description copied from interface: IssueInputParameters
Adds a value for a custom field with the specified full key. This will put a value in the web-style parameters with a key as provided.

Specified by:
addCustomFieldValue in interface IssueInputParameters
Parameters:
fullCustomFieldKey - used in the "web-style" parameters as the key, the custom field should expect this value as the key in its populate from parameters method.
values - the custom field values, must be in the format the field expects.
Returns:
this object.

retainExistingValuesWhenParameterNotProvided

public boolean retainExistingValuesWhenParameterNotProvided()
Specified by:
retainExistingValuesWhenParameterNotProvided in interface IssueInputParameters
Returns:
true if the issues value should be retained when a parameter has not been provided, false if the missing parameter should be treated as an update.

setRetainExistingValuesWhenParameterNotProvided

public void setRetainExistingValuesWhenParameterNotProvided(boolean retain)
Specified by:
setRetainExistingValuesWhenParameterNotProvided in interface IssueInputParameters
Parameters:
retain - true if non-provided parameters should have the values retained, false otherwise.
See Also:
IssueInputParameters.retainExistingValuesWhenParameterNotProvided()

applyDefaultValuesWhenParameterNotProvided

public boolean applyDefaultValuesWhenParameterNotProvided()
Specified by:
applyDefaultValuesWhenParameterNotProvided in interface IssueInputParameters
Returns:
true if default value should be supplied when a parameter has not been provided. false if the default value should not be applied.

setApplyDefaultValuesWhenParameterNotProvided

public void setApplyDefaultValuesWhenParameterNotProvided(boolean applyDefaultValuesWhenParameterNotProvided)
Specified by:
setApplyDefaultValuesWhenParameterNotProvided in interface IssueInputParameters
Parameters:
applyDefaultValuesWhenParameterNotProvided - true if default value should be supplied when a parameter has not been provided. false if the default value should not be applied.

skipScreenCheck

public boolean skipScreenCheck()
Description copied from interface: IssueInputParameters
Get the flag to skip screen checks during update.

By default, the Issue Service only allows updates to fields which appear on the screen of the operation which you are performing (e.g. the Edit screen). By enabling this flag, the Issue Service will skip this check.

Specified by:
skipScreenCheck in interface IssueInputParameters
Returns:
whether or not we are skipping screen check
See Also:
IssueService.validateUpdate(com.atlassian.crowd.embedded.api.User, Long, IssueInputParameters)

setSkipScreenCheck

public void setSkipScreenCheck(boolean skipScreenCheck)
Description copied from interface: IssueInputParameters
Set the flag to skip screen checks during update.

By default, the Issue Service only allows updates to fields which appear on the screen of the operation which you are performing (e.g. the Edit screen). By enabling this flag, the Issue Service will skip this check.

Specified by:
setSkipScreenCheck in interface IssueInputParameters
Parameters:
skipScreenCheck - whether or not we are skipping screen check
See Also:
IssueService.validateUpdate(com.atlassian.crowd.embedded.api.User, Long, IssueInputParameters)

getCustomFieldValue

public String[] getCustomFieldValue(Long customFieldId)
Specified by:
getCustomFieldValue in interface IssueInputParameters
Parameters:
customFieldId - uniquely identifies the custom field value you are looking for.
Returns:
the values for the provided custom field if they exist, null otherwise.

getCustomFieldValue

public String[] getCustomFieldValue(String fullCustomFieldKey)
Specified by:
getCustomFieldValue in interface IssueInputParameters
Parameters:
fullCustomFieldKey - identifies the custom field values you are looking for.
Returns:
the values for the provided custom field if they exist, null otherwise.

getCommentValue

public String getCommentValue()
Specified by:
getCommentValue in interface IssueInputParameters
Returns:
the comment string value if it has been set, null otherwise.

setComment

public IssueInputParameters setComment(String comment)
Description copied from interface: IssueInputParameters
Set a comment value with no visibility restrictions.

Specified by:
setComment in interface IssueInputParameters
Parameters:
comment - the comment value.
Returns:
this object.

setComment

public IssueInputParameters setComment(String comment,
                                       Long projectRoleId)
Description copied from interface: IssueInputParameters
Set a comment value with a project role restriction.

Specified by:
setComment in interface IssueInputParameters
Parameters:
comment - the comment value.
projectRoleId - the id of the project role the comment must be restricted by.
Returns:
this object.

setComment

public IssueInputParameters setComment(String comment,
                                       String groupId)
Description copied from interface: IssueInputParameters
Set a comment value with a group restriction.

Specified by:
setComment in interface IssueInputParameters
Parameters:
comment - the comment value.
groupId - the group name that the comment must be restricted by.
Returns:
this object.

getActionParameters

public Map<String,String[]> getActionParameters()
Description copied from interface: IssueInputParameters
This provides the "web-style" parameters that JIRA fields expect to perform their functions.

Specified by:
getActionParameters in interface IssueInputParameters
Returns:
this is a raw map of "web" style input parameters. These parameters are used to allow the fields to attain the user inputted values. This map is of the style: <field_name> <String [] {value}>.

setFieldValuesHolder

public void setFieldValuesHolder(Map<String,Object> fieldValuesHolder)
Description copied from interface: IssueInputParameters
If set the validation will use the seed values from this field values holder.

Specified by:
setFieldValuesHolder in interface IssueInputParameters
Parameters:
fieldValuesHolder - provides the seed values for the field values holder.

getFieldValuesHolder

public Map<String,Object> getFieldValuesHolder()
Specified by:
getFieldValuesHolder in interface IssueInputParameters
Returns:
the provided field values holder or an empty map, never null.

getProvidedFields

public Collection<String> getProvidedFields()
Specified by:
getProvidedFields in interface IssueInputParameters
Returns:
the field id's that should be validated, null if not specified.

setProvidedFields

public void setProvidedFields(Collection<String> providedFields)
Description copied from interface: IssueInputParameters
Use this to indicate which fields validation should be performed on, if left alone then the systems configured fields for either create/update will be used.

Specified by:
setProvidedFields in interface IssueInputParameters
Parameters:
providedFields - a collection of Field.getId()'s which identify the fields.

isFieldSet

public boolean isFieldSet(String fieldId)
Specified by:
isFieldSet in interface IssueInputParameters
Parameters:
fieldId - identifies the field in question, this will be the Field.getId().
Returns:
true if a non-null, non-empty value has been set for the field, false if not.

isFieldPresent

public boolean isFieldPresent(String fieldId)
Specified by:
isFieldPresent in interface IssueInputParameters
Parameters:
fieldId - identifies the field in question, this will be the Field.getId().
Returns:
true if the field has been set, even with an empty value, false if not.


Copyright © 2002-2012 Atlassian. All Rights Reserved.