るりまサーチ

最速Rubyリファレンスマニュアル検索!
20件ヒット [1-20件を表示] (0.159秒)
トップページ > クエリ:I[x] > クエリ:IO[x] > クエリ:-[x] > クエリ:EMPTY[x] > クエリ:zero?[x]

別のキーワード

  1. _builtin -
  2. open-uri open
  3. irb/input-method gets
  4. irb/input-method new
  5. matrix -

ライブラリ

クラス

モジュール

検索結果

FileTest.#zero?(file) -> bool (21325.0)

ファイルが存在して、そのサイズが 0 である時に真を返します。 そうでない場合、あるいはシステムコールに失敗した場合には false を返します。

...file ファイル名を表す文字列か IO オブジェクトを指定します。

@raise IOError 指定された IO オブジェクト file が既に close されていた場合に発生します。

//emlist[例:][ruby]{
IO
.write("zero.txt", "")
FileTest.zero?("zero.txt") # => true
IO
.writ...
...e("nonzero.txt", "1")
FileTest.zero?("nonzero.txt") # => false
//}

@see FileTest.#size, FileTest.#size?...

File.zero?(path) -> bool (21207.0)

FileTest.#zero? と同じです。

...FileTest.#zero? と同じです。

@param path パスを表す文字列か IO オブジェクトを指定します。...

NEWS for Ruby 3.0.0 (396.0)

NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

...positional arguments.
Code that resulted in deprecation warnings in Ruby 2.7 will now
result in ArgumentError or different behavior. 14183
* Procs accepting a single rest argument and keywords are no longer
subject to autosplatting. This now matches the behavior of Procs
accepting...
...tion warning
# 3.0 => a=>1}, {}]
//}

* Arguments forwarding (`...`) now supports leading arguments.
16378

//emlist{
def method_missing(meth, ...)
send(:"do_#{meth}", ...)
end
//}

* Pattern matching (`case/in`) is no longer experimental. 17260
* One-line pattern matching is redesig...
...sing a
class variable from the toplevel scope is now a RuntimeError.
14541
* Assigning to a numbered parameter is now a SyntaxError instead of
a warning.

== Command line options

=== `--help` option

When the environment variable `RUBY_PAGER` or `PAGER` is present and has
a non-empty...