com.atlassian.jira.web.action.project
Class EditComponent

java.lang.Object
  extended bywebwork.action.ActionSupport
      extended bycom.atlassian.jira.action.JiraActionSupport
          extended bycom.atlassian.jira.web.action.JiraWebActionSupport
              extended bycom.atlassian.jira.web.action.ProjectActionSupport
                  extended bycom.atlassian.jira.web.action.project.AbstractProjectAction
                      extended bycom.atlassian.jira.web.action.project.ViewProject
                          extended bycom.atlassian.jira.web.action.project.EditProjectEntity
                              extended bycom.atlassian.jira.web.action.project.EditComponent
All Implemented Interfaces:
webwork.action.Action, webwork.action.CommandDriven, ErrorCollection, I18nHelper, webwork.action.IllegalArgumentAware, java.io.Serializable

public class EditComponent
extends EditProjectEntity

This class is used to edit the name of a Project Version.

See Also:
Serialized Form

Field Summary
protected  org.ofbiz.core.entity.GenericValue editedEntity
           
protected  org.ofbiz.core.entity.GenericValue existingEntity
           
 
Fields inherited from class com.atlassian.jira.web.action.project.ViewProject
pid, project
 
Fields inherited from class com.atlassian.jira.web.action.ProjectActionSupport
projectManager, savedFilters
 
Fields inherited from class com.atlassian.jira.web.action.JiraWebActionSupport
ISSUE_NOT_FOUND_RESULT, PERMISSION_VIOLATION_RESULT, request
 
Fields inherited from class com.atlassian.jira.action.JiraActionSupport
log
 
Fields inherited from class webwork.action.ActionSupport
command, errorMap, errorMessages
 
Fields inherited from interface com.atlassian.jira.util.I18nHelper
DEFAULT_RESOURCE_BUNDLE
 
Fields inherited from interface webwork.action.Action
ERROR, INPUT, LOGIN, NONE, SUCCESS
 
Constructor Summary
EditComponent()
           
 
Method Summary
 java.lang.String doDefault()
           
protected  void doValidation()
          Validates to ensure that a name field exists and that it is not a duplicate
protected  java.util.Map getBackendVariablesMap()
           
 java.lang.String getComponentLead()
           
 java.lang.String getEditAction()
           
 org.ofbiz.core.entity.GenericValue getEditedEntity()
          Returns a Component with the new Component name so that the new name can be retrieved in the case of an error or validation.
 org.ofbiz.core.entity.GenericValue getExistingEntity()
          Returns the existing Component
 java.lang.String getNiceName()
          Return the human readable name of this component.
protected  boolean isDuplicateName()
          Checks if a component in the current project already exists with the same name, apart from this component.
 void setComponentLead(java.lang.String componentLead)
           
 void setEditedEntity(org.ofbiz.core.entity.GenericValue editedEntity)
           
 
Methods inherited from class com.atlassian.jira.web.action.project.EditProjectEntity
doExecute, getId, getName, setId, setName
 
Methods inherited from class com.atlassian.jira.web.action.project.ViewProject
getFieldLayoutScheme, getFieldLayoutSchemes, getIssueSecuritySchemes, getPermissionSchemes, getPid, getProject, getProjectCategory, getProjectEmail, getRepositories, getSchemes, getStandardIssueTypes, getStringSet, getSubTaskIssueTypes, getWorkflowScheme, hasAdminPermission, hasProjectAdminPermission, isDefaultAssigneeAssignable, isHasDefaultSMTPMailServer, isProjectDefaultScheme, isSubTaskEnabled, isVersionArchived, isVersionReleased, setPid
 
Methods inherited from class com.atlassian.jira.web.action.project.AbstractProjectAction
getAssigneeType, getAssigneeTypes, getDescription, getIssueSecurityScheme, getKey, getLead, getNotificationScheme, getPermissionScheme, getPrettyAssigneeType, getUrl, setAssigneeType, setDescription, setIssueSecurityScheme, setKey, setLead, setNotificationScheme, setPermissionScheme, setUrl
 
Methods inherited from class com.atlassian.jira.web.action.ProjectActionSupport
getBrowseableProjects, getBrowseableProjectsInCategory, getSavedFilters, getSelectedProject, isEnterprise, setSelectedProject, setSelectedProjectId
 
