Package org.opennms.netmgt.snmp
Class SnmpAgentConfig
- java.lang.Object
-
- org.opennms.netmgt.snmp.SnmpConfiguration
-
- org.opennms.netmgt.snmp.SnmpAgentConfig
-
- All Implemented Interfaces:
java.io.Serializable
public class SnmpAgentConfig extends SnmpConfiguration implements java.io.Serializable
- Author:
- (various previous authors not documented), David Hustace
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
AGENT_CONFIG_PREFIX
static java.lang.String
PROFILE_LABEL_FOR_DEFAULT_CONFIG
-
Fields inherited from class org.opennms.netmgt.snmp.SnmpConfiguration
AUTH_NOPRIV, AUTH_PRIV, DEFAULT_AUTH_PASS_PHRASE, DEFAULT_AUTH_PROTOCOL, DEFAULT_CONTEXT_ENGINE_ID, DEFAULT_CONTEXT_NAME, DEFAULT_ENGINE_ID, DEFAULT_MAX_REPETITIONS, DEFAULT_MAX_REQUEST_SIZE, DEFAULT_MAX_VARS_PER_PDU, DEFAULT_PORT, DEFAULT_PRIV_PASS_PHRASE, DEFAULT_PRIV_PROTOCOL, DEFAULT_READ_COMMUNITY, DEFAULT_RETRIES, DEFAULT_SECURITY_LEVEL, DEFAULT_SECURITY_NAME, DEFAULT_TIMEOUT, DEFAULT_VERSION, DEFAULT_WRITE_COMMUNITY, DEFAULTS, NOAUTH_NOPRIV, VERSION_UNSPECIFIED, VERSION1, VERSION2C, VERSION3
-
-
Constructor Summary
Constructors Constructor Description SnmpAgentConfig()
SnmpAgentConfig(java.net.InetAddress agentAddress)
SnmpAgentConfig(java.net.InetAddress agentAddress, SnmpConfiguration defaults)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
static SnmpAgentConfig
fromMap(java.util.Map<java.lang.String,java.lang.String> map)
java.net.InetAddress
getAddress()
java.net.InetAddress
getEffectiveAddress()
java.lang.String
getProfileLabel()
java.net.InetAddress
getProxyFor()
int
hashCode()
boolean
isDefault()
static SnmpAgentConfig
parseProtocolConfigurationString(java.lang.String protocolConfigString)
void
setAddress(java.net.InetAddress address)
void
setDefault(boolean isDefault)
void
setProfileLabel(java.lang.String profileLabel)
void
setProxyFor(java.net.InetAddress address)
java.util.Map<java.lang.String,java.lang.String>
toMap()
java.lang.String
toProtocolConfigString()
java.lang.String
toString()
Don't expose credentials here in plaintext in case this object is used in a log message.-
Methods inherited from class org.opennms.netmgt.snmp.SnmpConfiguration
getAuthPassPhrase, getAuthProtocol, getContextEngineId, getContextName, getEngineId, getEnterpriseId, getMaxRepetitions, getMaxRequestSize, getMaxVarsPerPdu, getPort, getPrivPassPhrase, getPrivProtocol, getReadCommunity, getRetries, getSecurityLevel, getSecurityName, getTimeout, getTTL, getVersion, getVersionAsString, getWriteCommunity, isVersion3, setAuthPassPhrase, setAuthProtocol, setContextEngineId, setContextName, setEngineId, setEnterpriseId, setMaxRepetitions, setMaxRequestSize, setMaxVarsPerPdu, setPort, setPrivPassPhrase, setPrivProtocol, setReadCommunity, setRetries, setSecurityLevel, setSecurityName, setTimeout, setTTL, setVersion, setVersionAsString, setWriteCommunity, stringToVersion, versionToString
-
-
-
-
Field Detail
-
PROFILE_LABEL_FOR_DEFAULT_CONFIG
public static final java.lang.String PROFILE_LABEL_FOR_DEFAULT_CONFIG
- See Also:
- Constant Field Values
-
AGENT_CONFIG_PREFIX
public static final java.lang.String AGENT_CONFIG_PREFIX
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SnmpAgentConfig
public SnmpAgentConfig()
-
SnmpAgentConfig
public SnmpAgentConfig(java.net.InetAddress agentAddress)
-
SnmpAgentConfig
public SnmpAgentConfig(java.net.InetAddress agentAddress, SnmpConfiguration defaults)
-
-
Method Detail
-
parseProtocolConfigurationString
public static SnmpAgentConfig parseProtocolConfigurationString(java.lang.String protocolConfigString)
-
toProtocolConfigString
public java.lang.String toProtocolConfigString()
-
toString
public java.lang.String toString()
Don't expose credentials here in plaintext in case this object is used in a log message. http://issues.opennms.org/browse/NMS-1504- Overrides:
toString
in classjava.lang.Object
-
getAddress
public java.net.InetAddress getAddress()
-
setAddress
public void setAddress(java.net.InetAddress address)
-
getProxyFor
public java.net.InetAddress getProxyFor()
-
setProxyFor
public void setProxyFor(java.net.InetAddress address)
-
getEffectiveAddress
public java.net.InetAddress getEffectiveAddress()
-
isDefault
public boolean isDefault()
-
setDefault
public void setDefault(boolean isDefault)
-
getProfileLabel
public java.lang.String getProfileLabel()
-
setProfileLabel
public void setProfileLabel(java.lang.String profileLabel)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
toMap
public java.util.Map<java.lang.String,java.lang.String> toMap()
-
fromMap
public static SnmpAgentConfig fromMap(java.util.Map<java.lang.String,java.lang.String> map)
-
-