るりまサーチ

最速Rubyリファレンスマニュアル検索!
66件ヒット [1-66件を表示] (0.154秒)
トップページ > クエリ:-[x] > クエリ:r[x] > クエリ:delete_at[x]

別のキーワード

  1. _builtin to_r
  2. open3 pipeline_r
  3. matrix elements_to_r
  4. fileutils rm_r
  5. fileutils cp_r

ライブラリ

クラス

オブジェクト

キーワード

検索結果

REXML::Parent#delete_at(index) -> REXML::Child | nil (24301.0)

子ノード列上の index で指定された場所の要素を取り除きます。

子ノード列上の index で指定された場所の要素を取り除きます。

取り除いだノードを返します。indexが範囲外である場合は何もせず
nil を返します。

Readline::HISTORY.delete_at(index) -> String | nil (21339.0)

index で指定したインデックスの内容をヒストリから削除し、その内容を返します。 該当する index の内容がヒストリになければ、 nil を返します。 index に 0 を指定すると Readline::HISTORY.shift と同様に最初の入力内容を削除します。 また、 -1 は最後の入力内容というように、index に負の値を指定することで、 最後から入力内容を取得することもできます。 index が -1 の場合は Readline::HISTORY.pop と同様に動作します。

... Readline::HISTORY.shift
と同様に最初の入力内容を削除します。
また、 -1 は最後の入力内容というように、index に負の値を指定することで、
最後から入力内容を取得することもできます。
index が -1 の場合は Readline::HISTORY.pop...
...@param index 削除対象のヒストリのインデックスを指定します。

@raise NotImplementedError サポートしていない環境で発生します。

例:

r
equire "readline"

R
eadline::HISTORY.push("foo", "bar", "baz")
R
eadline::HISTORY.delete_at(1)
p Readline::HISTORY.t...

Array#delete_at(pos) -> object | nil (21207.0)

指定された位置 pos にある要素を取り除きそれを返します。 pos が範囲外であったら nil を返します。

...取り除きそれを返します。
pos が範囲外であったら nil を返します。

Array#at と同様に負のインデックスで末尾から位置を指定するこ
とができます。

@param pos 削除したい要素のインデックスを整数で指定します。
...
...暗黙の型変換を試みます。

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

//emlist[例][ruby]{
array = [0, 1, 2, 3, 4]
array.delete_at 2
p array #=> [0, 1, 3, 4]
//}...

REXML::Element#delete_attribute(key) -> REXML::Attribute | nil (12400.0)

要素から key という属性名の属性を削除します。

...

@param key 削除する要素(文字列(属性名) or REXML::Attributeオブジェクト)

//emlist[][ruby]{
r
equire 'rexml/document'
e = REXML::Element.new("E")
e.add_attribute("x", "foo"); e # => <E x='foo'/>
e.add_attribute("y:x", "bar"); e # => <E x='foo' y:x='bar'/>
e.delete_attribute("x")...
...; e # => <E y:x='bar'/>
//}...

Readline::HISTORY.pop -> String (3206.0)

ヒストリの最後の内容を取り出します。 最後の内容は、ヒストリから取り除かれます。

...@raise NotImplementedError サポートしていない環境で発生します。

例:

r
equire "readline"

R
eadline::HISTORY.push("foo", "bar", "baz")
p Readline::HISTORY.pop #=> "baz"
p Readline::HISTORY.pop #=> "bar"
p Readline::HISTORY.pop #=> "foo"

@see Readline::HISTORY.push、Re...
...adline::HISTORY.shift、
R
eadline::HISTORY.delete_at...

絞り込み条件を変える

Readline::HISTORY.shift -> String (3206.0)

ヒストリの最初の内容を取り出します。 最初の内容は、ヒストリから取り除かれます。

...@raise NotImplementedError サポートしていない環境で発生します。

例:

r
equire "readline"

R
eadline::HISTORY.push("foo", "bar", "baz")
p Readline::HISTORY.shift #=> "foo"
p Readline::HISTORY.shift #=> "bar"
p Readline::HISTORY.shift #=> "baz"

@see Readline::HISTORY.p...
...ush、Readline::HISTORY.pop、
R
eadline::HISTORY.delete_at...