Debian Codegraph @

src/hardware/ups/apc/snmp/plugin.pm

raw
1 #
2 # Centreon is a full-fledged industry-strength solution that meets
3 # the needs in IT infrastructure and application monitoring for
4 # service performance.
5 #
6 # Licensed under the Apache License, Version 2.0 (the "License");
7 # you may not use this file except in compliance with the License.
8 # You may obtain a copy of the License at
9 #
10 # http://www.apache.org/licenses/LICENSE-2.0
11 #
12 # Unless required by applicable law or agreed to in writing, software
13 # distributed under the License is distributed on an "AS IS" BASIS,
14 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 # See the License for the specific language governing permissions and
16 # limitations under the License.
17 #
18
19 package hardware::ups::apc::snmp::plugin;
20
21 use strict;
22 use warnings;
23 use base qw(centreon::plugins::script_snmp);
24
25 sub new {
26 my ($class, %options) = @_;
27 my $self = $class->SUPER::new(package => __PACKAGE__, %options);
28 bless $self, $class;
29
30 $self->{modes} = {
31 'battery-status' => 'hardware::ups::apc::snmp::mode::batterystatus',
32 'input-lines' => 'hardware::ups::apc::snmp::mode::inputlines',
33 'output-lines' => 'hardware::ups::apc::snmp::mode::outputlines',
34 'sensors' => 'hardware::ups::apc::snmp::mode::sensors',
35 'time' => 'hardware::ups::apc::snmp::mode::ntp',
36 'uptime' => 'hardware::ups::apc::snmp::mode::uptime'
37 };
38
39 return $self;
40 }
41
42 1;
43
44 __END__
45
46 =head1 PLUGIN DESCRIPTION
47
48 Check UPS APC through SNMP (POWERNET-MIB)
49
50 =cut