Class EmailServiceImpl
java.lang.Object
com.app.service.impl.EmailServiceImpl
- All Implemented Interfaces:
EmailService
Implementation of the
EmailService
interface that provides functionality for sending emails.
This service uses JavaMailSender
to send simple email messages with the provided recipient email,
subject, and body. It encapsulates the logic for constructing and sending email messages via SMTP.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
EmailServiceImpl
public EmailServiceImpl()
-
-
Method Details
-
send
Sends an email with the specified recipient, subject, and body.This method creates a simple email message using
SimpleMailMessage
, sets the recipient's email address, subject, and body, and then sends it using theJavaMailSender
.- Specified by:
send
in interfaceEmailService
- Parameters:
email
- the recipient's email addresssubject
- the subject of the emailbody
- the body content of the email
-