るりまサーチ (Ruby 2.3.0)

最速Rubyリファレンスマニュアル検索!
1件ヒット [1-1件を表示] (0.028秒)
トップページ > クラス:Dir[x] > 種類:特異メソッド[x] > バージョン:2.3.0[x] > クエリ:Dir.exist?[x]

別のキーワード

  1. argf.class lines
  2. argf.class each
  3. argf.class each_line
  4. argf.class gets
  5. argf.class to_a

ライブラリ

検索結果

Dir.exist?(file_name) -> bool (186325.0)

file_name で与えられたディレクトリが存在する場合に真を返します。 そうでない場合は、偽を返します。

...られたディレクトリが存在する場合に真を返します。
そうでない場合は、偽を返します。

@param file_name 存在を確認したいディレクトリ名。

//emlist[例][ruby]{
Dir
.exist?(".") # => true
File.directory?(".") # => true
//}

@see File.directory?...