るりまサーチ (Ruby 2.5.0)

最速Rubyリファレンスマニュアル検索!
6件ヒット [1-6件を表示] (0.015秒)

別のキーワード

  1. cgi/html form
  2. cgi/html doctype
  3. cgi/html element_init
  4. cgi/html multipart_form
  5. cgi html

クラス

キーワード

検索結果

URI::Generic#+(rel) -> URI::Generic (46.0)

自身と与えられたパス rel を連結した新しい URI オブジェクトを生成して返します。

...結した新しい URI オブジェクトを生成して返します。

3986 の Section 5.2 の仕様に従います。
rel が文字列の場合は URI.parse(rel) によって、URI に変換してから連結します。


@param rel 連結したいパスを文字列か URI オブジェクトで...
...uire 'uri'
p URI.parse('http://example.com/') + '/foo/bar.html'
#=> #<URI::HTTP:0x201001c0 URL:http://example.com/foo/bar.html>
URI
('http://a/b/c/d;p?q').merge('?y') #=> #<URI::HTTP:0xb7ca2e2c URL:http://a/b/c/d;p?y>
URI
('http://a/b/c/d;p?q').merge('/./g') #=> #<URI::HTTP...
...0xb7ca2738 URL:http://a/g>
URI
('http://a/b/c/d;p?q').merge('/../g') #=> #<URI::HTTP:0xb7ca2008 URL:http://a/g>
URI
('http://a/b/c/d;p?q').merge('../../../g') #=> #<URI::HTTP:0xb7ca1888 URL:http://a/g>
URI
('http://a/b/c/d;p?q').merge('../../../../g') #=> #<URI::HTTP:0xb7ca10a4 URL:htt...

URI::Generic#-(src) -> URI::Generic (46.0)

与えられた URI を表す src からの相対パスを返します。

...えられた URI を表す src からの相対パスを返します。

@param src 自身の相対パスを算出するための、ルートとなる Absolute URI を与えます。

例:
require 'uri'
p URI.parse('http://example.com/foo/bar.html') - 'http://example.com/'
#=> #<URI::Generic:0x...

URI::Generic#merge!(rel) -> self (46.0)

与えられたパス rel を自身へ連結します。

...様に従います。
rel が文字列の場合は URI.parse(rel) によって、URI に変換してから連結します。

@param rel 連結したいパスを文字列か URI オブジェクトで与えます。

例:
require 'uri'
u = URI.parse('http://example.com/')
u.merge!('/foo/bar.htm...

URI::Generic#merge(rel) -> URI::Generic (46.0)

自身と与えられたパス rel を連結した新しい URI オブジェクトを生成して返します。

...結した新しい URI オブジェクトを生成して返します。

3986 の Section 5.2 の仕様に従います。
rel が文字列の場合は URI.parse(rel) によって、URI に変換してから連結します。


@param rel 連結したいパスを文字列か URI オブジェクトで...
...uire 'uri'
p URI.parse('http://example.com/') + '/foo/bar.html'
#=> #<URI::HTTP:0x201001c0 URL:http://example.com/foo/bar.html>
URI
('http://a/b/c/d;p?q').merge('?y') #=> #<URI::HTTP:0xb7ca2e2c URL:http://a/b/c/d;p?y>
URI
('http://a/b/c/d;p?q').merge('/./g') #=> #<URI::HTTP...
...0xb7ca2738 URL:http://a/g>
URI
('http://a/b/c/d;p?q').merge('/../g') #=> #<URI::HTTP:0xb7ca2008 URL:http://a/g>
URI
('http://a/b/c/d;p?q').merge('../../../g') #=> #<URI::HTTP:0xb7ca1888 URL:http://a/g>
URI
('http://a/b/c/d;p?q').merge('../../../../g') #=> #<URI::HTTP:0xb7ca10a4 URL:htt...

URI::Generic#route_from(src) -> URI::Generic (46.0)

与えられた URI を表す src からの相対パスを返します。

...えられた URI を表す src からの相対パスを返します。

@param src 自身の相対パスを算出するための、ルートとなる Absolute URI を与えます。

例:
require 'uri'
p URI.parse('http://example.com/foo/bar.html') - 'http://example.com/'
#=> #<URI::Generic:0x...

絞り込み条件を変える

URI::Generic#route_to(dst) -> URI::Generic (46.0)

自身から dst への相対パスを返します。

...自身から dst への相対パスを返します。

@param dst URI を文字列かURIオブジェクトで与えます。

例:
require 'uri'
p URI.parse('http://example.com/').route_to('http://example.com/foo/bar.html')

#=> #<URI::Generic:0x20100198 URL:foo/bar.html>...