るりまサーチ

最速Rubyリファレンスマニュアル検索!
22件ヒット [1-22件を表示] (0.371秒)
トップページ > クエリ:-[x] > クエリ:r[x] > クラス:CSV[x] > クエリ:read[x] > クエリ:field_size_limit[x]

別のキーワード

  1. _builtin new
  2. _builtin inspect
  3. _builtin []
  4. _builtin to_s
  5. _builtin each

ライブラリ

検索結果

CSV#field_size_limit -> Integer (18332.0)

フィールドサイズの最大値を返します。

...します。

//emlist[例][ruby]{
r
equire "csv"

csv
= CSV.new(DATA)
csv
.field_size_limit # => nil
p csv.read # => [["a", "b"], ["\n2\n2\n", ""]]

DATA.rewind
csv
= CSV.new(DATA, field_size_limit: 4)
p csv.field_size_limit # => 4
csv
.read # => #<CSV::MalformedCSVError: Field size exceeded on line 2...
....>

__END__
"a","b"
"
2
2
",""
//}

@see CSV.new...

CSV.new(data, options = Hash.new) -> CSV (161.0)

このメソッドは CSV ファイルを読み込んだり、書き出したりするために String か IO のインスタンスをラップします。

...のメソッドは CSV ファイルを読み込んだり、書き出したりするために
String か IO のインスタンスをラップします。

ラップされた文字列の先頭から読み込むことになります。
文字列に追記したい場合は CSV.generate を使用して...
...or the stream is only available for output, the default
$INPUT_RECORD_SEPARATOR ($/) is used. Obviously,
discovery takes a little time. Set manually if speed is important. Also
note that IO objects should be opened in binary mode on Windows if this
feature will be used as the line-e...
...nding translation can cause
problems with resetting the document position to where it was before the
read
ahead. This String will be transcoded into the data's Encoding before parsing.
: :quote_char
フィールドをクオートする文字を指定します。長さ 1 の文字列でな...