|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.ibm.di.connector.Connector
com.ibm.di.connector.SNMPServerConnector
public class SNMPServerConnector
The SNMP Server Connector is used by a monitoring console (an SNMP Manager). The SNMP Server Connector receives SNMP packets on a specified port, and returns appropriate SNMP response packets.
| Nested Class Summary | |
|---|---|
static class |
SNMPServerConnector.EmptyValue
An Empty Value used in internal code. |
| Field Summary |
|---|
| Fields inherited from class com.ibm.di.connector.Connector |
|---|
ALL_MODES, myLog, PROPERTY_MESSAGE, PROPERTY_READER, PROPERTY_WRITER |
| Constructor Summary | |
|---|---|
SNMPServerConnector()
Default constructor. |
|
| Method Summary | |
|---|---|
com.tivoli.snmp.data.BadValue |
createBadValue()
Convenient methods to create SNMP object types. |
com.tivoli.snmp.data.Boolean |
createBoolean(boolean aValue)
Creates boolean object. |
com.tivoli.snmp.data.Counter |
createCounter(long aValue)
Creates Counter object. |
com.tivoli.snmp.data.Counter64 |
createCounter64(long aValue)
Creates Counter64 object. |
com.tivoli.snmp.data.FixedLengthOctetString |
createFixedLengthOctetString(String aValue)
Creates FixedLengthOctetString object. |
com.tivoli.snmp.data.FullCounter64 |
createFullCounter64(BigInteger aValue)
Creates FullCounter64 object. |
com.tivoli.snmp.data.Gauge |
createGauge(long aValue)
Creates Gauge object. |
com.tivoli.snmp.data.IPAddress |
createIPAddress(String aValue)
Creates IPAddress object. |
com.tivoli.snmp.data.NoChange |
createNoChange()
Creates NoChange object. |
com.tivoli.snmp.data.NoSuchInstance |
createNoSuchInstance()
Creates NoSuchInstance object. |
com.tivoli.snmp.data.NoSuchObject |
createNoSuchObject()
Creates NoSuchObject object. |
com.tivoli.snmp.data.NotSupported |
createNotSupported()
Creates NotSupported object. |
com.tivoli.snmp.data.Null |
createNull()
Creates Null object. |
com.tivoli.snmp.data.OctetString |
createOctetString(String aValue)
Creates OctetString object. |
com.tivoli.snmp.data.OID |
createOID(String aValue)
Creates OID object. |
com.tivoli.snmp.data.Opaque |
createOpaque(byte[] aValue)
Creates Opaque object. |
com.tivoli.snmp.data.TimeTicks |
createTimeTicks(long aValue)
Creates TimeTicks object. |
ConnectorInterface |
getNextClient()
Server mode - returns a new instance of the Connector for each client connection. |
Entry |
getNextEntry()
Returns the next Entry from the SNMP client(Manager). |
SNMPServerConnector |
getServerConnector()
Returns the server Connector if this Connector is handling a client session. |
String |
getVersion()
Version information. |
void |
initialize(Object aObj)
Initialize the Connector. |
boolean |
isAccepting()
Checks if this Connector is currently waiting for a client connection. |
boolean |
isTerminating()
Checks if termination is requested. |
void |
putEntry(Entry aEntry)
Send response to the SNMP client (Manager). |
void |
replyEntry(Entry aEntry)
Send response to the SNMP client (Manager). |
void |
setCommunity(String aCommunity)
Sets community parameter |
void |
setServerConnector(SNMPServerConnector aServerConnector)
Sets the server Connector for this Connector. |
void |
terminate()
Terminate the connector. |
void |
terminateServer()
This method tries to terminate the server by setting the termination flag for the Connector returned by getServerConnector and immediatly connecting to its port. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SNMPServerConnector()
| Method Detail |
|---|
public SNMPServerConnector getServerConnector()
public void setCommunity(String aCommunity)
aCommunity - The communitypublic void setServerConnector(SNMPServerConnector aServerConnector)
aServerConnector - The serverConnector.public boolean isAccepting()
public boolean isTerminating()
public void initialize(Object aObj)
throws Exception
initialize in interface ConnectorInterfaceinitialize in class ConnectoraObj - Null, DatagramPacket or ConnectorMode class
Exception - If invalid Connector parameter values are supplied.
public ConnectorInterface getNextClient()
throws Exception
getNextClient in interface ConnectorInterfacegetNextClient in class ConnectorException - if an error occurs.
public Entry getNextEntry()
throws Exception
getNextEntry in interface ConnectorInterfacegetNextEntry in class ConnectorException - If retrieving the next Entry fails.ConnectorInterface.selectEntries()
public void replyEntry(Entry aEntry)
throws Exception
replyEntry in interface ConnectorInterfacereplyEntry in class ConnectoraEntry - The entry.
Exception - If sending response fails.
public void putEntry(Entry aEntry)
throws Exception
putEntry in interface ConnectorInterfaceputEntry in class ConnectoraEntry - The entry.
Exception - If sending response fails.
public void terminateServer()
throws Exception
terminateServer in interface ConnectorInterfaceterminateServer in class ConnectorException - if an error occurs
public void terminate()
throws Exception
terminate in interface ConnectorInterfaceterminate in class ConnectorException - if an error occurs.public com.tivoli.snmp.data.BadValue createBadValue()
BadValue instance.public com.tivoli.snmp.data.Boolean createBoolean(boolean aValue)
aValue - The boolean value to set.
Boolean instance.public com.tivoli.snmp.data.Counter createCounter(long aValue)
Counter object.
aValue - The long value to set.
Counter instance.public com.tivoli.snmp.data.Counter64 createCounter64(long aValue)
Counter64 object.
aValue - The long value to set.
Counter64 instance.public com.tivoli.snmp.data.FixedLengthOctetString createFixedLengthOctetString(String aValue)
FixedLengthOctetString object.
aValue - The String value to set.
FixedLengthOctetString instance.public com.tivoli.snmp.data.FullCounter64 createFullCounter64(BigInteger aValue)
FullCounter64 object.
aValue - The java.math.BigInteger value to set.
FullCounter64 instance.public com.tivoli.snmp.data.Gauge createGauge(long aValue)
Gauge object.
aValue - The long value to set.
Gauge instance.public com.tivoli.snmp.data.IPAddress createIPAddress(String aValue)
IPAddress object.
aValue - The String value to set.
IPAddress instance.public com.tivoli.snmp.data.NoChange createNoChange()
NoChange object.
NoChange instance.public com.tivoli.snmp.data.NoSuchInstance createNoSuchInstance()
NoSuchInstance object.
NoSuchInstance instance.public com.tivoli.snmp.data.NoSuchObject createNoSuchObject()
NoSuchObject object.
NoSuchObject instance.public com.tivoli.snmp.data.NotSupported createNotSupported()
NotSupported object.
NotSupported instance.public com.tivoli.snmp.data.Null createNull()
Null object.
Null instance.public com.tivoli.snmp.data.OctetString createOctetString(String aValue)
OctetString object.
aValue - The String value to set.
OctetString instance.public com.tivoli.snmp.data.OID createOID(String aValue)
OID object.
aValue - The String value to set.
OID instance.public com.tivoli.snmp.data.Opaque createOpaque(byte[] aValue)
Opaque object.
aValue - The byte[] value to set.
Opaque instance.public com.tivoli.snmp.data.TimeTicks createTimeTicks(long aValue)
TimeTicks object.
aValue - The long value to set.
TimeTicks instance.public String getVersion()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||