563件ヒット
[1-100件を表示]
(0.055秒)
ライブラリ
- ビルトイン (66)
- date (44)
- e2mmap (12)
- fileutils (11)
- json (11)
- logger (8)
-
net
/ http (22) -
net
/ imap (22) - open-uri (36)
- prettyprint (22)
- psych (12)
-
rdoc
/ markup / formatter (11) -
rdoc
/ top _ level (22) - resolv (11)
-
rexml
/ document (55) -
rubygems
/ defaults (11) -
rubygems
/ format (22) -
rubygems
/ installer (11) -
rubygems
/ old _ format (33) -
rubygems
/ platform (33) -
rubygems
/ specification (11) - time (22)
- uri (44)
-
webrick
/ httputils (11)
クラス
- Date (22)
- DateTime (22)
- Dir (11)
- Encoding (11)
- File (33)
-
Gem
:: Format (22) -
Gem
:: Installer (11) -
Gem
:: OldFormat (33) -
Gem
:: Platform (33) -
Gem
:: Specification (11) - IO (11)
- Logger (8)
-
Net
:: HTTP (11) -
Net
:: HTTPResponse (11) -
Net
:: IMAP (22) - PrettyPrint (22)
-
RDoc
:: Markup :: Formatter (11) -
RDoc
:: TopLevel (22) -
REXML
:: Formatters :: Default (11) -
REXML
:: Formatters :: Pretty (11) -
REXML
:: Formatters :: Transitive (11) -
REXML
:: Text (22) -
Resolv
:: DNS :: Resource :: MINFO (11) - Time (22)
-
WEBrick
:: HTTPUtils :: FormData (11)
モジュール
- Exception2MessageMapper (12)
- FileUtils (11)
- Gem (11)
-
JSON
:: Generator :: GeneratorMethods :: String :: Extend (11) - OpenURI (22)
- Psych (12)
- URI (58)
キーワード
-
_ strptime (22) -
all
_ classes _ and _ modules (11) -
body
_ permitted? (11) -
decode
_ www _ form (11) -
decode
_ www _ form _ component (11) -
def
_ exception (6) -
default
_ exec _ format (11) -
encode
_ www _ form (11) -
encode
_ www _ form _ component (11) -
exec
_ format (11) -
find
_ class _ named (11) - format (11)
-
format
_ date (11) -
format
_ datetime (11) -
from
_ file _ by _ path (22) -
from
_ io (22) -
json
_ create (11) - local (11)
-
locale
_ charmap (11) - match (11)
- new (107)
- normalize (11)
-
normalize
_ yaml _ input (11) - open (36)
-
open
_ uri (22) -
post
_ form (11) - rmdir (11)
-
safe
_ load (12) -
singleline
_ format (11) - strptime (44)
- sysopen (11)
- unnormalize (11)
検索結果
先頭5件
-
URI
. encode _ www _ form _ component(str , enc=nil) -> String (6265.0) -
文字列を URL-encoded form data の1コンポーネント としてエンコードした文字列を返します。
...文字列を URL-encoded form data の1コンポーネント
としてエンコードした文字列を返します。
通常は URI.encode_www_form を使うほうがよいでしょう。
このメソッドでは *, -, ., 0-9, A-Z, _, a-z, は変換せず、
空白は + に変換し、その他......、変換します。
このメソッドは
https://www.w3.org/TR/2013/CR-html5-20130806/forms.html#url-encoded-form-data
にもとづいて実装されています。
//emlist[][ruby]{
require 'uri'
p URI.encode_www_form_component('Ruby リファレンスマニュアル')
# => "Ruby+%E3%83%AA%E3%......%83%B3%E3%82%B9%E3%83%9E%E3%83%8B%E3%83%A5%E3%82%A2%E3%83%AB"
//}
@param str エンコードする文字列
@param enc 指定された場合、パーセントエンコーディングする前に、strをこのエンコーディングに変換
@see URI.decode_www_form_component, URI.encode_www_form... -
URI
. encode _ www _ form(enum , enc=nil) -> String (6259.0) -
enum から URL-encoded form data を生成します。
...enum から URL-encoded form data を生成します。
HTML5 で定義されている application/x-www-form-urlencoded 形式の
文字列を生成します。
enum には通常 [key, value] という形の配列の配列を渡します。
以下の例を見てください。
require 'uri'......ode_www_form([["a", "1"], ["b", "2"], ["c", "x yz"]])
# => "a=1&b=2&c=x+yz"
実際には、each のブロック呼び出しで [key, value] の形のデータを渡すものであれば
何でも渡すことができます(例えば Hash など)。
require 'uri'
URI.encode_www_form({"a"=>"1"......のエンコーディングを変換したい場合はあらかじめ
変換しておいてください(例えば ASCII incompatible なものを
UTF-8 に変換する場合など)。
各要素のエンコーディングがばらばらの場合もあらかじめエンコーディングを
揃えて... -
URI
. decode _ www _ form(str , enc=Encoding :: UTF _ 8) -> [[String , String]] (6247.0) -
文字列から URL-encoded form data をデコードします。
...文字列から URL-encoded form data をデコードします。
application/x-www-form-urlencoded 形式のデータをデコードし、
[key, value] という形の配列の配列を返します。
enc で指定したエンコーディングの文字列が URL エンコードされたもの......は
https://url.spec.whatwg.org/#concept-urlencoded-parser
にもとづいて実装されています。
そのため「&」区切りのみに対応していて、「;」区切りには対応していません。
require 'uri'
ary = URI.decode_www_form("a=1&a=2&b=3")
p ary #=......assoc('a').last #=> '2'
p Hash[ary] # => {"a"=>"2", "b"=>"3"}
@param str デコード対象の文字列
@param enc エンコーディング
@raise ArgumentError str のフォーマットが不正である場合に発生します
@see URI.decode_www_form_component, URI.encode_www_form... -
URI
. decode _ www _ form _ component(str , enc=Encoding :: UTF _ 8) -> String (6235.0) -
URL-encoded form data の文字列の各コンポーネント をデコードした文字列を返します。
...URL-encoded form data の文字列の各コンポーネント
をデコードした文字列を返します。
通常は URI.decode_www_form を使うほうがよいでしょう。
"+" という文字は空白文字にデコードします。
enc で指定したエンコーディングの文字......グを付加します。
このメソッドは
https://www.w3.org/TR/html5/sec-forms.html#urlencoded-form-data
にもとづいて実装されています。
//emlist[][ruby]{
require 'uri'
enc = URI.encode_www_form_component('Ruby リファレンスマニュアル')
# => "Ruby+%E3%83%AA%E3%83%95%......_www_form_component(enc)
# => "Ruby リファレンスマニュアル"
//}
@param str デコード対象の文字列
@param enc エンコーディング
@raise ArgumentError str のフォーマットが不正である場合に発生します
@see URI.encode_www_form_component, URI.decode_www_form... -
Encoding
. locale _ charmap -> String | nil (6219.0) -
ロケールエンコーディングを決定するために用いる、locale charmap 名を返します。nl_langinfo 等がない環境では nil を、miniruby では ASCII_8BIT を返します。
...locale charmap 名を返します。nl_langinfo 等がない環境では nil を、miniruby では ASCII_8BIT を返します。
//emlist[Debian GNU/Linux + LANG=C][ruby]{
Encoding.locale_charmap #=> "ANSI_X3.4-1968"
//}
//emlist[LANG=ja_JP.EUC-JP][ruby]{
Encoding.locale_charmap #=> "EUC-JP"
//}......//emlist[SunOS 5 + LANG=C][ruby]{
Encoding.locale_charmap #=> "646"
//}
//emlist[SunOS 5 + LANG=ja][ruby]{
Encoding.locale_charmap #=> "eucJP"
//}
@see charmap(5)... -
Net
:: IMAP . format _ date(time) -> String (6213.0) -
時刻オブジェクトを IMAP の日付フォーマットでの文字列に変換します。
...時刻オブジェクトを IMAP の日付フォーマットでの文字列に変換します。
require 'net/imap'
Net::IMAP.format_date(Time.new(2011, 6, 20))
# => "20-Jun-2011"
@param time 変換する時刻オブジェクト... -
Net
:: IMAP . format _ datetime(time) -> String (6213.0) -
時刻オブジェクトを IMAP の日付時刻フォーマットでの文字列に変換します
...時刻オブジェクトを IMAP の日付時刻フォーマットでの文字列に変換します
require 'net/imap'
Net::IMAP.format_datetime(Time.new(2011, 6, 20, 13, 20, 1))
# => "20-Jun-2011 13:20 +0900"
@param time 変換する時刻オブジェクト... -
Gem
. default _ exec _ format -> String (6201.0) -
デフォルトのインストールするコマンド名を決めるためのフォーマット文字列を返します。
デフォルトのインストールするコマンド名を決めるためのフォーマット文字列を返します。 -
Gem
:: Installer . exec _ format -> String (6201.0) -
実行ファイル名のフォーマットを返します。
実行ファイル名のフォーマットを返します。
指定しない場合は ruby コマンドと同じフォーマットを使用します。 -
Gem
:: Specification . normalize _ yaml _ input(input) -> String (6201.0) -
YAML 形式の gemspec を正しくフォーマットします。
YAML 形式の gemspec を正しくフォーマットします。
@param input 文字列か IO オブジェクトを指定します。