line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package FusionInventory::Agent::Task::Inventory::Win32::Sounds; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
61165947
|
use strict; |
|
1
|
|
|
|
|
15
|
|
|
1
|
|
|
|
|
69
|
|
4
|
1
|
|
|
1
|
|
6
|
use warnings; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
80
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
706
|
use FusionInventory::Agent::Tools::Win32; |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
240
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
sub isEnabled { |
9
|
0
|
|
|
0
|
0
|
|
my (%params) = @_; |
10
|
0
|
0
|
|
|
|
|
return 0 if $params{no_category}->{sound}; |
11
|
0
|
|
|
|
|
|
return 1; |
12
|
|
|
|
|
|
|
} |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub doInventory { |
15
|
0
|
|
|
0
|
0
|
|
my (%params) = @_; |
16
|
|
|
|
|
|
|
|
17
|
0
|
|
|
|
|
|
my $inventory = $params{inventory}; |
18
|
|
|
|
|
|
|
|
19
|
0
|
|
|
|
|
|
foreach my $object (getWMIObjects( |
20
|
|
|
|
|
|
|
class => 'Win32_SoundDevice', |
21
|
|
|
|
|
|
|
properties => [ qw/ |
22
|
|
|
|
|
|
|
Name Manufacturer Caption Description |
23
|
|
|
|
|
|
|
/ ] |
24
|
|
|
|
|
|
|
)) { |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
$inventory->addEntry( |
27
|
|
|
|
|
|
|
section => 'SOUNDS', |
28
|
|
|
|
|
|
|
entry => { |
29
|
|
|
|
|
|
|
NAME => $object->{Name}, |
30
|
|
|
|
|
|
|
CAPTION => $object->{Caption}, |
31
|
|
|
|
|
|
|
MANUFACTURER => $object->{Manufacturer}, |
32
|
|
|
|
|
|
|
DESCRIPTION => $object->{Description}, |
33
|
|
|
|
|
|
|
} |
34
|
0
|
|
|
|
|
|
); |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
} |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
1; |