Class EmailSender

Inheritance Relationships

Derived Types

Class Documentation

class EmailSender

Abstract email sender.

Sends emails. Only the email subject & body can change from one sent email to another.

Subclassed by email::CurlEmailSender, email::IntraEmailSender

Public Functions

EmailSender()

Constructor.

virtual ~EmailSender()
virtual bool send(const struct EmailContent &content, std::optional<EmailHeaders> additional_headers = std::nullopt) = 0

Send an email.

Parameters:
  • content – the content

  • additional_headers – the optional additional headers to include in the email

Returns:

true if successful, false otherwise

virtual bool reply(const struct EmailContent &content, const struct EmailData &email, std::optional<EmailHeaders> additional_headers = std::nullopt) = 0

Reply to an email.

Parameters:
  • content – the content

  • email – the email to reply to

  • additional_headers – the optional additional headers to include in the email

Returns:

true if successful, false otherwise

Protected Static Functions

static std::shared_ptr<Logger> logger()

Get logger.