Class: MailHandler::Sender
- Inherits:
-
Object
- Object
- MailHandler::Sender
- Defined in:
- lib/mailhandler/sender.rb
Overview
Class for sending email, and storing details about the sending.
Direct Known Subclasses
Defined Under Namespace
Classes: Sending
Instance Attribute Summary collapse
-
#dispatcher ⇒ Object
Returns the value of attribute dispatcher.
-
#sending ⇒ Object
Returns the value of attribute sending.
Instance Method Summary collapse
-
#initialize(dispatcher) ⇒ Sender
constructor
A new instance of Sender.
- #send_email(email) ⇒ Object
Constructor Details
Instance Attribute Details
#dispatcher ⇒ Object
Returns the value of attribute dispatcher.
8 9 10 |
# File 'lib/mailhandler/sender.rb', line 8 def dispatcher @dispatcher end |
#sending ⇒ Object
Returns the value of attribute sending.
8 9 10 |
# File 'lib/mailhandler/sender.rb', line 8 def sending @sending end |
Instance Method Details
#send_email(email) ⇒ Object
24 25 26 27 28 29 30 |
# File 'lib/mailhandler/sender.rb', line 24 def send_email(email) init_sending_details(email) response = dispatcher.send(email) update_sending_details(response) response end |