line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package FusionInventory::Agent::Target::Local; |
2
|
|
|
|
|
|
|
|
3
|
21
|
|
|
21
|
|
18595231
|
use strict; |
|
21
|
|
|
|
|
38
|
|
|
21
|
|
|
|
|
731
|
|
4
|
21
|
|
|
21
|
|
109
|
use warnings; |
|
21
|
|
|
|
|
28
|
|
|
21
|
|
|
|
|
554
|
|
5
|
21
|
|
|
21
|
|
104
|
use base 'FusionInventory::Agent::Target'; |
|
21
|
|
|
|
|
74
|
|
|
21
|
|
|
|
|
8666
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
my $count = 0; |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub new { |
10
|
0
|
|
|
0
|
1
|
|
my ($class, %params) = @_; |
11
|
|
|
|
|
|
|
|
12
|
0
|
0
|
|
|
|
|
die "no path parameter" unless $params{path}; |
13
|
|
|
|
|
|
|
|
14
|
0
|
|
|
|
|
|
my $self = $class->SUPER::new(%params); |
15
|
|
|
|
|
|
|
|
16
|
0
|
|
|
|
|
|
$self->{path} = $params{path}; |
17
|
|
|
|
|
|
|
|
18
|
0
|
0
|
|
|
|
|
$self->{format} = $params{html} ? 'html' :'xml'; |
19
|
|
|
|
|
|
|
|
20
|
0
|
|
|
|
|
|
$self->_init( |
21
|
|
|
|
|
|
|
id => 'local' . $count++, |
22
|
|
|
|
|
|
|
vardir => $params{basevardir} . '/__LOCAL__', |
23
|
|
|
|
|
|
|
); |
24
|
|
|
|
|
|
|
|
25
|
0
|
|
|
|
|
|
return $self; |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
sub getPath { |
29
|
0
|
|
|
0
|
1
|
|
my ($self) = @_; |
30
|
|
|
|
|
|
|
|
31
|
0
|
|
|
|
|
|
return $self->{path}; |
32
|
|
|
|
|
|
|
} |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
sub _getName { |
35
|
0
|
|
|
0
|
|
|
my ($self) = @_; |
36
|
|
|
|
|
|
|
|
37
|
0
|
|
|
|
|
|
return $self->{path}; |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
sub _getType { |
41
|
0
|
|
|
0
|
|
|
my ($self) = @_; |
42
|
|
|
|
|
|
|
|
43
|
0
|
|
|
|
|
|
return 'local'; |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
1; |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
__END__ |