るりまサーチ (Ruby 2.7.0)

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

別のキーワード

  1. pathname descend
  2. descend pathname
  3. descend enumerator

ライブラリ

クラス

検索結果

Pathname#descend -> Enumerator (54346.0)

self のパス名の親から子供へと辿っていったときの各パス名を新しい Pathname オブジェクトとして生成し、ブロックへの引数として渡して実行しま す。 ブロックを省略した場合は Enumerator を返します。

self のパス名の親から子供へと辿っていったときの各パス名を新しい
Pathname オブジェクトとして生成し、ブロックへの引数として渡して実行しま
す。
ブロックを省略した場合は Enumerator を返します。

//emlist[例][ruby]{
require 'pathname'

Pathname.new('/path/to/some/file.rb').descend {|v| p v}
# => #<Pathname:/>
# #<Pathname:/path>
# #<Pathname:/path/to>
# #<Pathname:/path/to/s...

Pathname#descend {|pathname| ... } -> nil (54346.0)

self のパス名の親から子供へと辿っていったときの各パス名を新しい Pathname オブジェクトとして生成し、ブロックへの引数として渡して実行しま す。 ブロックを省略した場合は Enumerator を返します。

self のパス名の親から子供へと辿っていったときの各パス名を新しい
Pathname オブジェクトとして生成し、ブロックへの引数として渡して実行しま
す。
ブロックを省略した場合は Enumerator を返します。

//emlist[例][ruby]{
require 'pathname'

Pathname.new('/path/to/some/file.rb').descend {|v| p v}
# => #<Pathname:/>
# #<Pathname:/path>
# #<Pathname:/path/to>
# #<Pathname:/path/to/s...