palio.modules.snmp.implementation
Class SnmpCommon

java.lang.Object
  extended by palio.modules.snmp.implementation.SnmpCommon
All Implemented Interfaces:
SnmpCommonInterface
Direct Known Subclasses:
SnmpCommunity, SnmpV3

public abstract class SnmpCommon
extends java.lang.Object
implements SnmpCommonInterface


Constructor Summary
SnmpCommon(org.snmp4j.Snmp snmp, org.snmp4j.event.ResponseListener listener)
           
 
Method Summary
static SnmpResponse buildValueResponse(org.snmp4j.CommandResponderEvent response)
           
static SnmpResponse buildValueResponse(org.snmp4j.event.ResponseEvent response)
           
 java.lang.Long getAsynchronous(java.lang.String address, SnmpCommonUser user, java.lang.String oid)
           
 java.lang.Long getAsynchronous(java.lang.String address, SnmpCommonUser user, java.lang.String[] oids)
           
 java.lang.Long getNextAsynchronous(java.lang.String address, SnmpCommonUser user, java.lang.String oid)
           
 java.lang.Long getNextAsynchronous(java.lang.String address, SnmpCommonUser user, java.lang.String[] oids)
           
 SnmpResponse getNextSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String oid)
           
 SnmpResponse getNextSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String[] oids)
           
 SnmpResponse getSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String oid)
           
 SnmpResponse getSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String[] oids)
           
 java.lang.String getTextError(java.lang.Long error)
           
 java.lang.Long setAsynchronous(java.lang.String address, SnmpCommonUser user, java.lang.String[] oids, java.lang.String[] values, java.lang.String[] types)
           
 java.lang.Long setAsynchronous(java.lang.String address, SnmpCommonUser user, java.lang.String oid, java.lang.String value, java.lang.String type)
           
 SnmpResponse setSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String[] oids, java.lang.String[] values, java.lang.String[] types)
           
 SnmpResponse setSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String oid, java.lang.String value, java.lang.String type)
           
 SnmpResponse walkSynchronous(java.lang.String address, SnmpCommonUser user, java.lang.Long timeout, java.lang.Long retries, java.lang.String root, java.lang.Boolean branchOnly)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SnmpCommon

public SnmpCommon(org.snmp4j.Snmp snmp,
                  org.snmp4j.event.ResponseListener listener)
Method Detail

getSynchronous

public SnmpResponse getSynchronous(java.lang.String address,
                                   SnmpCommonUser user,
                                   java.lang.Long timeout,
                                   java.lang.Long retries,
                                   java.lang.String oid)
                            throws java.io.IOException
Specified by:
getSynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

getSynchronous

public SnmpResponse getSynchronous(java.lang.String address,
                                   SnmpCommonUser user,
                                   java.lang.Long timeout,
                                   java.lang.Long retries,
                                   java.lang.String[] oids)
                            throws java.io.IOException
Specified by:
getSynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

getNextSynchronous

public SnmpResponse getNextSynchronous(java.lang.String address,
                                       SnmpCommonUser user,
                                       java.lang.Long timeout,
                                       java.lang.Long retries,
                                       java.lang.String oid)
                                throws java.io.IOException
Specified by:
getNextSynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

getNextSynchronous

public SnmpResponse getNextSynchronous(java.lang.String address,
                                       SnmpCommonUser user,
                                       java.lang.Long timeout,
                                       java.lang.Long retries,
                                       java.lang.String[] oids)
                                throws java.io.IOException
Specified by:
getNextSynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

walkSynchronous

public SnmpResponse walkSynchronous(java.lang.String address,
                                    SnmpCommonUser user,
                                    java.lang.Long timeout,
                                    java.lang.Long retries,
                                    java.lang.String root,
                                    java.lang.Boolean branchOnly)
                             throws java.io.IOException
Specified by:
walkSynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

setSynchronous

public SnmpResponse setSynchronous(java.lang.String address,
                                   SnmpCommonUser user,
                                   java.lang.Long timeout,
                                   java.lang.Long retries,
                                   java.lang.String oid,
                                   java.lang.String value,
                                   java.lang.String type)
                            throws java.io.IOException,
                                   SNMPException
Specified by:
setSynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException
SNMPException

setSynchronous

public SnmpResponse setSynchronous(java.lang.String address,
                                   SnmpCommonUser user,
                                   java.lang.Long timeout,
                                   java.lang.Long retries,
                                   java.lang.String[] oids,
                                   java.lang.String[] values,
                                   java.lang.String[] types)
                            throws SNMPException,
                                   java.io.IOException
Specified by:
setSynchronous in interface SnmpCommonInterface
Throws:
SNMPException
java.io.IOException

getAsynchronous

public java.lang.Long getAsynchronous(java.lang.String address,
                                      SnmpCommonUser user,
                                      java.lang.String oid)
                               throws java.io.IOException
Specified by:
getAsynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

getAsynchronous

public java.lang.Long getAsynchronous(java.lang.String address,
                                      SnmpCommonUser user,
                                      java.lang.String[] oids)
                               throws java.io.IOException
Specified by:
getAsynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

getNextAsynchronous

public java.lang.Long getNextAsynchronous(java.lang.String address,
                                          SnmpCommonUser user,
                                          java.lang.String oid)
                                   throws java.io.IOException
Specified by:
getNextAsynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

getNextAsynchronous

public java.lang.Long getNextAsynchronous(java.lang.String address,
                                          SnmpCommonUser user,
                                          java.lang.String[] oids)
                                   throws java.io.IOException
Specified by:
getNextAsynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException

setAsynchronous

public java.lang.Long setAsynchronous(java.lang.String address,
                                      SnmpCommonUser user,
                                      java.lang.String oid,
                                      java.lang.String value,
                                      java.lang.String type)
                               throws SNMPException,
                                      java.io.IOException
Specified by:
setAsynchronous in interface SnmpCommonInterface
Throws:
SNMPException
java.io.IOException

setAsynchronous

public java.lang.Long setAsynchronous(java.lang.String address,
                                      SnmpCommonUser user,
                                      java.lang.String[] oids,
                                      java.lang.String[] values,
                                      java.lang.String[] types)
                               throws java.io.IOException,
                                      SNMPException
Specified by:
setAsynchronous in interface SnmpCommonInterface
Throws:
java.io.IOException
SNMPException

getTextError

public java.lang.String getTextError(java.lang.Long error)

buildValueResponse

public static SnmpResponse buildValueResponse(org.snmp4j.event.ResponseEvent response)

buildValueResponse

public static SnmpResponse buildValueResponse(org.snmp4j.CommandResponderEvent response)