public class V1TrapInformation extends TrapInformation
Constructor and Description |
---|
V1TrapInformation(InetAddress agent,
String community,
SnmpPduTrap pdu)
Constructs a new trap information instance that contains the sending
agent, the community string, and the Protocol Data Unit.
|
Modifier and Type | Method and Description |
---|---|
int |
getPduLength() |
protected Integer |
getRequestId() |
SnmpVarBindDTO |
getSnmpVarBindDTO(int i) |
long |
getTimeStamp()
Get the SNMP TimeTicks value for the sysUpTime of the agent that
generated the trap.
|
InetAddress |
getTrapAddress() |
TrapIdentity |
getTrapIdentity() |
String |
getVersion() |
String |
toString() |
getAgentAddress, getCommunity, getCreationTime, getLocation, getSystemId, setCreationTime, setLocation, setSystemId, validate
public V1TrapInformation(InetAddress agent, String community, SnmpPduTrap pdu)
agent
- The sending agent's addresscommunity
- The community string from the SNMP packet.pdu
- The encapsulated Protocol Data Unit.public int getPduLength()
getPduLength
in class TrapInformation
public long getTimeStamp()
TrapInformation
getTimeStamp
in class TrapInformation
public TrapIdentity getTrapIdentity()
getTrapIdentity
in class TrapInformation
public InetAddress getTrapAddress()
getTrapAddress
in class TrapInformation
TrapInformation.getAgentAddress()
but for SNMPv1
traps, the value can be different if the trap has been forwarded. It then
represents the true source IP address of the trap event.public String getVersion()
getVersion
in class TrapInformation
public SnmpVarBindDTO getSnmpVarBindDTO(int i)
getSnmpVarBindDTO
in class TrapInformation
protected Integer getRequestId()
getRequestId
in class TrapInformation
Copyright © 2021. All rights reserved.