55件ヒット
[1-55件を表示]
(0.071秒)
検索結果
先頭5件
-
URI
:: Generic # userinfo -> String | nil (18118.0) -
自身の userinfo を "username:password" という形式の文字列で返します。 設定されていない場合は nil を返します。
...自身の userinfo を "username:password" という形式の文字列で返します。
設定されていない場合は nil を返します。... -
URI
:: Generic # userinfo=(s) (6148.0) -
自身の userinfo を設定します。
...自身の userinfo を設定します。
@param s 自身の userinfo を "username" か "username:password" という形式の文字列、あるいは
[username, password] という形式の文字列の配列で指定します。
@raise URI::InvalidComponentError 不正な引数 s に対......:InvalidURIError userinfo と registry を同時に設定した場合に発生します。
例:
require 'uri'
u = URI.parse('http://example.com/')
u.userinfo = 'hoge-san:jfae82kj'
p u.to_s #=> "http://hoge-san:jfae82kj@example.com/"
u.userinfo = 'oreore'
p......u.to_s #=> "http://oreore:jfae82kj@example.com/"
u.userinfo = ['you', 'akakfd']
p u.to_s #=> "http://you:akakfd@example.com/"... -
URI
:: Generic # user -> String | nil (23.0) -
自身の userinfo を文字列で返します。
...自身の userinfo を文字列で返します。
userinfo が「username:password」の形式である場合は、username 部を返します。
設定されていない場合は nil を返します。... -
URI
:: Generic # password=(s) (7.0) -
自身の password を設定します。
...い場合には例外が発生します。
@param s 自身の password を表す文字列を指定します。
@raise URI::InvalidComponentError 不正な引数 s に対して発生します。
@raise URI::InvalidURIError userinfo と registry を同時に設定した場合に発生します。... -
URI
:: Generic # select(*components) -> [String] (7.0) -
指定された components に対応する構成要素を文字列の配列として返します。
...字列の配列として返します。
@param components 構成要素名をシンボルで指定します。
例:
require 'uri'
uri = URI.parse('http://myuser:mypass@my.example.com/test.rbx')
p uri.select(:userinfo, :host, :path)
# => ["myuser:mypass", "my.example.com", "/test.rbx"]...