com.atlassian.jira.service.util.handler.MessageUserProcessor |
![]() |
Clients of @PublicApi
can expect
that programs compiled against a given version will remain binary compatible with later versions of the
@PublicApi
as per each product's API policy as long as the client does not implement/extend
@PublicApi
interfaces or classes (refer to each product's API policy for the exact
guarantee---usually binary compatibility is guaranteed at least across minor versions).
@PublicApi
interfaces and classes are not designed to be implemented or extended by clients,
we may perform certain types of binary-incompatible changes to these classes and interfaces, but these will not
affect well-behaved clients that do not extend/implement these types (in general, only classes and interfaces
annotated with @PublicSpi
are safe to extend/implement).
A set of User-related util methods which can be useful while processing Message objects.
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the first User found with an email address that equals the given emailAddress case insensitively.
| |||||||||||
Finds the user with the given username or returns null if there is no such User.
| |||||||||||
For each sender of the given message in turn, look up a User first with a case-insensitively equal email address,
and failing that, with a username equal to the email address.
|
Returns the first User found with an email address that equals the given emailAddress case insensitively.
emailAddress | the email address to match. |
---|
Finds the user with the given username or returns null if there is no such User. Convenience method which doesn't throw up.
username | the username. |
---|
For each sender of the given message in turn, look up a User first with a case-insensitively equal email address, and failing that, with a username equal to the email address.
JIRA wants to do this because when we create users in email handlers, we set email and username equal. If a user subsequently changes their email address, we must not assume they don't exist and create them with the email address as the username.message | the message from which to get the User. |
---|
MessagingException | if there's strife getting the message sender. |
---|