るりまサーチ

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

別のキーワード

  1. process fork
  2. process abort
  3. process setrlimit
  4. tracer display_process_id
  5. tracer display_process_id=

ライブラリ

クラス

キーワード

検索結果

Shell::CommandProcessor#foreach(path = nil, &block) -> () (21139.0)

pathがファイルなら, File#foreach pathがディレクトリなら, Dir#foreach の動作をします。

...イルなら, File#foreach
pathがディレクトリなら, Dir#foreach
の動作をします。

@param path ファイルもしくはディレクトリのパスを文字列で指定します。

使用例
require 'shell'
Shell.verbose = false
sh = Shell.new
sh.foreach("/tmp"){|f|
puts f...

CSV (18.0)

このクラスは CSV ファイルやデータに対する完全なインターフェイスを提供します。

...by]{
require "csv"

csv_text = <<~CSV_TEXT
Ruby,1995
Rust,2010
CSV_TEXT

IO.write "sample.csv", csv_text

# ファイルから一行ずつ
CSV.foreach("sample.csv") do |row|
p row
end
# => ["Ruby", "1995"]
# ["Rust", "2010"]

# ファイルから一度に
p CSV.read("sample.csv")
# => [["Ru...
...or example, <tt>:col_sep</tt>, <tt>:row_sep</tt>, and
<tt>:quote_char</tt> must be transcoded to match your data. Hopefully this
makes the entire process feel transparent, since CSV's defaults should just
magically work for you data. However, you can set these values manually in
the target Encodin...
...d String objects
passed into CSV have the proper Encoding set and everything should just work.
CSV methods that allow you to open IO objects (CSV::foreach(), CSV::open(),
CSV::read(), and CSV::readlines()) do allow you to specify the Encoding.

One minor exception comes when generating CSV into a St...

NEWS for Ruby 2.4.0 (18.0)

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

...half には :even, :up, :down が指定可能です。 12548 12958 12953

* IO
* IO#gets, IO#readline, IO#each_line, IO#readlines, IO.foreach
chomp というキーワード引数を受け付けるようになりました。12553

* Kernel
* Kernel#clone は freeze とい...
...ようになりました 12534
* Module.used_modules を追加 7418

* Numeric
* Numeric#finite?, Numeric#infinite? を追加 12039

* Process
* macOS 10.12 から導入された CLOCK_MONOTONIC_RAW_APPROX, CLOCK_UPTIME_RAW,
CLOCK_UPTIME_RAW_APPROX をサポートしました...
...ジトリです。

* Zlib
* Zlib.gzip, Zlib.gunzip を追加 13020

=== C API の更新

* ruby_show_version() will no longer exits the process, if
RUBY_SHOW_COPYRIGHT_TO_DIE is set to 0. This will be the default in
the future.

* rb_gc_adjust_memory_usage() [Feature #12690]

===...