36件ヒット
[1-36件を表示]
(0.037秒)
ライブラリ
-
webrick
/ httpresponse (36)
キーワード
-
content
_ length (12) -
content
_ length= (12) - filename (12)
検索結果
先頭3件
-
WEBrick
:: HTTPResponse # filename -> String | nil (6203.0) -
自身の内容があるファイルのそれである場合に、そのファイル名を返します。 デフォルトは nil です。
自身の内容があるファイルのそれである場合に、そのファイル名を返します。
デフォルトは nil です。 -
WEBrick
:: HTTPResponse # content _ length -> Integer | nil (14.0) -
Content-Length ヘッダの値を整数で表すアクセサです。デフォルトは nil です。
...Content-Length ヘッダの値を整数で表すアクセサです。デフォルトは nil です。
: body が String オブジェクトである場合
content_length の値が nil のとき Content-Length ヘッダには
body のサイズが使われます。nil でないとき body の実......を指定することは出来ません。
require 'webrick'
include WEBrick
res = HTTPResponse.new( { :HTTPVersion => "1.1" } )
f = File.new('testfile')
res.body = f
res.content_length = 2
print res.to_s
#=> 出力結果
HTTP/1.1 200 OK
Connection: Keep-Alive
Date: Sat, 27... -
WEBrick
:: HTTPResponse # content _ length=(len) (14.0) -
Content-Length ヘッダの値を整数で表すアクセサです。デフォルトは nil です。
...Content-Length ヘッダの値を整数で表すアクセサです。デフォルトは nil です。
: body が String オブジェクトである場合
content_length の値が nil のとき Content-Length ヘッダには
body のサイズが使われます。nil でないとき body の実......を指定することは出来ません。
require 'webrick'
include WEBrick
res = HTTPResponse.new( { :HTTPVersion => "1.1" } )
f = File.new('testfile')
res.body = f
res.content_length = 2
print res.to_s
#=> 出力結果
HTTP/1.1 200 OK
Connection: Keep-Alive
Date: Sat, 27...