Parent

Taps::Multipart::Container

Attributes

attachments[RW]

Public Class Methods

new() click to toggle source
# File lib/taps/multipart.rb, line 11
def initialize
        @attachments = []
end

Public Instance Methods

attach(opts) click to toggle source
# File lib/taps/multipart.rb, line 15
def attach(opts)
        mp = Taps::Multipart.new(opts)
        attachments << mp
end
generate() click to toggle source
# File lib/taps/multipart.rb, line 20
def generate
        hash = {}
        attachments.each do |mp|
                hash[mp.name] = mp
        end
        m = RestClient::Payload::Multipart.new(hash)
        [m.to_s, m.headers['Content-Type']]
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.