Skip to content

Commit

Permalink
Remove deprecated URI.escape/URI.unescape since 3.0
Browse files Browse the repository at this point in the history
ruby/uri#9 で削除されて、 3.0.0preview1 でも削除されていました。
  • Loading branch information
znz committed Sep 30, 2020
1 parent 968eefb commit d23e057
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions refm/api/src/uri/URI
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,12 @@ schemes を与えた場合は、そのスキームの URI にのみマッチす
p URI.regexp =~ "http://www.ruby-lang.org/" #=> 0


#@until 3.0
--- escape(str, unsafe = URI::UNSAFE) -> String
--- encode(str, unsafe = URI::UNSAFE) -> String

URI 文字列をエンコードした文字列を返します。

#@since 1.9.2
このメソッドは obsolete です。

代わりに
Expand All @@ -159,7 +159,6 @@ URI 文字列をエンコードした文字列を返します。
[[m:WEBrick::HTTPUtils.#escape]]
などの使用を検討してください。
詳細は [[ruby-core:29293]] からのスレッドを参照してください。
#@end

例:
require 'uri'
Expand All @@ -176,15 +175,13 @@ URI 文字列をエンコードした文字列を返します。

URI 文字列をデコードした文字列を返します。

#@since 1.9.2
このメソッドは obsolete です。

代わりに
[[m:CGI.unescape]],
[[m:URI.decode_www_form]],
[[m:URI.decode_www_form_component]]
などの使用を検討してください。
#@end

例:
require 'uri'
Expand All @@ -194,6 +191,7 @@ URI 文字列をデコードした文字列を返します。

@param str URI を文字列として与えます。

#@end
#@since 1.9.2
--- decode_www_form(str, enc=Encoding::UTF_8) -> [[String, String]]

Expand Down

0 comments on commit d23e057

Please sign in to comment.