NAME

Lab::Data::Writer - Write data to disk

SYNOPSIS

use Lab::Data::Writer;

my $writer=new Lab::Data::Writer($filename,$config);

$writer->log_comment("This is my test log");

my $num=$writer->log_start_block();
$writer->log_line(1,2,3);

DESCRIPTION

This module can be used to log data to a file, comfortably.

CONSTRUCTOR

new

$writer=new Lab::Data::Writer($filename,$config);

See configure below for available configuration options.

METHODS

configure

$writer->configure(\%config);

Available options and default values are

output_data_ext     => "dat",
output_meta_ext     => "meta",

output_col_sep      => "\t",
output_line_sep     => "\n",
output_block_sep    => "\n",
output_comment_char => "# ",

Example usage is like this:

$writer->configure({
    output_col_sep      => ":",
    output_comment_char => "// ",
});

get_filename

($filename,$filepath)=$writer->get_filename()

log_comment

$writer->log_comment($comment);

Writes a comment to the file.

log_line

$writer->log_line(@data);

Writes a line of data to the file.

log_start_block

$num=$writer->log_start_block();

Starts a new data block.

import_gpplus(%opts)

Imports GPplus TSK-files. Valid parameters are

filename => 'path/to/one/of/the/tsk-files',
newname  => 'path/to/new/directory/newname',
archive  => '[copy|move]'

The path path/to/new/directory/ must exist, while newname shall not exist there.

AUTHOR/COPYRIGHT

Copyright 2004-2006 Daniel Schröer (http://www.danielschroeer.de), 2011 Andreas K. Hüttel

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

1 POD Error

The following errors were encountered while parsing the POD:

Around line 340:

Non-ASCII character seen before =encoding in 'Schröer'. Assuming UTF-8