com.atlassian.jira.web.action.issue
Class AttachScreenshot

java.lang.Object
  extended by webwork.action.ActionSupport
      extended by com.atlassian.jira.action.JiraActionSupport
          extended by com.atlassian.jira.web.action.JiraWebActionSupport
              extended by com.atlassian.jira.web.action.ProjectActionSupport
                  extended by com.atlassian.jira.web.action.IssueActionSupport
                      extended by com.atlassian.jira.web.action.issue.AbstractIssueSelectAction
                          extended by com.atlassian.jira.web.action.issue.AbstractViewIssue
                              extended by com.atlassian.jira.web.action.issue.AbstractCommentableIssue
                                  extended by com.atlassian.jira.web.action.issue.AttachScreenshot
All Implemented Interfaces:
OperationContext, ErrorCollection, I18nHelper, IssueSummaryAware, AuthorizationSupport, Serializable, webwork.action.Action, webwork.action.CommandDriven, webwork.action.IllegalArgumentAware

public class AttachScreenshot
extends AbstractCommentableIssue
implements OperationContext

Webwork action for popping up the attach screenshot applet and attaching screenshots to an issue.

Since:
v4.2
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface com.atlassian.jira.util.ErrorCollection
ErrorCollection.Reason
 
Nested classes/interfaces inherited from interface com.atlassian.jira.util.I18nHelper
I18nHelper.BeanFactory
 
Field Summary
 
Fields inherited from class com.atlassian.jira.web.action.issue.AbstractCommentableIssue
userUtil
 
Fields inherited from class com.atlassian.jira.web.action.issue.AbstractIssueSelectAction
id, ISSUE_PERMISSION_ERROR, PREPOPULATED_ISSUE_OBJECT
 
Fields inherited from class com.atlassian.jira.web.action.IssueActionSupport
attachmentManager
 
Fields inherited from class com.atlassian.jira.web.action.ProjectActionSupport
projectManager
 
Fields inherited from class com.atlassian.jira.web.action.JiraWebActionSupport
ISSUE_NOT_FOUND_RESULT, PERMISSION_VIOLATION_RESULT, request, RETURN_URL_PARAMETER, savedFilters
 
Fields inherited from class com.atlassian.jira.action.JiraActionSupport
log
 
Fields inherited from class webwork.action.ActionSupport
command, errorMap, errorMessages
 
Fields inherited from interface webwork.action.Action
ERROR, INPUT, LOGIN, NONE, SUCCESS
 
Constructor Summary
AttachScreenshot(SubTaskManager subTaskManager, FieldScreenRendererFactory fieldScreenRendererFactory, FieldManager fieldManager, ProjectRoleManager projectRoleManager, CommentService commentService, WebAttachmentManager webAttachmentManager, IssueUpdater issueUpdater, AttachmentService attachmentService, SecureUserTokenManager secureUserTokenManager, JiraAuthenticationContext authenticationContext, UserUtil userUtil)
           
 
Method Summary
 String doDefault()
           
protected  String doExecute()
           
protected  void doValidation()
           
 String encode(String text)
           
 String getAfterUrl()
           
 Map<String,Object> getDisplayParams()
           
 com.atlassian.crowd.embedded.api.User getLoggedInUser()
           
 String getNewUserToken()
           
 String getNextScreenshotName()
           
 int getNextScreenshotNumber()
           
 String getSecureToken()
           
 boolean isAbleToAttach()
           
 void setSecureToken(String secureToken)
           
 
Methods inherited from class com.atlassian.jira.web.action.issue.AbstractCommentableIssue
createComment, doCommentValidation, getComment, getCommentLevel, getFieldScreenRendererLayoutItemForField, getFieldScreenRendererWithAllFields, getFieldValuesHolder, getGroupLevel, getGroupLevels, getIssueOperation, getOrderableField, getRoleLevels, populateCommentFields, setComment, setCommentLevel, setFieldValuesHolder, setGroupLevel
 
Methods inherited from class com.atlassian.jira.web.action.issue.AbstractViewIssue
getAttachments, getPossibleComponents, getPossibleVersions, getPossibleVersionsReleasedFirst
 
Methods inherited from class com.atlassian.jira.web.action.issue.AbstractIssueSelectAction
addErrorMessage, assertIssueIsValid, cameFromIssue, cameFromParent, getId, getIssue, getIssueObject, getIssueObjectNoSecurityCheck, getIssueObjectWithoutDatabaseRead, getIssuePath, getKey, getLayoutBean, getParentIssueObject, getProject, getSecurityLevel, getSubTaskManager, getSummaryIssue, getViewIssueKey, getViewUrl, isEditable, isEditable, isHasEditIssuePermission, isIssueExists, isIssueValid, isSubTask, isSubTaskCreatable, isWorkflowAllowsEdit, redirectToView, refreshIssueObject, setId, setIssueObject, setKey, setViewIssueKey
 
