Module TMail::StrategyInterface
In: actionmailer/lib/action_mailer/vendor/tmail/encode.rb

Methods

Public Instance methods

[Source]

# File actionmailer/lib/action_mailer/vendor/tmail/encode.rb, line 64
    def accept_strategy( klass, eol, charset, dest = nil )
      dest ||= ''
      accept klass.new(create_dest(dest), charset, eol)
      dest
    end

[Source]

# File actionmailer/lib/action_mailer/vendor/tmail/encode.rb, line 40
    def create_dest( obj )
      case obj
      when nil
        StringOutput.new
      when String
        StringOutput.new(obj)
      when IO, StringOutput
        obj
      else
        raise TypeError, 'cannot handle this type of object for dest'
      end
    end

[Source]

# File actionmailer/lib/action_mailer/vendor/tmail/encode.rb, line 58
    def decoded( eol = "\n", charset = 'e', dest = nil )
      accept_strategy Decoder, eol, charset, dest
    end

[Source]

# File actionmailer/lib/action_mailer/vendor/tmail/encode.rb, line 54
    def encoded( eol = "\r\n", charset = 'j', dest = nil )
      accept_strategy Encoder, eol, charset, dest
    end
to_s( eol = "\n", charset = 'e', dest = nil )

Alias for decoded

[Validate]