i/if_ignore cleanup (#377)
* does not have an i_ignore function, don't mention it in the docs
* these interfaces don't even exist on oneaccess
remove i_ignore, mark tests as complete now
* don't see a reason for a function, so remove it:
sub i_ignore {return;}
This commit is contained in:
@@ -552,10 +552,6 @@ Returns reference to the map between IID and physical Port.
|
|||||||
|
|
||||||
The physical port name is returned as slot.port.
|
The physical port name is returned as slot.port.
|
||||||
|
|
||||||
=item $baystack->i_ignore()
|
|
||||||
|
|
||||||
Returns reference to hash of IIDs to ignore.
|
|
||||||
|
|
||||||
=item $baystack->i_mac()
|
=item $baystack->i_mac()
|
||||||
|
|
||||||
Returns the C<ifPhysAddress> table entries.
|
Returns the C<ifPhysAddress> table entries.
|
||||||
|
|||||||
@@ -312,10 +312,6 @@ sub i_mtu {
|
|||||||
return \%i_mtu;
|
return \%i_mtu;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub i_ignore {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
sub i_speed {
|
sub i_speed {
|
||||||
my $netscreen = shift;
|
my $netscreen = shift;
|
||||||
|
|
||||||
@@ -642,10 +638,6 @@ Defaults to C<insIfDescr> if available, uses C<nsIfName> if not.
|
|||||||
Description of the interface. Uses C<insIfDescr> if available, C<nsIfName>
|
Description of the interface. Uses C<insIfDescr> if available, C<nsIfName>
|
||||||
if not.
|
if not.
|
||||||
|
|
||||||
=item $netscreen->i_ignore()
|
|
||||||
|
|
||||||
Returns without defining any interfaces to ignore.
|
|
||||||
|
|
||||||
=item $netscreen->i_index()
|
=item $netscreen->i_index()
|
||||||
|
|
||||||
Default SNMP IID to Interface index.
|
Default SNMP IID to Interface index.
|
||||||
@@ -804,4 +796,3 @@ See L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
|
|||||||
See L<SNMP::Info::IEEE802dot11/"TABLE METHODS"> for details.
|
See L<SNMP::Info::IEEE802dot11/"TABLE METHODS"> for details.
|
||||||
|
|
||||||
=cut
|
=cut
|
||||||
|
|
||||||
|
|||||||
@@ -111,22 +111,6 @@ sub os_ver {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub i_ignore {
|
|
||||||
my $l3 = shift;
|
|
||||||
my $partial = shift;
|
|
||||||
|
|
||||||
my $interfaces = $l3->interfaces($partial) || {};
|
|
||||||
|
|
||||||
my %i_ignore;
|
|
||||||
foreach my $if ( keys %$interfaces ) {
|
|
||||||
# lo0 etc
|
|
||||||
if ( $interfaces->{$if} =~ /\b(inloopback|console)\d*\b/i ) {
|
|
||||||
$i_ignore{$if}++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return \%i_ignore;
|
|
||||||
}
|
|
||||||
|
|
||||||
1;
|
1;
|
||||||
__END__
|
__END__
|
||||||
|
|
||||||
@@ -227,18 +211,6 @@ See documentation in L<SNMP::Info::Layer3> for details.
|
|||||||
These are methods that return tables of information in the form of a reference
|
These are methods that return tables of information in the form of a reference
|
||||||
to a hash.
|
to a hash.
|
||||||
|
|
||||||
=head2 Overrides
|
|
||||||
|
|
||||||
=over
|
|
||||||
|
|
||||||
=item $oneos->i_ignore()
|
|
||||||
|
|
||||||
Returns reference to hash. Increments value of IID if port is to be ignored.
|
|
||||||
|
|
||||||
Ignores InLoopback and Console interfaces
|
|
||||||
|
|
||||||
=back
|
|
||||||
|
|
||||||
=head2 Table Methods imported from SNMP::Info::Layer3
|
=head2 Table Methods imported from SNMP::Info::Layer3
|
||||||
|
|
||||||
See documentation in L<SNMP::Info::Layer3> for details.
|
See documentation in L<SNMP::Info::Layer3> for details.
|
||||||
|
|||||||
@@ -33,14 +33,6 @@ use Test::Class::Most parent => 'My::Test::Class';
|
|||||||
|
|
||||||
use SNMP::Info::Layer3::OneAccess;
|
use SNMP::Info::Layer3::OneAccess;
|
||||||
|
|
||||||
# Remove this startup override once we have full method coverage
|
|
||||||
sub startup : Tests(startup => 1) {
|
|
||||||
my $test = shift;
|
|
||||||
$test->SUPER::startup();
|
|
||||||
|
|
||||||
$test->todo_methods(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
sub setup : Tests(setup) {
|
sub setup : Tests(setup) {
|
||||||
my $test = shift;
|
my $test = shift;
|
||||||
$test->SUPER::setup;
|
$test->SUPER::setup;
|
||||||
|
|||||||
Reference in New Issue
Block a user