class AWS::Core::ManagedFile

This trival wrapper around File provides an easy way for the client to know when the file that it just streamed over HTTP should be closed after receiving the response. This should only be used internally to track files that we opened. Open files passed into upload methods should be closed by the user. @private

Public Class Methods

open(path) click to toggle source
# File lib/aws/core/managed_file.rb, line 24
def self.open path
  file_opts = ['rb']
  file_opts << { :encoding => "BINARY" } if Object.const_defined?(:Encoding)
  super(path.to_s, *file_opts)
end