|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.fenyo.gnetwatch.SNMPQuerier
public class SNMPQuerier
An SNMP querier maintains SNMP parameters needed for the manager to talk to an agent.
| Nested Class Summary | |
|---|---|
static interface |
SNMPQuerier.QuerierListener
Interface used to manage asynchronous SNMP answers. |
| Field Summary | |
|---|---|
private java.net.InetAddress |
address
|
private java.lang.String |
community
|
private java.lang.Long |
id
|
private java.lang.String |
last_sysdescr
|
private static Log |
log
|
private java.lang.String |
password_auth
|
private java.lang.String |
password_priv
|
private int |
pdu_max_size
|
private int |
port
|
private int |
retries
|
private int |
sec
|
private boolean |
snmp_capable
|
private SNMPManager |
snmp_manager
|
private Target |
snmp_target
|
private int |
timeout
|
private java.lang.String |
username
|
private int |
version
|
| Constructor Summary | |
|---|---|
protected |
SNMPQuerier()
Default constructor. |
protected |
SNMPQuerier(java.net.InetAddress address,
SNMPManager snmp_manager)
Constructor. |
| Method Summary | |
|---|---|
java.lang.Object |
clone()
|
java.net.InetAddress |
getAddress()
Returns the target address. |
java.lang.String |
getCommunity()
Returns the community string. |
java.lang.Long |
getId()
|
java.util.List<TableEvent> |
getInterfaces()
Gets some columns of the interface list table synchronously. |
java.lang.String |
getLastSysdescr()
Returns the last sysdescr returned. |
java.lang.String |
getPasswordAuth()
Returns the password authentication attribute. |
java.lang.String |
getPasswordPriv()
Returns the password privacy attribute. |
private PDU |
getPDU()
Creates a new empty PDU. |
int |
getPDUMaxSize()
Returns the PDU maximum size attribute. |
int |
getPort()
Returns the agent UDP port attribute. |
int |
getRetries()
Returns the retries attribute. |
int |
getSec()
Returns the security attribute. |
private Snmp |
getSNMP()
Returns the SNMP4J Snmp instance used to perform further SNMP queries. |
SNMPManager |
getSNMPManager()
|
Target |
getSNMPTarget()
|
java.lang.String |
getSysDescr()
Gets the system description OID content synchronously. |
void |
getSysDescr(SNMPQuerier.QuerierListener listener)
Gets the system description OID content asynchronously. |
int |
getTimeout()
Returns the timeout attribute. |
java.lang.String |
getUsername()
Returns the username attribute. |
int |
getVersion()
Returns the version attribute. |
boolean |
isSNMPCapable()
Checks that the associated target has already answered a SNMP query. |
void |
parametersHaveChanged()
Must be called after some setters have been called. |
void |
setAddress(java.net.InetAddress address)
|
void |
setCommunity(java.lang.String community)
Sets the community string attribute. |
protected void |
setId(java.lang.Long id)
|
void |
setLastSysdescr(java.lang.String last_sysdescr)
|
void |
setPasswordAuth(java.lang.String password_auth)
Sets the password authentication attribute. |
void |
setPasswordPriv(java.lang.String password_priv)
Sets the password privacy attribute. |
void |
setPDUMaxSize(int pdu_max_size)
Sets the PDU maximum size attribute. |
void |
setPort(int port)
Sets the agent UDP port attribute. |
void |
setRetries(int retries)
Sets the retries attribute. |
void |
setSec(int sec)
Sets the security attribute. |
private void |
setSNMP(SNMPManager snmp_manager)
|
void |
setSNMPCapable(boolean snmp_capable)
|
void |
setSNMPManager(SNMPManager snmp_manager)
|
void |
setSNMPTarget(Target snmp_target)
|
void |
setTimeout(int timeout)
Sets the timeout attribute. |
void |
setUsername(java.lang.String username)
Sets the username attribute. |
void |
setVersion(int version)
Sets the version attribute. |
void |
update()
Must be called after some setters have been called. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static Log log
private java.lang.Long id
private java.net.InetAddress address
private int version
private int sec
private int retries
private int timeout
private int port
private java.lang.String community
private java.lang.String username
private java.lang.String password_auth
private java.lang.String password_priv
private int pdu_max_size
private boolean snmp_capable
private java.lang.String last_sysdescr
private SNMPManager snmp_manager
private Target snmp_target
| Constructor Detail |
|---|
protected SNMPQuerier(java.net.InetAddress address,
SNMPManager snmp_manager)
address - target address.snmp_manager - SNMPManager instance.protected SNMPQuerier()
none. - | Method Detail |
|---|
public Target getSNMPTarget()
public void setSNMPTarget(Target snmp_target)
public SNMPManager getSNMPManager()
public void setSNMPManager(SNMPManager snmp_manager)
public java.lang.Long getId()
protected void setId(java.lang.Long id)
public java.net.InetAddress getAddress()
none. -
public void setAddress(java.net.InetAddress address)
public boolean isSNMPCapable()
none. -
public void setSNMPCapable(boolean snmp_capable)
public java.lang.String getLastSysdescr()
none. -
public void setLastSysdescr(java.lang.String last_sysdescr)
public void update()
none. - public final void parametersHaveChanged()
none. - public int getVersion()
none. -
public int getSec()
none. -
public int getRetries()
none. -
public int getTimeout()
none. -
public int getPort()
none. -
public java.lang.String getCommunity()
none. -
public java.lang.String getUsername()
none. -
public java.lang.String getPasswordAuth()
none. -
public java.lang.String getPasswordPriv()
none. -
public int getPDUMaxSize()
none. -
public void setVersion(int version)
version - version.public void setSec(int sec)
sec - security attribute.public void setRetries(int retries)
retries - retries attribute.public void setTimeout(int timeout)
timeout - timeout attribute.public void setPort(int port)
port - agent UDP port attribute.public void setCommunity(java.lang.String community)
community - community string attribute.public void setUsername(java.lang.String username)
username - username attribute.public void setPasswordAuth(java.lang.String password_auth)
password_auth - password authentication attribute.public void setPasswordPriv(java.lang.String password_priv)
password_priv - password_privacy attribute.public void setPDUMaxSize(int pdu_max_size)
pdu_max_size - PDU maximum size attribute.private Snmp getSNMP()
none. -
private void setSNMP(SNMPManager snmp_manager)
private PDU getPDU()
none. -
public java.lang.String getSysDescr()
none. -
public void getSysDescr(SNMPQuerier.QuerierListener listener)
listener - listener instance that will be called asynchronously.public java.util.List<TableEvent> getInterfaces()
none. -
public java.lang.Object clone()
clone in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||