PDF::ReportWriter::Report 1.3 review
DownloadPDF::ReportWriter::Report is a Perl module with PDF::ReportWriter classes that represents a single report
|
|
PDF::ReportWriter::Report is a Perl module with PDF::ReportWriter classes that represents a single report. It handles the conversions from/to XML to PDF::ReportWriter correct data structures, and can provide the data to be used in the report. XML::Simple module is used for data structures serialization to XML and restore.
This class is designed in a way that should be simple to be overloaded, and thus provide alternative classes that load reports in a totally different way, or supply data connecting automatically to a DBI DSN, or who knows...
USAGE:
The most useful usage for this class is through the PDF::ReportWriter::render_report() call. If you really want an example of usage of standalone Report object, here it is:
# Create a blank report object
my $report = PDF::ReportWriter::Report->new();
my $config;
# Load XML report definition
eval { $config = $report->load('/home/cosimo/myreport.xml') };
if( $@ ) {
# Incorrect xml file!
print 'Error in XML report:', $@, "n";
}
# Now save the report object to xml file
my $ok = $report->save($config);
my $ok = $report->save($config, 'Copy of report.xml');
Requirements:
Perl
PDF::ReportWriter::Report 1.3 keywords