44件ヒット
[1-44件を表示]
(0.027秒)
検索結果
先頭4件
-
CSV
. filter(input , options = Hash . new) {|row| . . . } (18296.0) -
このメソッドは CSV データに対して Unix のツール群のようなフィルタを構築 するのに便利です。
...ARGF です。
@param output String か IO のインスタンスを指定します。
デフォルトは $stdout です。
@param options ":in_", ":input_" で始まるキーは input にだけ適用されます。
":out_", ":output_" で始まるキーは output に......echo "header1,header2\nrow1_1,row1_2" > in.csv; ruby test.rb in.csv
require "csv"
options = { headers: true, return_headers: true, write_headers: true }
CSV.filter(options) do |row|
if row.header_row?
row << "header3"
next
end
row << "row1_3"
end
# => header1,header2,header3
# row......3,ami,sato,19
4,yumi,adachi,21
EOS
File.write('test.csv',content)
options = { headers: true, return_headers: true, write_headers: true }
CSV.filter(File.open("test.csv"), File.open("out.csv", "w"), options) do |row|
if row.header_row?
row << "full name"
next
end
row << row["first na... -
CSV
. filter(input , output , options = Hash . new) {|row| . . . } (18296.0) -
このメソッドは CSV データに対して Unix のツール群のようなフィルタを構築 するのに便利です。
...ARGF です。
@param output String か IO のインスタンスを指定します。
デフォルトは $stdout です。
@param options ":in_", ":input_" で始まるキーは input にだけ適用されます。
":out_", ":output_" で始まるキーは output に......echo "header1,header2\nrow1_1,row1_2" > in.csv; ruby test.rb in.csv
require "csv"
options = { headers: true, return_headers: true, write_headers: true }
CSV.filter(options) do |row|
if row.header_row?
row << "header3"
next
end
row << "row1_3"
end
# => header1,header2,header3
# row......3,ami,sato,19
4,yumi,adachi,21
EOS
File.write('test.csv',content)
options = { headers: true, return_headers: true, write_headers: true }
CSV.filter(File.open("test.csv"), File.open("out.csv", "w"), options) do |row|
if row.header_row?
row << "full name"
next
end
row << row["first na... -
CSV
. filter(options = Hash . new) {|row| . . . } (18296.0) -
このメソッドは CSV データに対して Unix のツール群のようなフィルタを構築 するのに便利です。
...ARGF です。
@param output String か IO のインスタンスを指定します。
デフォルトは $stdout です。
@param options ":in_", ":input_" で始まるキーは input にだけ適用されます。
":out_", ":output_" で始まるキーは output に......echo "header1,header2\nrow1_1,row1_2" > in.csv; ruby test.rb in.csv
require "csv"
options = { headers: true, return_headers: true, write_headers: true }
CSV.filter(options) do |row|
if row.header_row?
row << "header3"
next
end
row << "row1_3"
end
# => header1,header2,header3
# row......3,ami,sato,19
4,yumi,adachi,21
EOS
File.write('test.csv',content)
options = { headers: true, return_headers: true, write_headers: true }
CSV.filter(File.open("test.csv"), File.open("out.csv", "w"), options) do |row|
if row.header_row?
row << "full name"
next
end
row << row["first na... -
ruby 1
. 6 feature (30.0) -
ruby 1.6 feature ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン になります。
...(<ruby-dev:17193>))
ruby '-*' -v
=> ruby 1.6.7 (2002-03-01) [i586-linux]
=> ruby: invalid option -* (-h will show valid options)
: 2002-05-22 parsedate
バージョンアップ((<ruby-dev:17171>))
: 2002-05-22 -T オプション
ruby のコマンドラインオプ......1303>))
: CGI#header
以下のようなスクリプトでTEXT_PLAINが"text/plain; charset=iso-8859-1"
のように書き換えられていました。
((<ruby-dev:14716>))
require 'cgi'
TEXT_PLAIN = "text/plain"
cgi = CGI.new
print cgi.header("type" => TEX......SO_SECURITY_AUTHENTICATION
SO_SECURITY_ENCRYPTION_TRANSPORT
SO_SECURITY_ENCRYPTION_NETWORK
SO_BINDTODEVICE
SO_ATTACH_FILTER
SO_DETACH_FILTER
SO_PEERNAME
SO_TIMESTAMP
: ((<require|組み込み関数>)) / $LOAD_PATH
Changed to use a new algorithm to locate a library...