Class: ThingsFetcher::MailHandler
- Inherits:
-
Object
- Object
- ThingsFetcher::MailHandler
- Includes:
- Appscript, OSAX
- Defined in:
- lib/things_fetcher/mail_handler.rb
Instance Method Summary collapse
-
#initialize(config) ⇒ MailHandler
constructor
A new instance of MailHandler.
- #receive(data) ⇒ Object
Constructor Details
#initialize(config) ⇒ MailHandler
Returns a new instance of MailHandler.
7 8 9 |
# File 'lib/things_fetcher/mail_handler.rb', line 7 def initialize(config) @config = config end |
Instance Method Details
#receive(data) ⇒ Object
11 12 13 14 |
# File 'lib/things_fetcher/mail_handler.rb', line 11 def receive(data) msg = Mail.read_from_string(data) make_todo msg.subject end |