class Shrine::RackFile

  1. lib/shrine/plugins/rack_file.rb
Superclass: Object

This is used to wrap the Rack hash into an IO-like object which Shrine can upload.

Methods

Public Class

  1. new

Public Instance

  1. content_type
  2. original_filename
  3. path
  4. tempfile

Attributes

Public Class methods

new(hash)
[show source]
   # File lib/shrine/plugins/rack_file.rb
55 def initialize(hash)
56   @tempfile          = hash[:tempfile]
57   @original_filename = hash[:filename]
58   @content_type      = hash[:type]
59 end

Public Instance methods

path()
[show source]
   # File lib/shrine/plugins/rack_file.rb
61 def path
62   @tempfile.path
63 end