Class DeleteKeySender
- java.lang.Object
-
- com.google.gerrit.server.mail.send.OutgoingEmail
-
- com.google.gerrit.server.mail.send.DeleteKeySender
-
public class DeleteKeySender extends OutgoingEmail
Sender that informs a user by email about the removal of an SSH or GPG key from their account.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
DeleteKeySender.Factory
-
Field Summary
-
Fields inherited from class com.google.gerrit.server.mail.send.OutgoingEmail
args, footers, fromId, messageClass, notify, soyContext, soyContextEmailData
-
-
Constructor Summary
Constructors Constructor Description DeleteKeySender(EmailArguments args, MessageIdGenerator messageIdGenerator, IdentifiedUser user, AccountSshKey sshKey)
DeleteKeySender(EmailArguments args, MessageIdGenerator messageIdGenerator, IdentifiedUser user, List<String> gpgKeyFingerprints)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
format()
Format the message body by callingOutgoingEmail.appendText(String)
.protected void
init()
Setup the message headers and envelope (TO, CC, BCC).protected void
setupSoyContext()
protected boolean
shouldSendMessage()
-
Methods inherited from class com.google.gerrit.server.mail.send.OutgoingEmail
add, add, add, add, addByEmail, addByEmail, appendHtml, appendText, getFromLine, getGerritHost, getNameEmailFor, getNameFor, getSettingsUrl, getUserNameEmailFor, isVisibleTo, removeHeader, removeUser, send, setFrom, setHeader, setHeader, setMessageId, setNotify, soyHtmlTemplate, textTemplate, useHtml
-
-
-
-
Constructor Detail
-
DeleteKeySender
public DeleteKeySender(EmailArguments args, MessageIdGenerator messageIdGenerator, IdentifiedUser user, AccountSshKey sshKey)
-
DeleteKeySender
public DeleteKeySender(EmailArguments args, MessageIdGenerator messageIdGenerator, IdentifiedUser user, List<String> gpgKeyFingerprints)
-
-
Method Detail
-
init
protected void init() throws com.google.gerrit.exceptions.EmailException
Description copied from class:OutgoingEmail
Setup the message headers and envelope (TO, CC, BCC).- Overrides:
init
in classOutgoingEmail
- Throws:
com.google.gerrit.exceptions.EmailException
- if an error occurred.
-
shouldSendMessage
protected boolean shouldSendMessage()
- Overrides:
shouldSendMessage
in classOutgoingEmail
-
format
protected void format() throws com.google.gerrit.exceptions.EmailException
Description copied from class:OutgoingEmail
Format the message body by callingOutgoingEmail.appendText(String)
.- Specified by:
format
in classOutgoingEmail
- Throws:
com.google.gerrit.exceptions.EmailException
-
setupSoyContext
protected void setupSoyContext()
- Overrides:
setupSoyContext
in classOutgoingEmail
-
-