| 1 | package Data::All::IO; | ||
| 2 | |||
| 3 | |||
| 4 | 1 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 1 | ▶ | use base qw( Class::Factory ); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 1 | our $VERSION = 0.10; | |
| 9 | |||
| 10 | # NOTE: I need to be given factory type before I am useful | ||
| 11 | # i.e. Data::All::IO->register_factory_type( pkg => 'Data::All::IO::Pkg' ); | ||
| 12 | |||
| 13 | sub new() | ||
| 14 | 4 | ▶ | { |
|
Subroutine
new: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 15 | 4 | my ( $pkg, $type ) = ( shift, shift ); | |
| 16 | 4 | my $class = $pkg->get_factory_class( $type ); | |
| 17 | |||
| 18 | # Use the base's new | ||
| 19 | 4 | return $class->new(@_); | |
| 20 | } | ||
| 21 | |||
| 22 | 1 | 1; | |