るりまサーチ (Ruby 3.3)

最速Rubyリファレンスマニュアル検索!
1件ヒット [1-1件を表示] (0.086秒)
トップページ > クエリ:i[x] > クエリ:h[x] > ライブラリ:net/http[x] > クエリ:http_version[x] > クラス:Net::HTTPResponse[x] > バージョン:3.3[x]

別のキーワード

  1. _builtin to_h
  2. env to_h
  3. hash to_h
  4. struct to_h
  5. array to_h

検索結果

Net::HTTPResponse#http_version -> String (99931.0)

サーバがサポートしている HTTP のバージョンを文字列で返します。

...サーバがサポートしている HTTP のバージョンを文字列で返します。

//emlist[例][ruby]{
require 'net/http'

uri = "http://www.example.com/index.html"
response = Net::HTTP.get_response(URI.parse(uri))
response.http_version # => "1.1"
//}...