るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.140秒)
トップページ > クエリ:I[x] > クエリ:>[x] > クエリ:body[x] > クエリ:response_body_permitted?[x]

別のキーワード

  1. httpresponse body
  2. httpresponse read_body
  3. net/http read_body
  4. httprequest body
  5. net/http body

ライブラリ

クラス

検索結果

Net::HTTPGenericRequest#response_body_permitted? -> bool (30426.0)

サーバからのレスポンスにエンティティボディを含むことが許されている HTTP メソッド (GET, POST など)の場合真を返します。

...合真を返します。

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

uri = URI.parse('http://www.example.com/index.html')
post = Net::HTTP::Post.new(uri.request_uri)
post.response_body_permitted? # => true

head = Net::HTTP::Head.new(uri.request_uri)
head.response_body_permitted? # => false
//}...