Revision 09294068
Von Sven Schöling vor mehr als 13 Jahren hinzugefügt
SL/Helper/Csv.pm | ||
---|---|---|
9 | 9 |
use Text::CSV; |
10 | 10 |
use Rose::Object::MakeMethods::Generic scalar => [ qw( |
11 | 11 |
file encoding sep_char quote_char escape_char header profile class |
12 |
numberformat dateformat ignore_unknown_columns _io _csv _objects _parsed
|
|
13 |
_data _errors |
|
12 |
numberformat dateformat ignore_unknown_columns strict_profile _io _csv
|
|
13 |
_objects _parsed _data _errors
|
|
14 | 14 |
) ]; |
15 | 15 |
|
16 | 16 |
use SL::Helper::Csv::Dispatcher; |
... | ... | |
32 | 32 |
numberformat => 0, |
33 | 33 |
dateformat => 0, |
34 | 34 |
ignore_unknown_columns => 0, |
35 |
strict_profile => 0, |
|
35 | 36 |
}); |
36 | 37 |
my $self = bless {}, $class; |
37 | 38 |
|
... | ... | |
342 | 343 |
If set, the import will ignore unkown header columns. Useful for lazy imports, |
343 | 344 |
but deactivated by default. |
344 | 345 |
|
346 |
=item C<strict_profile> |
|
347 |
|
|
348 |
If set, all columns to be parsed must be specified in C<profile>. Every header |
|
349 |
field not listed there will be treated like an unknown column. |
|
350 |
|
|
345 | 351 |
=back |
346 | 352 |
|
347 | 353 |
=head1 ERROR HANDLING |
Auch abrufbar als: Unified diff
SL::Helper::Csv: neues flag "strict_profile". Wenn gesetzt werden nur Daten aus dem Profil benutzt, keine DWIM can checks.