Class: Mail::DkimField
- Inherits:
-
StructuredField
- Object
- StructuredField
- Mail::DkimField
- Defined in:
- lib/mail/dkim_field.rb
Constant Summary collapse
- FIELD_NAME =
'dkim-signature'
- CAPITALIZED_FIELD =
'DKIM-Signature'
Instance Method Summary collapse
- #decoded ⇒ Object
- #encoded ⇒ Object
-
#initialize(value = nil, charset = 'utf-8') ⇒ DkimField
constructor
A new instance of DkimField.
Constructor Details
#initialize(value = nil, charset = 'utf-8') ⇒ DkimField
Returns a new instance of DkimField.
10 11 12 13 14 15 |
# File 'lib/mail/dkim_field.rb', line 10 def initialize(value = nil, charset = 'utf-8') self.charset = charset value = strip_field(FIELD_NAME, value) if respond_to?(:strip_field) super(CAPITALIZED_FIELD, value, charset) self end |
Instance Method Details
#decoded ⇒ Object
21 22 23 |
# File 'lib/mail/dkim_field.rb', line 21 def decoded "#{name}:#{value}\r\n" end |
#encoded ⇒ Object
17 18 19 |
# File 'lib/mail/dkim_field.rb', line 17 def encoded "#{name}:#{value}\r\n" end |