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

NAME

App::Pod::Example - Base class for pod_example script.

SYNOPSIS

 use App::Pod::Example;
 my $app = App::Pod::Example->new(%parameters);
 $app->run($file_or_module, $section);

METHODS

new(%parameters)
 Constructor.
  • debug

     Debug flag. It means print debug messages.
     Default value is 1.
  • enumerate

     Enumerate lines in print output.
     Default value is 0.
  • print

     Print flag. It means print of example.
     Default value is 0.
  • run

     Run flag. It means run of example.
     Default value is 1.
run($file_or_module, $section, $number_of_example, $args_ar)
 Run method.
 $file_or_module    - File with pod doc or perl module.
 $section           - Pod section with example. Default value is 'EXAMPLE'.
 $number_of_example - Number of example. If exists 'EXAMPLE1' and 'EXAMPLE2'
                      sections, then this number can be '1' or '2'.
                      Default value is nothing.
 $args_ar           - Reference to array with arguments for 'run' mode.
 Returns undef.

ERRORS

 new():
         Cannot process any action.
         From Class::Utils::set_params():
                 Unknown parameter '%s'.

EXAMPLE

 # Pragmas.
 use strict;
 use warnings;

 # Modules.
 use App::Pod::Example;

 # Run.
 App::Pod::Example->new(
         'enumerate' => 1,
         'print' => 1,
         'run' => 1,
 )->run('Pod::Example');

CAVEATS

Examples with die() cannot process, because returns bad results.

DEPENDENCIES

Class::Utils, English, Error::Pure, File::Temp, IO::Barf, Pod::Example, Readonly.

REPOSITORY

https://github.com/tupinek/App-Pod-Example

AUTHOR

Michal Špaček mailto:skim@cpan.org

http://skim.cz

LICENSE AND COPYRIGHT

BSD license.

VERSION

0.13