Class: Mail::ReturnPathField
- Inherits:
-
StructuredField
- Object
- StructuredField
- Mail::ReturnPathField
- Includes:
- CommonAddress
- Defined in:
- lib/mail/fields/return_path_field.rb
Constant Summary collapse
- FIELD_NAME =
'return-path'
- CAPITALIZED_FIELD =
'Return-Path'
Instance Method Summary collapse
- #address ⇒ Object
- #decoded ⇒ Object
- #default ⇒ Object
- #encoded ⇒ Object
-
#initialize(*args) ⇒ ReturnPathField
constructor
A new instance of ReturnPathField.
Methods included from CommonAddress
Methods included from Utilities
Methods included from CommonField
Constructor Details
#initialize(*args) ⇒ ReturnPathField
Returns a new instance of ReturnPathField.
38 39 40 41 42 43 |
# File 'lib/mail/fields/return_path_field.rb', line 38 def initialize(*args) super(CAPITALIZED_FIELD, strip_field(FIELD_NAME, args.last)) self.parse self end |
Instance Method Details
#address ⇒ Object
53 54 55 |
# File 'lib/mail/fields/return_path_field.rb', line 53 def address addresses.first end |
#decoded ⇒ Object
49 50 51 |
# File 'lib/mail/fields/return_path_field.rb', line 49 def decoded do_decode end |
#default ⇒ Object
57 58 59 |
# File 'lib/mail/fields/return_path_field.rb', line 57 def default address end |
#encoded ⇒ Object
45 46 47 |
# File 'lib/mail/fields/return_path_field.rb', line 45 def encoded "#{CAPITALIZED_FIELD}: <#{address}>\r\n" end |