るりまサーチ

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

別のキーワード

  1. etc sc_xopen_enh_i18n
  2. openssl n
  3. rsa n
  4. rsa n=
  5. openssl n=

ライブラリ

クラス

キーワード

検索結果

Array#insert(nth, *val) -> self (24214.0)

インデックス nth の要素の直前(nth が負の場合は直後)に第 2 引数以降の値を挿入します。 引数 val を一つも指定しなければ何もしません。

...インデックス nth の要素の直前(nth が負の場合は直後)に第 2 引数以降の値を挿入します。
引数 val を一つも指定しなければ何もしません。

@param nth val を挿入する位置を整数で指定します。
整数以外のオブジェクト...
...を指定した場合は to_int メソッドによる
暗黙の型変換を試みます。

@param val 自身に挿入するオブジェクトを指定します。

@raise TypeError 引数に整数以外の(暗黙の型変換が行えない)オブジェクトを
指定し...
...た場合に発生します。

//emlist[例][ruby]{
ary = [1, 2, 3]
ary.insert(2, "a", "b")
p ary # => [1, 2, "a", "b", 3]
ary.insert(-2, "X")
p ary # => [1, 2, "a", "b", "X", 3]
//}...

String#insert(pos, other) -> self (24208.0)

pos 番目の文字の直前に文字列 other を挿入します。 self[pos, 0] = other と同じ操作です。

...の直前に文字列 other を挿入します。
self[pos, 0] = other と同じ操作です。

@param pos 文字列を挿入するインデックス
@param other 挿入する文字列

//emlist[例][ruby]{
str = "foobaz"
str.insert(3, "bar")
p str # => "foobarbaz"
//}

@see String#[]=...

Encoding::Converter#insert_output(string) -> nil (12214.0)

変換器内のバッファに文字列を挿入します。 バッファに保持された文字列は、次の変換時の変換結果と一緒に返されます。

...am string 挿入する文字列

//emlist[][ruby]{
ec = Encoding::Converter.new("utf-8", "iso-8859-1")
src = "HIRAGANA LETTER A is \u{3042}."
dst = ""
p ec.primitive_convert(src, dst) #=> :undefined_conversion
puts "[#{dst.dump}, #{src.dump}]" #=> ["HIRAGANA LETTER A is ", "."]
ec.insert_output...
...convert(src, dst) #=> :finished
puts "[#{dst.dump}, #{src.dump}]" #=> ["HIRAGANA LETTER A is <err>.", ""]

ec = Encoding::Converter.new("utf-8", "iso-2022-jp")
src = "\u{306F 3041 3068 2661 3002}" # U+2661 is not representable in iso-2022-jp
dst = ""
p ec.primitive_convert(src, dst) #=> :und...
...efined_conversion
puts "[#{dst.dump}, #{src.dump}]" #=> ["\e$B$O$!$H".force_encoding("ISO-2022-JP"), "\xE3\ x80\x82"]
ec.insert_output "?" # state change required to output "?".
p ec.primitive_convert(src, dst) #=> :finished
puts "[#{dst.dump}, #{src.dump}]" #=> ["\e$B$O$!$...

REXML::Parent#insert_after(child1, child2) -> self (12202.0)

child2 を child1 で指定したノードの後ろに挿入します。

child2 を child1 で指定したノードの後ろに挿入します。

child1 が REXML::Child のインスタンスであるならば、その
子ノードの後ろに挿入されます。
child1 が 文字列であるならば、XPath で場所を指定します。
具体的には REXML::XPath.first(self, child1) で特定されるノードの
後ろに挿入されます。

挿入されるノード(child2)の親は self に変更されます。

@param child1 挿入場所の指定
@param child2 挿入されるノード

REXML::Parent#insert_before(child1, child2) -> self (12202.0)

child2 を child1 で指定したノードの前に挿入します。

child2 を child1 で指定したノードの前に挿入します。

child1 が REXML::Child のインスタンスであるならば、その
子ノードの前に挿入されます。
child1 が 文字列であるならば、XPath で場所を指定します。
具体的には REXML::XPath.first(self, child1) で特定されるノードの
前に挿入されます。

挿入されるノード(child2)の親は self に変更されます。

@param child1 挿入場所の指定
@param child2 挿入されるノード

絞り込み条件を変える

Encoding::Converter#primitive_convert(source_buffer, destination_buffer) -> Symbol (6119.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...、Encoding::Converter#primitive_convert が唯一の方法になります。

@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_by...
...ram options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol

options には以下が指定できます。

: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion after o...
...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_empty
* :fin...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer, destination_byteoffset) -> Symbol (6119.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...、Encoding::Converter#primitive_convert が唯一の方法になります。

@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_by...
...ram options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol

options には以下が指定できます。

: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion after o...
...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_empty
* :fin...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer, destination_byteoffset, destination_bytesize) -> Symbol (6119.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...、Encoding::Converter#primitive_convert が唯一の方法になります。

@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_by...
...ram options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol

options には以下が指定できます。

: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion after o...
...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_empty
* :fin...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer, destination_byteoffset, destination_bytesize, options) -> Symbol (6119.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...、Encoding::Converter#primitive_convert が唯一の方法になります。

@param source_buffer 変換元文字列のバッファ
@param destination_buffer 変換先文字列を格納するバッファ
@param destination_byteoffset 変換先バッファでのオフセット
@param destination_by...
...ram options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol

options には以下が指定できます。

: hash form
:partial_input => true # source buffer may be part of larger source
:after_output => true # stop conversion after o...
...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_empty
* :fin...