Insight/MIB/IFMIB.pm

filter: Statementstmt 100% 17 / 17 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 3 / 3 Podpod n/a totaltotal 100% 20 / 20 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Insight/MIB/Cisco_VTP.pm ↑ Summary Insight/MIB/SNMPv2.pm »
1 package SNMP::Insight::MIB::IFMIB;
2  
3 #ABSTRACT: Support for data in IF-MIB
4  
5 2 ▶use Moose::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 2 our $VERSION = '0.002'; #TRIAL VERSION:
8  
9 2 ▶use SNMP::Insight::Moose::MIB;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 2 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
11  
12 2 with 'SNMP::Insight::MIB';
13  
14 2 mib_oid '1.3.6.1.2.1.31';
15 2 mib_name 'IF-MIB';
16  
17 2 has_scalar 'ifNumber' => ( oid => ".1.3.6.1.2.1.2.1" );
18  
19 2 has_table 'ifTable' => (
20 oid => ".1.3.6.1.2.1.2.2",
21 index => 'ifIndex',
22 columns => {
23 'ifIndex' => 1,
24 'ifDescr' => 2,
25 'ifType' => 3,
26 'ifMtu' => 4,
27 'ifSpeed' => 5,
28 'ifPhysAddress' => [ 6, 'munge_macaddress' ],
29 'ifAdminStatus' => 7,
30 'ifOperStatus' => 8,
31 'ifLastChange' => 9,
32 'ifInOctets' => 10,
33 'ifInUcastPkts' => 11,
34 'ifInNUcastPkts' => 12,
35 'ifInDiscards' => 13,
36 'ifInErrors' => 14,
37 'ifInUnknownProtos' => 15,
38 'ifOutOctets' => 16,
39 'ifOutUcastPkts' => 17,
40 'ifOutNUcastPkts' => 18,
41 'ifOutDiscards' => 19,
42 'ifOutErrors' => 20,
43 'ifOutQLen' => 21,
44 'ifSpecific' => 22,
45 }
46 );
47  
48 2 has_table "ifXTable" => (
49 oid => "1.1",
50 index => "ifIndex",
51 columns => {
52 'ifName' => 1,
53 'ifInMulticastPkts' => 2,
54 'ifInBroadcastPkts' => 3,
55 'ifOutMulticastPkts' => 4,
56 'ifOutBroadcastPkts' => 5,
57 'ifHCInOctets' => 6,
58 'ifHCInUcastPkts' => 7,
59 'ifHCInMulticastPkts' => 8,
60 'ifHCInBroadcastPkts' => 9,
61 'ifHCOutOctets' => 10,
62 'ifHCOutUcastPkts' => 11,
63 'ifHCOutMulticastPkts' => 12,
64 'ifHCOutBroadcastPkts' => 13,
65 'ifLinkUpDownTrapEnable' => 14,
66 'ifHighSpeed' => 15,
67 'ifPromiscuousMode' => 16,
68 'ifConnectorPresent' => 17,
69 'ifAlias' => 18,
70 'ifCounterDiscontinuityTime' => 19,
71 }
72 );
73  
74 2 1;
75  
76 # Local Variables:
77 # mode: cperl
78 # indent-tabs-mode: nil
79 # cperl-indent-level: 4
80 # cperl-indent-parens-as-block: t
81 # End:
82  
83 __END__
« Insight/MIB/Cisco_VTP.pm ↑ Summary Insight/MIB/SNMPv2.pm »