Methods inherited from class com.atlassian.jira.web.action.JiraWebActionSupport
addErrorCollection, getAssignableUsers, getAssignableUsers, getCachedGroups, getColumnViewHtml, getComponentManager, getConstantsManager, getCustomFieldHtml, getCustomFieldXML, getDefaultAssignee, getDefaultResourceBundle, getField, getLocale, getOutlookDate, getPermissionManager, getProjectManager, getPropertySet, getRedirect, getRemoteUser, getReturnUrl, getText, getText, getText, getText, getText, getUserFullName, getUserPreferences, getVersionManager, isDefaultAssignee, isDefaultAssignee, isHasIssuePermission, isHasIssuePermission, isHasPermission, isHasPermission, isHasPermission, isHasProjectPermission, isHasProjectPermission, processDefaultAssignee, processDefaultAssignee, processDefaultAssignee, setReturnUrl
 
Methods inherited from class com.atlassian.jira.action.JiraActionSupport
addErrorMessages, addErrorMessages, addErrors, execute, getActionName, getApplicationProperties, getDelegator, getLocaleUtils, getResult, getUnescapedText, getWatcherManager, hasAnyErrors, isIndexing
 
Methods inherited from class webwork.action.ActionSupport
addError, addErrorMessage, addIllegalArgumentException, getErrorMessages, getErrors, getHasErrorMessages, getHasErrors, getPropertyEditorMessage, getTexts, getTexts, invalidInput, invokeCommand, isCommand, setCommand, setErrorMessages, setErrors, validate
 
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.util.ErrorCollection
addError, addErrorMessage, addErrorMessages, addErrors, getErrorMessages, getErrors, hasAnyErrors
 
Methods inherited from interface webwork.action.CommandDriven
setCommand
 

Field Detail

existingEntity

protected org.ofbiz.core.entity.GenericValue existingEntity

editedEntity

protected org.ofbiz.core.entity.GenericValue editedEntity
Constructor Detail

EditComponent

public EditComponent()
Method Detail

doDefault

public java.lang.String doDefault()
                           throws java.lang.Exception
Overrides:
doDefault in class ViewProject
Throws:
java.lang.Exception

doValidation

protected void doValidation()
Description copied from class: EditProjectEntity
Validates to ensure that a name field exists and that it is not a duplicate

Overrides:
doValidation in class EditProjectEntity

getBackendVariablesMap

protected java.util.Map getBackendVariablesMap()
                                        throws java.lang.Exception
Overrides:
getBackendVariablesMap in class EditProjectEntity
Throws:
java.lang.Exception

getEditedEntity

public org.ofbiz.core.entity.GenericValue getEditedEntity()
Returns a Component with the new Component name so that the new name can be retrieved in the case of an error or validation. If the name hasn't been set yet then the existing component will be returned

Specified by:
getEditedEntity in class EditProjectEntity
Returns:
Component

setEditedEntity

public void setEditedEntity(org.ofbiz.core.entity.GenericValue editedEntity)

getEditAction

public java.lang.String getEditAction()
Specified by:
getEditAction in class EditProjectEntity
Returns:
The class name of the Action to be called for editing the component

getNiceName

public java.lang.String getNiceName()
Description copied from class: EditProjectEntity
Return the human readable name of this component.

Specified by:
getNiceName in class EditProjectEntity

getExistingEntity

public org.ofbiz.core.entity.GenericValue getExistingEntity()
                                                     throws java.lang.Exception
Returns the existing Component

Specified by:
getExistingEntity in class EditProjectEntity
Returns:
Component
Throws:
java.lang.Exception

isDuplicateName

protected boolean isDuplicateName()
                           throws java.lang.Exception
Checks if a component in the current project already exists with the same name, apart from this component.

Specified by:
isDuplicateName in class EditProjectEntity
Returns:
True if a component with the same name already exists otherwise false
Throws:
java.lang.Exception

getComponentLead

public java.lang.String getComponentLead()

setComponentLead

public void setComponentLead(java.lang.String componentLead)


Copyright © 2002-2005 Atlassian. All Rights Reserved.