Object
# File lib/action_dispatch/http/upload.rb, line 6 6: def initialize(hash) 7: @original_filename = encode_filename(hash[:filename]) 8: @content_type = hash[:type] 9: @headers = hash[:head] 10: @tempfile = hash[:tempfile] 11: raise(ArgumentError, ':tempfile is required') unless @tempfile 12: end
# File lib/action_dispatch/http/upload.rb, line 24 24: def encode_filename(filename) 25: # Encode the filename in the utf8 encoding, unless it is nil or we're in 1.8 26: if "ruby".encoding_aware? && filename 27: filename.force_encoding("UTF-8").encode! 28: else 29: filename 30: end 31: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.