|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.snmp4j.agent.CommandProcessor
org.snmp4j.agent.agentx.master.AgentXCommandProcessor
public class AgentXCommandProcessor
| Nested Class Summary | |
|---|---|
protected static class |
AgentXCommandProcessor.AgentXRegEntryComparator
|
| Field Summary | |
|---|---|
protected AgentXIndexRegistry |
indexRegistry
|
static int |
MAX_REPROCESSING_DEFAULT
|
| Fields inherited from class org.snmp4j.agent.CommandProcessor |
|---|
coexistenceProvider, moServers, notificationOriginator, ownContextEngineID, pduHandler, proxyForwarder, requestFactory, requestList, threadPool, vacm |
| Constructor Summary | |
|---|---|
AgentXCommandProcessor(org.snmp4j.smi.OctetString contextEngineID,
AgentXQueue queue,
AgentX agentX,
org.snmp4j.agent.MOServer[] server)
|
|
| Method Summary | |
|---|---|
protected int |
acceptSession(AgentXMasterSession session)
|
AgentXResponsePDU |
addAgentCaps(AgentXAddAgentCapsPDU pdu,
AgentXMasterSession session)
|
void |
addAgentXMasterListener(AgentXMasterListener l)
|
protected void |
addPeer(AgentXPeer peer)
|
protected void |
addRegion(AgentXRegEntry registration,
AgentXRegion region)
|
protected void |
addRegistration(AgentXRegEntry registration)
|
protected void |
addSession(AgentXMasterSession session)
|
protected AgentXPeer |
closePeer(org.snmp4j.smi.Address peerAddress,
byte reason)
|
AgentXResponsePDU |
closeSession(AgentXClosePDU pdu,
AgentXMasterSession session)
|
void |
closeSession(AgentXMasterSession session,
byte reason)
|
void |
connectionStateChanged(org.snmp4j.transport.TransportStateEvent change)
|
protected AgentXResponsePDU |
createResponse(AgentXPDU request,
AgentXSession session)
|
protected void |
finalizeRequest(org.snmp4j.CommandResponderEvent command,
org.snmp4j.agent.request.Request req,
org.snmp4j.agent.MOServer server)
|
protected void |
fireMasterChanged(AgentXMasterEvent event)
|
protected org.snmp4j.agent.mo.snmp.AgentCapabilityList |
getAgentCaps(org.snmp4j.smi.OctetString contextName)
|
byte |
getAgentXVersion()
|
protected org.snmp4j.smi.TimeTicks |
getContextSysUpTime(org.snmp4j.smi.OctetString context)
|
byte |
getDefaultTimeout()
|
int |
getMaxConsecutiveTimeouts()
Gets the maximum number of consecutive timeouts allowed per session. |
int |
getMaxParseErrors()
Gets the upper limit for parse errors for an AgentX peer. |
int |
getMaxReprocessing()
|
protected int |
getNextSessionID()
|
protected AgentXPeer |
getPeer(org.snmp4j.smi.Address address)
|
org.snmp4j.agent.MOServer |
getServer()
Deprecated. Use CommandProcessor.getServer(OctetString context) instead. |
protected AgentXMasterSession |
getSession(AgentXPDU pdu)
|
protected AgentXMasterSession |
getSession(int sessionID)
|
AgentXResponsePDU |
indexAllocate(AgentXIndexAllocatePDU pdu,
AgentXMasterSession session)
|
AgentXResponsePDU |
indexDeallocate(AgentXIndexDeallocatePDU pdu,
AgentXMasterSession session)
|
boolean |
isAcceptNewContexts()
Indicates whether subagents can register contexts that are not yet supported by this master agent. |
protected boolean |
isDuplicate(AgentXRegEntry registration)
|
protected AgentXResponsePDU |
notify(AgentXNotifyPDU pdu,
AgentXMasterSession session)
|
void |
onResponse(AgentXResponseEvent event)
Process an AgentX response. |
AgentXResponsePDU |
openSession(AgentXOpenPDU pdu,
AgentXCommandEvent event)
|
protected AgentXResponsePDU |
ping(AgentXPingPDU pdu,
AgentXMasterSession session)
|
protected void |
processAgentXBulkResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
protected void |
processAgentXGetNextResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
protected void |
processAgentXGetResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
protected void |
processAgentXSearchResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
protected void |
processAgentXSetResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
void |
processCommand(AgentXCommandEvent event)
|
protected static void |
processsErrorResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
protected AgentXResponsePDU |
register(AgentXRegisterPDU pdu,
AgentXCommandEvent command,
AgentXMasterSession session)
|
AgentXResponsePDU |
removeAgentCaps(AgentXRemoveAgentCapsPDU pdu,
AgentXMasterSession session)
|
void |
removeAgentXMasterListener(AgentXMasterListener l)
|
protected void |
removeAllRegistrations(AgentXMasterSession session)
|
protected AgentXPeer |
removePeer(org.snmp4j.smi.Address peerAddress)
|
protected boolean |
removeRegistration(AgentXRegEntry registration,
java.util.Iterator regIterator)
|
protected AgentXMasterSession |
removeSession(int sessionID)
|
protected void |
sendResponse(AgentXPDU response,
AgentXSession session)
|
void |
setAcceptNewContexts(boolean acceptNewContexts)
Enables or disables accepting new contexts from subagents. |
void |
setDefaultTimeout(byte defaultTimeout)
|
void |
setMaxConsecutiveTimeouts(int maxConsecutiveTimeouts)
Sets the maximum number of timeouts allowed per session. |
void |
setMaxParseErrors(int maxParseErrors)
Sets the maximum number of parse errors allowed per peer. |
void |
setMaxReprocessing(int maxReprocessing)
|
protected AgentXResponsePDU |
unregister(AgentXUnregisterPDU pdu,
AgentXCommandEvent event,
AgentXMasterSession session)
|
| Methods inherited from class org.snmp4j.agent.CommandProcessor |
|---|
addCounterListener, addMOServer, addPduHandler, addProxyForwarder, dispatchCommand, fireIncrementCounter, getCoexistenceProvider, getContextEngineID, getHandler, getInternalRequestTimeout, getNotificationOriginator, getProxyForwarder, getRequestList, getServer, getVacm, getViewName, notify, notify, processNextSubRequest, processPdu, processRequest, processRequest, release, removeCounterListener, removeMOServer, removePduHandler, removeProxyForwarder, reprocessRequest, sendResponse, setAuthorizationError, setCoexistenceProvider, setContextEngineID, setInternalRequestTimeout, setNotificationOriginator, setThreadPool, setVacm, setWorkerPool |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int MAX_REPROCESSING_DEFAULT
protected AgentXIndexRegistry indexRegistry
| Constructor Detail |
|---|
public AgentXCommandProcessor(org.snmp4j.smi.OctetString contextEngineID,
AgentXQueue queue,
AgentX agentX,
org.snmp4j.agent.MOServer[] server)
| Method Detail |
|---|
public void setMaxReprocessing(int maxReprocessing)
public int getMaxReprocessing()
public void setMaxParseErrors(int maxParseErrors)
AgentXProtocol.REASON_PARSE_ERROR.
maxParseErrors - a positive value (including zero) sets the upper limit of parse errors
tolerated per peer. If the number of parse errors exceeds this limit,
all sessions with that peer will be closed. A negative value deactivates
any limit.public int getMaxParseErrors()
protected void finalizeRequest(org.snmp4j.CommandResponderEvent command,
org.snmp4j.agent.request.Request req,
org.snmp4j.agent.MOServer server)
finalizeRequest in class org.snmp4j.agent.CommandProcessorprotected int getNextSessionID()
public org.snmp4j.agent.MOServer getServer()
CommandProcessor.getServer(OctetString context) instead.
null context).
public byte getDefaultTimeout()
public int getMaxConsecutiveTimeouts()
public boolean isAcceptNewContexts()
true if subagents can register objects for new contexts.public void setDefaultTimeout(byte defaultTimeout)
public void setMaxConsecutiveTimeouts(int maxConsecutiveTimeouts)
AgentXProtocol.REASON_TIMEOUTS.
maxConsecutiveTimeouts - the maximum number of timeouts (should be greater than zero).public void setAcceptNewContexts(boolean acceptNewContexts)
acceptNewContexts - true if subagents are allowed to register objects for new
contexts, false otherwise. Default is false.public void processCommand(AgentXCommandEvent event)
processCommand in interface AgentXCommandListener
public AgentXResponsePDU indexDeallocate(AgentXIndexDeallocatePDU pdu,
AgentXMasterSession session)
public AgentXResponsePDU indexAllocate(AgentXIndexAllocatePDU pdu,
AgentXMasterSession session)
protected void processAgentXSearchResponse(AgentXPending pending,
AgentXResponsePDU pdu)
protected void processAgentXBulkResponse(AgentXPending pending,
AgentXResponsePDU pdu)
protected static void processsErrorResponse(AgentXPending pending,
AgentXResponsePDU pdu)
throws java.util.NoSuchElementException
java.util.NoSuchElementException
protected AgentXResponsePDU ping(AgentXPingPDU pdu,
AgentXMasterSession session)
protected AgentXResponsePDU notify(AgentXNotifyPDU pdu,
AgentXMasterSession session)
protected org.snmp4j.smi.TimeTicks getContextSysUpTime(org.snmp4j.smi.OctetString context)
public AgentXResponsePDU addAgentCaps(AgentXAddAgentCapsPDU pdu,
AgentXMasterSession session)
protected org.snmp4j.agent.mo.snmp.AgentCapabilityList getAgentCaps(org.snmp4j.smi.OctetString contextName)
public AgentXResponsePDU removeAgentCaps(AgentXRemoveAgentCapsPDU pdu,
AgentXMasterSession session)
public AgentXResponsePDU closeSession(AgentXClosePDU pdu,
AgentXMasterSession session)
public void closeSession(AgentXMasterSession session,
byte reason)
protected void removeAllRegistrations(AgentXMasterSession session)
protected AgentXMasterSession getSession(int sessionID)
protected AgentXMasterSession getSession(AgentXPDU pdu)
protected AgentXResponsePDU register(AgentXRegisterPDU pdu,
AgentXCommandEvent command,
AgentXMasterSession session)
protected AgentXResponsePDU unregister(AgentXUnregisterPDU pdu,
AgentXCommandEvent event,
AgentXMasterSession session)
protected boolean isDuplicate(AgentXRegEntry registration)
protected void addRegistration(AgentXRegEntry registration)
throws org.snmp4j.agent.DuplicateRegistrationException
org.snmp4j.agent.DuplicateRegistrationException
protected void addRegion(AgentXRegEntry registration,
AgentXRegion region)
throws org.snmp4j.agent.DuplicateRegistrationException
org.snmp4j.agent.DuplicateRegistrationException
protected boolean removeRegistration(AgentXRegEntry registration,
java.util.Iterator regIterator)
public AgentXResponsePDU openSession(AgentXOpenPDU pdu,
AgentXCommandEvent event)
protected void addPeer(AgentXPeer peer)
protected AgentXPeer getPeer(org.snmp4j.smi.Address address)
protected int acceptSession(AgentXMasterSession session)
protected void addSession(AgentXMasterSession session)
protected AgentXMasterSession removeSession(int sessionID)
protected AgentXResponsePDU createResponse(AgentXPDU request,
AgentXSession session)
protected void sendResponse(AgentXPDU response,
AgentXSession session)
public void connectionStateChanged(org.snmp4j.transport.TransportStateEvent change)
connectionStateChanged in interface org.snmp4j.transport.TransportStateListenerprotected AgentXPeer removePeer(org.snmp4j.smi.Address peerAddress)
protected AgentXPeer closePeer(org.snmp4j.smi.Address peerAddress,
byte reason)
public byte getAgentXVersion()
public void addAgentXMasterListener(AgentXMasterListener l)
public void removeAgentXMasterListener(AgentXMasterListener l)
protected void fireMasterChanged(AgentXMasterEvent event)
public void onResponse(AgentXResponseEvent event)
AgentXResponseListener
onResponse in interface AgentXResponseListenerevent - a AgentXResponseEvent.
protected void processAgentXGetResponse(AgentXPending pending,
AgentXResponsePDU pdu)
protected void processAgentXGetNextResponse(AgentXPending pending,
AgentXResponsePDU pdu)
protected void processAgentXSetResponse(AgentXPending pending,
AgentXResponsePDU pdu)
|
Copyright 2005-2010 Frank Fock (SNMP4J.org) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||