242件ヒット
[1-100件を表示]
(0.081秒)
別のキーワード
種類
- インスタンスメソッド (88)
- 文書 (76)
- 特異メソッド (44)
- モジュール関数 (23)
- クラス (11)
ライブラリ
- ビルトイン (155)
-
webrick
/ httpversion (11)
クラス
-
Encoding
:: Converter (88) - String (33)
-
WEBrick
:: HTTPVersion (11)
モジュール
- Kernel (23)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (11) - Float (6)
- Integer (6)
-
NEWS for Ruby 2
. 5 . 0 (7) -
NEWS for Ruby 3
. 1 . 0 (3) - UndefinedConversionError (11)
- encode (33)
-
last
_ error (11) - new (22)
-
primitive
_ convert (44) - putc (11)
-
ruby 1
. 6 feature (11) -
ruby 1
. 8 . 2 feature (11) -
ruby 1
. 8 . 3 feature (11) -
ruby 1
. 9 feature (11) -
search
_ convpath (11) - 多言語化 (11)
検索結果
先頭5件
- WEBrick
:: HTTPVersion . convert(version) -> WEBrick :: HTTPVersion - Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset , destination _ bytesize , options) -> Symbol - Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset , destination _ bytesize) -> Symbol - Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset) -> Symbol - Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer) -> Symbol
-
WEBrick
:: HTTPVersion . convert(version) -> WEBrick :: HTTPVersion (24401.0) -
指定された version を HTTPVersion オブジェクトに変換して返します。 version が HTTPVersion オブジェクトの場合はそのまま version を返します。
...指定された version を HTTPVersion オブジェクトに変換して返します。
version が HTTPVersion オブジェクトの場合はそのまま version を返します。
@param version HTTP のバージョンを WEBrick::HTTPVersion オブジェクトか文字列で指定します。... -
Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset , destination _ bytesize , options) -> Symbol (15622.0) -
エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。
...ncoding::Converter#primitive_convert が唯一の方法になります。
@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_bytesi......@param options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol
options には以下が指定できます。
: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion aft......put before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT
戻り値は以下のうちのどれかです。
* :invalid_byte_sequence
* :incomplete_input
* :undefined_conversion
* :after_output
* :destination_buffer_full
* :source_buffer_emp... -
Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset , destination _ bytesize) -> Symbol (15522.0) -
エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。
...ncoding::Converter#primitive_convert が唯一の方法になります。
@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_bytesi......@param options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol
options には以下が指定できます。
: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion aft......put before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT
戻り値は以下のうちのどれかです。
* :invalid_byte_sequence
* :incomplete_input
* :undefined_conversion
* :after_output
* :destination_buffer_full
* :source_buffer_emp... -
Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset) -> Symbol (15422.0) -
エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。
...ncoding::Converter#primitive_convert が唯一の方法になります。
@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_bytesi......@param options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol
options には以下が指定できます。
: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion aft......put before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT
戻り値は以下のうちのどれかです。
* :invalid_byte_sequence
* :incomplete_input
* :undefined_conversion
* :after_output
* :destination_buffer_full
* :source_buffer_emp... -
Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer) -> Symbol (15322.0) -
エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。
...ncoding::Converter#primitive_convert が唯一の方法になります。
@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_bytesi......@param options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol
options には以下が指定できます。
: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion aft......put before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT
戻り値は以下のうちのどれかです。
* :invalid_byte_sequence
* :incomplete_input
* :undefined_conversion
* :after_output
* :destination_buffer_full
* :source_buffer_emp... -
Encoding
:: Converter . search _ convpath(source _ encoding , destination _ encoding , options) -> Array (9330.0) -
引数で指定した文字エンコーディングの変換の経路を配列にして返します。
...ィングの変換の経路を配列にして返します。
@param source_encoding 変換元の文字エンコーディングを Encoding オ
ブジェクトか文字列で指定します。
@param destination_encoding 変換先の文字エンコーディングを......ます。
@param options 変換の詳細を指定する定数やハッシュを指定します。
Encoding::Converter.new と同じオプションが指定でき
ます。
//emlist[][ruby]{
p Encoding::Converter.search_convpath("ISO-8859-1", "EUC-JP")
# => [[#<Enc......ncoding:EUC-JP>]]
p Encoding::Converter.search_convpath("ISO-8859-1", "EUC-JP", universal_newline: true)
# or
p Encoding::Converter.search_convpath("ISO-8859-1", "EUC-JP", newline: :universal)
# => [[#<Encoding:ISO-8859-1>, #<Encoding:UTF-8>],
# [#<Encoding:UTF-8>, #<Encoding:EUC-JP>],
# "u... -
Kernel
. # putc(ch) -> object (6112.0) -
文字 ch を 標準出力 $stdout に出力します。
...は、ch.to_int で整数に変換を試みます。
@param ch 出力する文字です。数または文字列で指定します。
@return ch を返します
@raise RangeError Bignum を引数にした場合に発生します。
@raise IOError 標準出力が書き込み用にオープンされ......@raise TypeError Integer に変換できないオブジェクトを引数に
指定した場合に発生します。
//emlist[例][ruby]{
putc("ch")
putc(?c)
putc(99)
putc(355)
#=> cccc
putc(99.00) #=> c
putc(33333333333333333333333333333333333) # bignum too big to convert into `l......ong' (RangeError)
//}
@see IO#putc... -
Encoding
:: UndefinedConversionError (6036.0) -
エンコーディング変換後の文字が存在しない場合に発生する例外。
...生する例外。
UTF-8 にしかない文字を EUC-JP に変換しようとした場合などに発生します。
//emlist[例][ruby]{
"\u2603".encode(Encoding::EUC_JP)
#=> Encoding::UndefinedConversionError: U+2603 from UTF-8 to EUC-JP
//}
変換が多段階でなされ、その途中で例......Encoding::Converter.new("ISO-8859-1", "EUC-JP")
# ISO-8859-1 -> UTF-8 -> EUC-JP
begin
ec.convert("\xa0")
# NO-BREAK SPACE, which is available in UTF-8 but not in EUC-JP.
rescue Encoding::UndefinedConversionError
p $!.source_encoding #=> #<Encoding:UTF-8>
p $!.destination_encodin......g #=> #<Encoding:EUC-JP>
p $!.source_encoding_name #=> "UTF-8"
p $!.destination_encoding_name #=> "EUC-JP"
puts $!.error_char.dump #=> "\u{a0}"
p $!.error_char.encoding #=> #<Encoding:UTF-8>
end
//}... -
Encoding
:: Converter . new(source _ encoding , destination _ encoding , options) -> Encoding :: Converter (3418.0) -
Encoding::Converter オブジェクトを作成します。
...oding::Converter オブジェクトを作成します。
@param source_encoding 変換元のエンコーディング
@param destination_encoding 変換先のエンコーディング
@param options 変換の詳細を指定する定数やハッシュ
@param convpath 変換経路の配列
options で......* Encoding::Converter::INVALID_REPLACE
* Encoding::Converter::UNDEF_REPLACE
* Encoding::Converter::UNDEF_HEX_CHARREF
* Encoding::Converter::UNIVERSAL_NEWLINE_DECORATOR
* Encoding::Converter::CRLF_NEWLINE_DECORATOR
* Encoding::Converter::CR_NEWLINE_DECORATOR
* Encoding::Converter::XML_TEX......R
* Encoding::Converter::XML_ATTR_CONTENT_DECORATOR
* Encoding::Converter::XML_ATTR_QUOTE_DECORATOR
//emlist[][ruby]{
# UTF-16BE to UTF-8
ec = Encoding::Converter.new("UTF-16BE", "UTF-8")
# Usually, decorators such as newline conversion are inserted last.
ec = Encoding::Converter.new("UTF-16BE... -
Encoding
:: Converter # last _ error -> Exception | nil (3236.0) -
直前に変換器で発生した例外に相当する例外オブジェクトを返します。 直前の変換で例外が発生していない場合は nil を返します。
...::Converter.new("utf-8", "iso-8859-1")
p ec.primitive_convert(src="\xf1abcd", dst="") #=> :invalid_byte_sequence
p ec.last_error #=> #<Encoding::InvalidByteSequenceError: "\xF1" followed by "a" on UTF-8>
p ec.primitive_convert(src, dst, nil, 1) #=> :destination_buffer_full
p e...