The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Spreadsheet::Template::Generator - create new templates from existing spreadsheets

VERSION

version 0.05

SYNOPSIS

  use Spreadsheet::Template::Generator;

  my $generator = Spreadsheet::Template::Generator->new;
  open my $fh, '>:encoding(utf8)', 'out.json';
  $fh->print($generator->generate($filename));

DESCRIPTION

This module is used to create new templates from existing spreadsheets. You can then modify this output to be suitable to use as input for Spreadsheet::Template by, for instance, adding in Text::Xslate directives to use your actual data, rather than the hardcoded data in the original spreadsheet.

ATTRIBUTES

parser_class

The class to use for parsing the spreadsheet. Defaults to Spreadsheet::Template::Generator::Parser::XLSX.

parser_options

Options to pass to the parser constructor. Defaults to an empty hashref.

METHODS

generate($filename)

Returns a string containing the JSON representation of the data contained in the spreadsheet file $filename. This representation is documented in Spreadsheet::Template.

AUTHOR

Jesse Luehrs <doy@tozt.net>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2015 by Jesse Luehrs.

This is free software, licensed under:

  The MIT (X11) License