Class: Mail::Jdec::Config
- Inherits:
-
Object
- Object
- Mail::Jdec::Config
- Defined in:
- lib/mail/jdec/config.rb
Constant Summary collapse
- NAMES =
[ :enabled, :autodetect_confidence, :autodetect_skip_charsets, :mime_types_for_autodetect, :preferred_charsets, :keep_field_order ]
Instance Method Summary collapse
- #attributes ⇒ Object
-
#initialize(attrs = {}) ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize(attrs = {}) ⇒ Config
Returns a new instance of Config.
15 16 17 18 19 |
# File 'lib/mail/jdec/config.rb', line 15 def initialize(attrs = {}) attrs.each do |key, val| send("#{key}=", val) end end |
Instance Method Details
#attributes ⇒ Object
21 22 23 24 25 |
# File 'lib/mail/jdec/config.rb', line 21 def attributes NAMES.each_with_object({}) do |name, hash| hash[name] = send(name) end end |