NAME

File::Process::Utils - commonly used recipes for File::Process

SYNOPSIS

use File::Process::Utils qw(process_csv);

my $obj = process_csv('foo.csv', has_headers => 1);

DESCRIPTION

Set of utilities that represent some common use cases for File::Process.

METHODS AND SUBROUTINES

process_csv

process_csv(file, options)

Reads a CSV files using Text::CSV_XS and returns an array of hashes.

Example:

my $obj = process_file(
  'foo.csv',
  has_header  => 1,
  csv_options => { sep_char "\t" },
  );
file

Filename or file handle of an open CSV file.

options

List of options described below.

has_header

Boolean that indicates whether or not the first line of the CSV file is should be considred the column titles. These will be used as the hash keys.

csv_options

Hash of options that will be passed through to Text::CSV_XS

SEE ALSO

File::Process, Text::ASCIITable::EasyTable

AUTHOR

Rob Lauer - <rlauer6@comcast.net>