1083件ヒット
[1-100件を表示]
(0.054秒)
クラス
- Array (12)
- CSV (420)
-
CSV
:: FieldInfo (60) -
CSV
:: Row (231) -
CSV
:: Table (348) - String (12)
キーワード
- << (36)
- == (12)
- [] (48)
- []= (36)
-
add
_ row (12) -
by
_ col (12) -
by
_ col! (12) -
by
_ col _ or _ row (12) -
by
_ col _ or _ row! (12) -
by
_ row (12) -
by
_ row! (12) -
close
_ read (12) -
col
_ sep (12) - convert (12)
- converters (12)
-
deconstruct
_ keys (3) - delete (24)
-
delete
_ if (36) - each (48)
- empty? (12)
-
external
_ encoding (12) - fcntl (12)
- field (12)
- field? (12)
-
field
_ size _ limit (12) - fields (12)
- flock (12)
- gets (12)
- header (12)
- header= (12)
- header? (12)
-
header
_ convert (36) -
header
_ converters (12) -
header
_ row? (24) - headers (36)
- include? (12)
- index (12)
- index= (12)
- inspect (12)
-
internal
_ encoding (12) - ioctl (12)
- isatty (12)
- length (12)
- line (12)
- line= (12)
- mode (12)
-
parse
_ csv (12) - path (12)
- push (24)
- puts (12)
-
quote
_ char (12) - read (12)
- readline (12)
- readlines (12)
-
return
_ headers? (12) - row (12)
- shift (12)
- size (12)
-
skip
_ blanks? (12) - stat (12)
- sync= (12)
- table (12)
-
to
_ a (12) -
to
_ csv (24) -
to
_ hash (12) -
to
_ s (12) - truncate (12)
- tty? (12)
-
values
_ at (24) -
write
_ headers? (12)
検索結果
先頭5件
-
CSV
:: Table # table -> Array (9103.0) -
同値性を比較するために内部的に使用します。
同値性を比較するために内部的に使用します。 -
CSV
# stat -> File :: Stat (6203.0) -
IO#stat に委譲します。
...IO#stat に委譲します。
@see IO#stat... -
CSV
# truncate(path , length) -> 0 (6203.0) -
File#truncate に委譲します。
...File#truncate に委譲します。
@see File#truncate... -
CSV
:: Row # to _ hash -> Hash (6203.0) -
自身をシンプルなハッシュに変換します。
...プルなハッシュに変換します。
フィールドの順序は無視されます。
重複したフィールドは削除されます。
//emlist[例][ruby]{
require "csv"
row = CSV::Row.new(["header2", "header1", "header2"], [1, 2, 3])
row.to_hash # => {"header2"=>3, "header1"=>2}
//}... -
CSV
:: Table # to _ a -> [Array] (6110.0) -
配列の配列を返します。
...します。
//emlist[例][ruby]{
require "csv"
row1 = CSV::Row.new(["header1", "header2"], ["row1_1", "row1_2"])
row2 = CSV::Row.new(["header1", "header2"], ["row2_1", "row2_2"])
table = CSV::Table.new([row1, row2])
table.to_a # => [["header1", "header2"], ["row1_1", "row1_2"], ["row2_1", "row2_2... -
CSV
# header _ converters -> Array (6109.0) -
現在有効なヘッダ用変換器のリストを返します。
...ェクトを返します。
//emlist[例][ruby]{
require "csv"
csv = CSV.new("HEADER1,HEADER2\nrow1_1,row1_2", headers: true, header_converters: CSV::HeaderConverters.keys)
csv.header_converters # => [:downcase, :symbol]
csv.read.to_a # => header2], ["row1_1", "row1_2"
//}
@see CSV.new... -
CSV
# close _ read -> nil (6103.0) -
IO#close_read に委譲します。
...IO#close_read に委譲します。
@see IO#close_read... -
CSV
# each {|row| . . . } -> nil (6103.0) -
各行に対してブロックを評価します。
... CSV.new 時に :header => true を指定した場合][ruby]{
require "csv"
users = <<CSV
id,first name,last name,age
1,taro,tanaka,20
2,jiro,suzuki,18
3,ami,sato,19
4,yumi,adachi,21
CSV
csv = CSV.new(users, headers: true)
csv.each do |row|
p row
end
# => #<CSV::Row "id":"1" "first name":"taro"......last name":"tanaka" "age":"20">
# => #<CSV::Row "id":"2" "first name":"jiro" "last name":"suzuki" "age":"18">
# => #<CSV::Row "id":"3" "first name":"ami" "last name":"sato" "age":"19">
# => #<CSV::Row "id":"4" "first name":"yumi" "last name":"adachi" "age":"21">
//}
//emlist[例 CSV.new 時に :hea......"csv"
users = <<CSV
id,first name,last name,age
1,taro,tanaka,20
2,jiro,suzuki,18
3,ami,sato,19
4,yumi,adachi,21
CSV
csv = CSV.new(users)
csv.each do |row|
p row
end
# => ["id", "first name", "last name", "age"]
# => ["1", "taro", "tanaka", "20"]
# => ["2", "jiro", "suzuki", "18"]
# => ["3", "am... -
CSV
# external _ encoding -> Encoding | nil (6103.0) -
IO#external_encoding に委譲します。
...IO#external_encoding に委譲します。...