【文件属性】:
文件名称:net-http-uploadprogress:获取 Ruby 的文件上传进度
文件大小:5KB
文件格式:ZIP
更新时间:2021-07-01 18:31:01
Ruby
net-http-uploadprogress.gem
获取文件上传进度。
安装
gem install net-http-uploadprogress
例子
require 'net/http/uploadprogress'
# API style upload
File . open ( 'path/to.file' , 'rb' ) do | io |
http = Net :: HTTP . new ( host , port )
req = Net :: HTTP :: Post . new ( '/' )
req . content_length = io . size
req . body_stream = io
Net :: HTTP :: UploadProgress . new (
【文件预览】:
net-http-uploadprogress-master
----lib()
--------net()
--------version.rb(53B)
----Gemfile(107B)
----spec()
--------uploadprogress_spec.rb(4KB)
----Rakefile(28B)
----README.md(951B)
----net-http-uploadprogress.gemspec(817B)
----.gitignore(182B)