com.sun.management.snmp.manager
Interface SnmpRequestHandler

All Superinterfaces:
SnmpDefinitions

public interface SnmpRequestHandler
extends SnmpDefinitions

Provides the callback methods that are required to be implemented by the application. An application creates one or more sessions to perform one or many SNMP operations in the form of requests.

Each request is provided with an object that implements this callback interface. An application then uses the session to start an SNMP request, which marks the request as active. The methods in this callback interface get invoked when any of the following happens:

Typically, an application would save the response SnmpVarBindList into its own data structure for further processing, or start another SNMP operation that may be a logical succession (for example, perform a SnmpSet first and then start SnmpGet for results).

Since:
Java DMK 5.1
See Also:
SnmpRequest

Field Summary
 
Fields inherited from interface com.sun.management.snmp.SnmpDefinitions
authMask, authNoPriv, authPriv, authPrivMask, CtxtConsFlag, noAuthNoPriv, noGroupName, noSuchContext, noSuchView, notInView, pduGetBulkRequestPdu, pduGetNextRequestPdu, pduGetRequestPdu, pduGetResponsePdu, pduInformRequestPdu, pduReportPdu, pduSetRequestPdu, pduV1TrapPdu, pduV2TrapPdu, pduWalkRequest, privMask, reportableFlag, snmpAuthNotSupported, snmpBadSecurityLevel, snmpPrivNotSupported, snmpReqAborted, snmpReqEncodingError, snmpReqHandleTooBig, snmpReqInternalError, snmpReqPacketOverflow, snmpReqRefireAfterVbFix, snmpReqSocketIOError, snmpReqTimeout, snmpReqTooBigImpossible, snmpReqUnknownError, snmpRspAuthorizationError, snmpRspBadValue, snmpRspCommitFailed, snmpRspDecodingError, snmpRspEndOfTable, snmpRspGenErr, snmpRspInconsistentName, snmpRspInconsistentValue, snmpRspNoAccess, snmpRspNoCreation, snmpRspNoError, snmpRspNoSuchName, snmpRspNotWritable, snmpRspReadOnly, snmpRspResourceUnavailable, snmpRspTooBig, snmpRspUndoFailed, snmpRspWrongEncoding, snmpRspWrongLength, snmpRspWrongType, snmpRspWrongValue, snmpUnknownPrincipal, snmpUsmBadEngineId, snmpUsmInvalidTimeliness, snmpUsmSecurityModel, snmpV1AccessControlModel, snmpV1MsgProcessingModel, snmpV1SecurityModel, snmpV2AccessControlModel, snmpV2MsgProcessingModel, snmpV2SecurityModel, snmpV3AccessControlModel, snmpV3MsgProcessingModel, snmpVersionOne, snmpVersionThree, snmpVersionTwo, snmpWrongSnmpVersion, trapAuthenticationFailure, trapColdStart, trapEgpNeighborLoss, trapEnterpriseSpecific, trapLinkDown, trapLinkUp, trapWarmStart
 
Method Summary
 void processSnmpInternalError(SnmpRequest request, String errmsg)
          This callback is invoked when any form of internal error occurs during processing of the session.
 void processSnmpPollData(SnmpRequest request, int errStatus, int errIndex, SnmpVarBindList vblist)
          This callback is invoked when a peer responds to an SNMP request.
 void processSnmpPollTimeout(SnmpRequest request)
          This callback is invoked when a peer does not respond within the specified timeout value to the SNMP request.
 

Method Detail

processSnmpPollData

void processSnmpPollData(SnmpRequest request,
                         int errStatus,
                         int errIndex,
                         SnmpVarBindList vblist)
This callback is invoked when a peer responds to an SNMP request. The callback should check the error status of the session to determine the kind of response. These response methods are invoked by the session's dispatcher.

Parameters:
request - The SnmpRequest associated with this callback.
errStatus - The status of the request.
errIndex - The index in the list that caused the error.
vblist - The Response varBind list for the successful request.

processSnmpPollTimeout

void processSnmpPollTimeout(SnmpRequest request)
This callback is invoked when a peer does not respond within the specified timeout value to the SNMP request. The number of tries have also been exhausted.

Parameters:
request - The SnmpRequest associated with this callback.

processSnmpInternalError

void processSnmpInternalError(SnmpRequest request,
                              String errmsg)
This callback is invoked when any form of internal error occurs during processing of the session.

Parameters:
request - The SnmpRequest associated with this callback.
errmsg - The String describing the internal error.

Open Source build 02
opendmk-1.0-b02 2007.10.01_19:17:46_MEST

Copyright 1998-2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.