Sha256: b464d81fac1acb7e6d44c1a1d203a8f1f39028fcdf7fb8914d72795d7834226f
Contents?: true
Size: 790 Bytes
Versions: 3
Compression:
Stored size: 790 Bytes
Contents
# encoding: utf-8 module Mail module CommonDate # :nodoc: module InstanceMethods # :doc: # Returns a date time object of the parsed date def date_time ::DateTime.parse("#{element.date_string} #{element.time_string}") end def default date_time end private def do_encode(field_name) "#{field_name}: #{value}\r\n" end def do_decode "#{value}" end def element @element ||= Mail::DateTimeElement.new(value) end # Returns the syntax tree of the Date def tree @tree ||= element.tree end end def self.included(receiver) # :nodoc: receiver.send :include, InstanceMethods end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
mail-1.5.2 | lib/mail/fields/common/common_date.rb |
mail-1.5.1 | lib/mail/fields/common/common_date.rb |
mail-1.5.0 | lib/mail/fields/common/common_date.rb |