Methods inherited from class com.atlassian.jira.web.action.IssueActionSupport
addIssueToHistory, clearSelectedIssue, getAttachmentManager, getCurrentFailedLoginCount, getCurrentJQL, getCustomFieldManager, getDaysPerWeek, getEverLoggedIn, getHoursPerDay, getIssueManager, getLastFailedLogin, getLastLogin, getLoginCount, getPossibleVersions, getPossibleVersionsReleasedFirst, getPrettyDuration, getPreviousLogin, getSearchRequest, getSelectedIssueId, getSessionPagerFilterManager, getSessionSearchRequestManager, getSessionSearchRequestManagerFactory, getSessionSelectedIssueManager, getTotalFailedLoginCount, getUrlEncoded, getWorkflow, getWorkflowTransitionDescription, getWorkflowTransitionDisplayName, isCustomFieldHidden, isElevatedSecurityCheckRequired, isFieldHidden, isFieldHidden, isTimeTrackingEnabled, setSearchRequest, setSelectedIssueId, updateSearchRequest
 
Methods inherited from class com.atlassian.jira.web.action.ProjectActionSupport
getBrowsableProjects, getBrowseableProjects, getSelectedProjectId, setSelectedProject, setSelectedProject
 
Methods inherited from class com.atlassian.jira.web.action.JiraWebActionSupport
addError, addErrorCollection, addErrorMessage, addErrorMessageByKeyIfAbsent, addErrorMessageIfAbsent, addReason, addReasons, forceRedirect, getAdministratorContactLink, getApplicationProperties, getConglomerateCookieValue, getConstantsManager, getDateFormat, getDateTimeFormat, getDateTimeFormatter, getDescTranslation, getDmyDateFormatter, getField, getFlushedErrorMessages, getGlobalPermissionManager, getHint, getHintManager, getJiraContactHelper, getJiraServiceContext, getLanguage, getNameTranslation, getOutlookDate, getPermissionManager, getProjectManager, getRandomHint, getReasons, getRedirect, getRedirectChecker, getReturnUrl, getReturnUrlForCancelLink, getSearchSortDescriptions, getSelectedProject, getSelectedProjectObject, getServerId, getTimeFormat, getUriValidator, getUserFullName, getUserManager, getUserProjectHistoryManager, getVersionManager, getWebworkStack, getWebworkStack, getXsrfToken, hasErrorMessage, hasErrorMessageByKey, htmlEncode, insertContextPath, isHasIssuePermission, isHasIssuePermission, isHasPermission, isHasPermission, isHasPermission, isHasProjectPermission, isHasProjectPermission, isInlineDialogMode, isSystemAdministrator, isUserExists, returnComplete, returnComplete, returnCompleteWithInlineRedirect, returnCompleteWithInlineRedirectAndMsg, setConglomerateCookieValue, setInline, setReasons, setReturnUrl, setSelectedProjectId
 
Methods inherited from class com.atlassian.jira.action.JiraActionSupport
addErrorMessages, addErrorMessages, addErrors, addIllegalArgumentException, execute, getActionName, getComponentInstanceOfType, getDefaultResourceBundle, getDelegator, getI18nHelper, getKeysForPrefix, getLocale, getOfBizDelegator, getRemoteUser, getResult, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getUnescapedText, getUserPreferences, getWatcherManager, hasAnyErrors, isIndexing, removeKeyOrAddError
 
Methods inherited from class webwork.action.ActionSupport
addError, getCommandName, getErrorMessages, getErrors, getHasErrorMessages, getHasErrors, getPropertyEditorMessage, getTexts, getTexts, getTimezone, 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.issue.customfields.OperationContext
getFieldValuesHolder, getIssueOperation
 
Methods inherited from interface com.atlassian.jira.util.ErrorCollection
addError, addErrorMessages, addErrors, getErrorMessages, getErrors, hasAnyErrors, setErrorMessages
 
Methods inherited from interface webwork.action.CommandDriven
getCommandName, setCommand
 

Constructor Detail

AttachScreenshot

public AttachScreenshot(SubTaskManager subTaskManager,
                        FieldScreenRendererFactory fieldScreenRendererFactory,
                        FieldManager fieldManager,
                        ProjectRoleManager projectRoleManager,
                        CommentService commentService,
                        WebAttachmentManager webAttachmentManager,
                        IssueUpdater issueUpdater,
                        AttachmentService attachmentService,
                        SecureUserTokenManager secureUserTokenManager,
                        JiraAuthenticationContext authenticationContext,
                        UserUtil userUtil)
Method Detail

doDefault

public String doDefault()
                 throws Exception
Overrides:
doDefault in class webwork.action.ActionSupport
Throws:
Exception

doValidation

protected void doValidation()
Overrides:
doValidation in class AbstractCommentableIssue

doExecute

protected String doExecute()
                    throws Exception
Overrides:
doExecute in class webwork.action.ActionSupport
Throws:
Exception

getAfterUrl

public String getAfterUrl()

isAbleToAttach

public boolean isAbleToAttach()

encode

public String encode(String text)

getNextScreenshotName

public String getNextScreenshotName()

getNewUserToken

public String getNewUserToken()

getNextScreenshotNumber

public int getNextScreenshotNumber()

getDisplayParams

public Map<String,Object> getDisplayParams()
Overrides:
getDisplayParams in class AbstractCommentableIssue

getSecureToken

public String getSecureToken()

setSecureToken

public void setSecureToken(String secureToken)

getLoggedInUser

public com.atlassian.crowd.embedded.api.User getLoggedInUser()
Specified by:
getLoggedInUser in interface IssueSummaryAware
Overrides:
getLoggedInUser in class JiraWebActionSupport
Returns:
The logged in user.


Copyright © 2002-2011 Atlassian. All Rights Reserved.