@Internal public class DefaultMessageHandlerContext extends Object implements MessageHandlerContext
Constructor and Description |
---|
DefaultMessageHandlerContext(CommentManager commentManager,
MessageHandlerExecutionMonitor monitor,
IssueManager issueManager,
AttachmentManager attachmentManager)
Deprecated.
|
DefaultMessageHandlerContext(CommentManager commentManager,
MessageHandlerExecutionMonitor monitor,
IssueManager issueManager,
AttachmentManager attachmentManager,
TextFieldCharacterLengthValidator textFieldCharacterLengthValidator,
PermissionManager permissionManager,
ApplicationProperties applicationProperties) |
Modifier and Type | Method and Description |
---|---|
ChangeItemBean |
createAttachment(File file,
String filename,
String contentType,
com.atlassian.crowd.embedded.api.User author,
Issue issue)
Creates attachment (when run in real mode) or does nothing if run in dry run mode.
|
Comment |
createComment(Issue issue,
com.atlassian.crowd.embedded.api.User author,
String body,
boolean dispatchEvent)
Creates a new issue comment in JIRA or a dummy comment in dry run mode
|
Issue |
createIssue(com.atlassian.crowd.embedded.api.User reporter,
Issue issue)
Creates a new issue in JIRA or a dummy issue in dry run mode
|
com.atlassian.crowd.embedded.api.User |
createUser(String username,
String password,
String email,
String fullname,
Integer userEventType)
Creates user in JIRA or just dummy user if run in dry run mode
|
MessageHandlerExecutionMonitor |
getMonitor() |
boolean |
isRealRun() |
public DefaultMessageHandlerContext(CommentManager commentManager, MessageHandlerExecutionMonitor monitor, IssueManager issueManager, AttachmentManager attachmentManager, TextFieldCharacterLengthValidator textFieldCharacterLengthValidator, PermissionManager permissionManager, ApplicationProperties applicationProperties)
@Deprecated public DefaultMessageHandlerContext(CommentManager commentManager, MessageHandlerExecutionMonitor monitor, IssueManager issueManager, AttachmentManager attachmentManager)
public com.atlassian.crowd.embedded.api.User createUser(String username, String password, String email, String fullname, Integer userEventType) throws PermissionException, CreateException
MessageHandlerContext
createUser
in interface MessageHandlerContext
PermissionException
CreateException
public Comment createComment(Issue issue, com.atlassian.crowd.embedded.api.User author, String body, boolean dispatchEvent)
MessageHandlerContext
createComment
in interface MessageHandlerContext
public Issue createIssue(@Nullable com.atlassian.crowd.embedded.api.User reporter, Issue issue) throws CreateException
MessageHandlerContext
createIssue
in interface MessageHandlerContext
CreateException
public ChangeItemBean createAttachment(File file, String filename, String contentType, com.atlassian.crowd.embedded.api.User author, Issue issue) throws AttachmentException
MessageHandlerContext
createAttachment
in interface MessageHandlerContext
IssueUpdater.doUpdate(com.atlassian.jira.issue.util.IssueUpdateBean, boolean)
AttachmentException
public boolean isRealRun()
isRealRun
in interface MessageHandlerContext
true
if the context works in production mode (when handlers are run from the service)
or false
if runspublic MessageHandlerExecutionMonitor getMonitor()
getMonitor
in interface MessageHandlerContext
Copyright © 2002-2015 Atlassian. All Rights Reserved.