るりまサーチ

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

別のキーワード

  1. io popen
  2. io pipe
  3. io each
  4. io readlines
  5. io each_line

検索結果

<< < ... 4 5 6 >>

Gem::StreamUI#alert_warning(statement, question = nil) -> String | nil (106.0)

WARNING レベルのアラートを表示します。

...am statement 表示する文字列を指定します。

@param question 必要であれば質問を指定します。

@return question を指定した場合は、それに対する回答を返します。
question を指定しない場合は nil を返します。

@see Gem::StreamUI#ask...

CSV (30.0)

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

...ターフェイスを提供します。

=== 読み込み

//emlist[][ruby]{
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", "2...
...V と文字エンコーディング (M17n or Multilingualization)

This new CSV parser is m17n savvy. The parser works in the Encoding of the IO
or String object being read from or written to. Your data is never transcoded
(unless you ask Ruby to transcode it for you) and will literally be parsed...
...the target Encoding to avoid the translation.

It's also important to note that while all of CSV's core parser is now
Encoding agnostic, some features are not. For example, the built-in
converters will try to transcode data to UTF-8 before making conversions.
Again, you can provide custom converte...
<< < ... 4 5 6 >>