line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package exact::conf; |
2
|
|
|
|
|
|
|
# ABSTRACT: Cascading merged application configuration extension for exact |
3
|
|
|
|
|
|
|
|
4
|
1
|
|
|
1
|
|
206011
|
use 5.014; |
|
1
|
|
|
|
|
8
|
|
5
|
1
|
|
|
1
|
|
4
|
use exact; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
9
|
|
6
|
1
|
|
|
1
|
|
517
|
use strict; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
176
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our $VERSION = '1.07'; # VERSION |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
sub import { |
11
|
1
|
|
|
1
|
|
8
|
my ( $self, $caller, $params ) = @_; |
12
|
1
|
|
33
|
|
|
3
|
$caller //= caller(); |
13
|
|
|
|
|
|
|
|
14
|
1
|
|
50
|
|
|
6
|
my @params = grep { length } split( /[,\s]+/, $params || '' ); |
|
0
|
|
|
|
|
0
|
|
15
|
|
|
|
|
|
|
|
16
|
1
|
|
|
|
|
422
|
require Config::App; |
17
|
1
|
50
|
33
|
|
|
44212
|
Config::App->import(@params) if ( @params or not length $params ); |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
{ |
20
|
1
|
|
|
1
|
|
6
|
no strict 'refs'; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
155
|
|
|
1
|
|
|
|
|
4834
|
|
21
|
1
|
|
|
|
|
2
|
my $method = 'conf'; |
22
|
1
|
50
|
|
|
|
2
|
*{ $caller . '::' . $method } = \&$method unless ( defined &{ $caller . '::' . $method } ); |
|
1
|
|
|
|
|
6
|
|
|
1
|
|
|
|
|
8
|
|
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub conf { |
27
|
1
|
|
|
1
|
1
|
4692
|
shift; |
28
|
1
|
|
|
|
|
10
|
return Config::App->new(@_); |
29
|
|
|
|
|
|
|
} |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
1; |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
__END__ |