るりまサーチ

最速Rubyリファレンスマニュアル検索!
48件ヒット [1-48件を表示] (0.063秒)
トップページ > 種類:インスタンスメソッド[x] > クエリ:p[x] > クエリ:file[x] > ライブラリ:webrick/httpresponse[x]

別のキーワード

  1. openssl p
  2. openssl p=
  3. fileutils mkdir_p
  4. kernel p
  5. rsa p

クラス

キーワード

検索結果

WEBrick::HTTPResponse#filename=(file) (9210.0)

自身の内容があるファイルのそれである場合に、そのファイル名をセットします。 デフォルトは nil です。

...自身の内容があるファイルのそれである場合に、そのファイル名をセットします。
デフォルトは nil です。

@param file ファイル名を表す文字列です。...

WEBrick::HTTPResponse#filename -> String | nil (9103.0)

自身の内容があるファイルのそれである場合に、そのファイル名を返します。 デフォルトは nil です。

自身の内容があるファイルのそれである場合に、そのファイル名を返します。
デフォルトは nil です。

WEBrick::HTTPResponse#content_length -> Integer | nil (3009.0)

Content-Length ヘッダの値を整数で表すアクセサです。デフォルトは nil です。

...れません。

@param len ヘッダの値を整数で指定します。nil を指定することは出来ません。

require 'webrick'
include WEBrick
res = HTTPResponse.new( { :HTTPVersion => "1.1" } )
f = File.new('testfile')
res.body = f
res.content_length = 2
p
rint res.to_s...
...#=> 出力結果
HTTP/1.1 200 OK
Connection: Keep-Alive
Date: Sat, 27 Oct 2007 12:04:32 GMT
Server:
Content-Length: 2

ho...

WEBrick::HTTPResponse#content_length=(len) (3009.0)

Content-Length ヘッダの値を整数で表すアクセサです。デフォルトは nil です。

...れません。

@param len ヘッダの値を整数で指定します。nil を指定することは出来ません。

require 'webrick'
include WEBrick
res = HTTPResponse.new( { :HTTPVersion => "1.1" } )
f = File.new('testfile')
res.body = f
res.content_length = 2
p
rint res.to_s...
...#=> 出力結果
HTTP/1.1 200 OK
Connection: Keep-Alive
Date: Sat, 27 Oct 2007 12:04:32 GMT
Server:
Content-Length: 2

ho...