るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.013秒)
トップページ > クエリ:HTTPProxyServer[x] > 種類:特異メソッド[x]

別のキーワード

  1. httpproxyserver new
  2. webrick/httpproxy httpproxyserver
  3. webrick/httpproxy webrick::httpproxyserver
  4. httpproxyserver
  5. new webrick::httpproxyserver

ライブラリ

クラス

検索結果

WEBrick::HTTPProxyServer.new(config, default = WEBrick::Config::HTTP) -> WEBrick::HTTPProxyServer (3120.0)

プロクシオブジェクトを生成して返します。

...icate'] = 'Basic realm="WEBrick Proxy"'
raise WEBrick::HTTPStatus::ProxyAuthenticationRequired
else
# 略
end
}
s = WEBrick::HTTPProxyServer.new(ProxyAuthProc: auth_proc, Port: 8080)
//}
: :ProxyContentHandler
接続先の HTTP サーバからの内容を処理する Proc オブ...
...handler = proc{|req, res|
res.body.gsub!(/です。/, 'でんがな。')
res.body.gsub!(/ます。/, 'まんがな。')
}
s = WEBrick::HTTPProxyServer.new(ProxyContentHandler: handler, Port: 8080)
//}
: :ProxyVia
true を指定した場合 接続先の HTTP サーバへのリクエスト...
...の Proxy の URI
を URI オブジェクトで指定します。
//emlist{
require 'uri'
require 'webrick/httpproxy'
u = URI.parse('http://localhost:18080/')
s = WEBrick::HTTPProxyServer.new(ProxyURI: u, Port: 8080)
//}

@param default デフォルトは WEBrick::Config::HTTP です。...