line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package FusionInventory::Agent::Task::Inventory::AIX::Videos; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
88275404
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
68
|
|
4
|
2
|
|
|
2
|
|
8
|
use warnings; |
|
2
|
|
|
|
|
7
|
|
|
2
|
|
|
|
|
79
|
|
5
|
|
|
|
|
|
|
|
6
|
2
|
|
|
2
|
|
995
|
use FusionInventory::Agent::Tools; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
288
|
|
7
|
2
|
|
|
2
|
|
727
|
use FusionInventory::Agent::Tools::AIX; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
467
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub isEnabled { |
10
|
0
|
|
|
0
|
0
|
0
|
my (%params) = @_; |
11
|
0
|
0
|
|
|
|
0
|
return 0 if $params{no_category}->{video}; |
12
|
0
|
|
|
|
|
0
|
return canRun('lsdev'); |
13
|
|
|
|
|
|
|
} |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
sub doInventory { |
16
|
0
|
|
|
0
|
0
|
0
|
my (%params) = @_; |
17
|
|
|
|
|
|
|
|
18
|
0
|
|
|
|
|
0
|
my $inventory = $params{inventory}; |
19
|
0
|
|
|
|
|
0
|
my $logger = $params{logger}; |
20
|
|
|
|
|
|
|
|
21
|
0
|
|
|
|
|
0
|
foreach my $video (_getVideos( |
22
|
|
|
|
|
|
|
logger => $logger |
23
|
|
|
|
|
|
|
)) { |
24
|
0
|
|
|
|
|
0
|
$inventory->addEntry( |
25
|
|
|
|
|
|
|
section => 'VIDEOS', |
26
|
|
|
|
|
|
|
entry => $video |
27
|
|
|
|
|
|
|
); |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
} |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub _getVideos { |
32
|
7
|
|
|
7
|
|
16419
|
my @adapters = getAdaptersFromLsdev(@_); |
33
|
|
|
|
|
|
|
|
34
|
7
|
|
|
|
|
54
|
my @videos; |
35
|
7
|
|
|
|
|
10
|
foreach my $adapter (@adapters) { |
36
|
82
|
100
|
|
|
|
236
|
next unless $adapter->{DESCRIPTION} =~ /graphics|vga|video/i; |
37
|
|
|
|
|
|
|
push @videos, { |
38
|
|
|
|
|
|
|
NAME => $adapter->{NAME}, |
39
|
2
|
|
|
|
|
5
|
}; |
40
|
|
|
|
|
|
|
} |
41
|
|
|
|
|
|
|
|
42
|
7
|
|
|
|
|
15
|
return @videos; |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
1; |