org.jboss.jmx.adaptor.snmp.trapd
Class TrapReceiver

java.lang.Object
  extended byorg.jboss.jmx.adaptor.snmp.trapd.TrapReceiver

public class TrapReceiver
extends java.lang.Object

Implements an SNMP trap reception engine


Field Summary
protected  Logger (src) log
          target logger
 
Constructor Summary
TrapReceiver(Logger (src)  log)
          Public CTOR
 
Method Summary
 void snmpReceivedTrap(SnmpTrapSession session, java.net.InetAddress agent, int port, SnmpOctetString community, SnmpPduPacket pdu)
          Receives and logs information about SNMPv2 traps.
 void snmpTrapSessionError(SnmpTrapSession session, int error, java.lang.Object ref)
          Processes session errors.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected final Logger (src)  log
target logger

Constructor Detail

TrapReceiver

public TrapReceiver(Logger (src)  log)
Public CTOR

Parameters:
log - the logger used to output info messages
Method Detail

snmpReceivedTrap

public void snmpReceivedTrap(SnmpTrapSession session,
                             java.net.InetAddress agent,
                             int port,
                             SnmpOctetString community,
                             SnmpPduPacket pdu)
Receives and logs information about SNMPv2 traps.

Parameters:
session - the trap session that received the PDU
agent - the address of the remote sender
port - the remote port where the pdu was transmitted from
community - the decoded community string
pdu - the decoded v2 trap pdu

snmpTrapSessionError

public void snmpTrapSessionError(SnmpTrapSession session,
                                 int error,
                                 java.lang.Object ref)
Processes session errors.

Parameters:
session - the trap session in error
error - the error condition
ref - the reference object, if any