Skip to content

Commit

Permalink
AWS SDK SES v2
Browse files Browse the repository at this point in the history
  • Loading branch information
musketyr committed Apr 17, 2020
1 parent 5146f1c commit b901606
Showing 1 changed file with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
import java.util.function.Consumer;

/**
* Service for sending
* Service for sending emails via AWS Simple Email Service.
*/
public interface SimpleEmailService {

Expand All @@ -41,10 +41,20 @@ static TransactionalEmail email(Consumer<TransactionalEmail> composer) {
return email;
}

/**
* Builds and sends an email.
* @param composer email definition
* @return delivery status
*/
default EmailDeliveryStatus send(Consumer<TransactionalEmail> composer) {
return send(email(composer));
}

/**
* Sends an email.
* @param email email to be sent
* @return delivery status
*/
EmailDeliveryStatus send(TransactionalEmail email);

}

0 comments on commit b901606

Please sign in to comment.