org.opennms.netmgt.capsd.snmp
Class IfTable
java.lang.Object
org.opennms.netmgt.snmp.CollectionTracker
org.opennms.netmgt.snmp.AggregateTracker
org.opennms.netmgt.capsd.snmp.SnmpTable<IfTableEntry>
org.opennms.netmgt.capsd.snmp.IfTable
- All Implemented Interfaces:
- Collectable
public final class IfTable
- extends SnmpTable<IfTableEntry>
The IfTable uses a SnmpSession to collect the entries in the remote agent's
interface table. It implements the SnmpHandler to receive notifications and
handle errors associated with the data collection. Data is collected using a
series of GETNEXT PDU request to walk multiple parts of the interface table
at once. The number of SNMP packets should not exceed the number of interface +
1, assuming no lost packets or error conditions occur.
Addition by Jon Whetzel
IfTable has an extra class variable for the SNMP version setting. If this is
set for SNMPv2, then a GETBULK command will be used for retrieving the
necessary data. Otherwise, the method will resort to its previous
implementation with GETNEXT commands.
- Author:
- Sowmya , Weave , OpenNMS
- See Also:
- RFC1213
|
Constructor Summary |
IfTable(InetAddress address)
Constructs an IfTable object that is used to collect the interface
elements from the remote agent. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IfTable
public IfTable(InetAddress address)
Constructs an IfTable object that is used to collect the interface
elements from the remote agent. Once all the interfaces are collected, or
there is an error in the collection the signaler object is notified
to inform other threads.
- Parameters:
address - TODO- See Also:
IfTableEntry
createTableEntry
protected IfTableEntry createTableEntry(SnmpObjId base,
SnmpInstId inst,
Object val)
- Specified by:
createTableEntry in class SnmpTable<IfTableEntry>
log
protected final Category log()
getEntry
public IfTableEntry getEntry(int ifIndex)
getOperStatus
public int getOperStatus(int ifIndex)
getAdminStatus
public int getAdminStatus(int ifIndex)
getIfType
public int getIfType(int ifIndex)
getIfDescr
public String getIfDescr(int ifIndex)
getIfSpeed
public Long getIfSpeed(int ifIndex)
getPhysAddr
public String getPhysAddr(int ifIndex)
Copyright © 2009. All Rights Reserved.