⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.133
Server IP:
185.119.109.197
Server:
Linux managedhosting.chostar.me 5.15.0-160-generic #170-Ubuntu SMP Wed Oct 1 10:06:56 UTC 2025 x86_64
Server Software:
Apache
PHP Version:
8.1.33
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
proc
/
self
/
root
/
usr
/
share
/
ri
/
3.0.0
/
system
/
CSV
/
View File Name :
filter-c.ri
U:RDoc::AnyMethod[iI"filter:ETI"CSV::filter;TT:publico:RDoc::Markup::Document:@parts[ o:RDoc::Markup::Paragraph; [I"-Reads \CSV input and writes \CSV output.;To:RDoc::Markup::BlankLine o; ; [I"For each input row:;To:RDoc::Markup::List: @type:BULLET:@items[o:RDoc::Markup::ListItem:@label0; [o; ; [I"Forms the data into:;To;; ;;[o;;0; [o; ; [I".A CSV::Row object, if headers are in use.;To;;0; [o; ; [I"$An \Array of Arrays, otherwise.;To;;0; [o; ; [I"&Calls the block with that object.;To;;0; [o; ; [I"4Appends the block's return value to the output.;T@o; ; [I"Arguments:;To;; ;;[o;;0; [o; ; [I"\CSV source:;To;; ;;[o;;0; [o; ; [I"AArgument +in_string+, if given, should be a \String object; ;TI"Kit will be put into a new StringIO object positioned at the beginning.;To;;0; [o; ; [I"@Argument +in_io+, if given, should be an IO object that is ;TI"?open for reading; on return, the IO object will be closed.;To;;0; [o; ; [I"3If neither +in_string+ nor +in_io+ is given, ;TI"Nthe input stream defaults to {ARGF}[https://ruby-doc.org/core/ARGF.html].;To;;0; [o; ; [I"\CSV output:;To;; ;;[o;;0; [o; ; [I"BArgument +out_string+, if given, should be a \String object; ;TI"Kit will be put into a new StringIO object positioned at the beginning.;To;;0; [o; ; [I"AArgument +out_io+, if given, should be an IO object that is ;TI"?ppen for writing; on return, the IO object will be closed.;To;;0; [o; ; [I"4If neither +out_string+ nor +out_io+ is given, ;TI"4the output stream defaults to
$stdout
.;To;;0; [o; ; [I"4Argument +options+ should be keyword arguments.;To;; ;;[ o;;0; [o; ; [ I"@Each argument name that is prefixed with +in_+ or +input_+ ;TI";is stripped of its prefix and is treated as an option ;TI"for parsing the input. ;TI"IOption +input_row_sep+ defaults to
$INPUT_RECORD_SEPARATOR
.;To;;0; [o; ; [ I"BEach argument name that is prefixed with +out_+ or +output_+ ;TI";is stripped of its prefix and is treated as an option ;TI" for generating the output. ;TI"JOption +output_row_sep+ defaults to
$INPUT_RECORD_SEPARATOR
.;To;;0; [o; ; [I"AEach argument not prefixed as above is treated as an option ;TI">both for parsing the input and for generating the output.;To;;0; [o; ; [I"ESee {Options for Parsing}[#class-CSV-label-Options+for+Parsing] ;TI"Kand {Options for Generating}[#class-CSV-label-Options+for+Generating].;T@o; ; [I" Example:;To:RDoc::Markup::Verbatim; [I")in_string = "foo,0\nbar,1\nbaz,2\n" ;TI"out_string = '' ;TI"0CSV.filter(in_string, out_string) do |row| ;TI" row[0] = row[0].upcase ;TI" row[1] *= 4 ;TI" end ;TI"5out_string # => "FOO,0000\nBAR,1111\nBAZ,2222\n";T:@format0: @fileI"lib/csv.rb;T:0@omit_headings_from_table_of_contents_below0I"7filter(**options) {|row| ... } filter(in_string, **options) {|row| ... } filter(in_io, **options) {|row| ... } filter(in_string, out_string, **options) {|row| ... } filter(in_string, out_io, **options) {|row| ... } filter(in_io, out_string, **options) {|row| ... } filter(in_io, out_io, **options) {|row| ... } ;TI"headers;T[ I"'(input=nil, output=nil, **options);T@FI"CSV;TcRDoc::NormalClass00