るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.026秒)
トップページ > ライブラリ:uri[x] > クエリ:HTTP[x] > クエリ:coerce[x]

別のキーワード

  1. net/http get
  2. http start
  3. http get
  4. net/http start
  5. net/http fetch

クラス

検索結果

URI::Generic#coerce(oth) -> [URI, URI] (18145.0)

引数 oth をパースして [パース後の oth, self] の配列を返します。

...返します。

@param oth URI オブジェクトか文字列を指定します。

例:

require 'uri'

uri
= URI.parse("http://my.example.com")
uri
.coerce("http://foo.com")
# => [#<URI::HTTP:0x00000000bcb028 URL:http://foo.com/>, #<URI::HTTP:0x00000000d92178 URL:http://my.example.com>]...