Class: Sortah::Email
- Inherits:
-
Mail
- Object
- Mail
- Sortah::Email
show all
- Defined in:
- lib/sortah/email.rb
Class Method Summary
collapse
Instance Method Summary
collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(meth, *args, &blk) ⇒ Object
9
10
11
12
|
# File 'lib/sortah/email.rb', line 9
def method_missing(meth, *args, &blk)
return @metadata[meth] if has_data_for?(meth)
super rescue nil
end
|
Class Method Details
.wrap(context, metadata = {}) ⇒ Object
5
6
7
|
# File 'lib/sortah/email.rb', line 5
def self.wrap(context, metadata = {})
Email.new(context, metadata)
end
|
Instance Method Details
14
15
16
|
# File 'lib/sortah/email.rb', line 14
def metadata(key, value)
@metadata[key] = value
end
|