public class SnmpUtils extends Object
Modifier and Type | Field and Description |
---|---|
static Pattern |
HEX_CHUNK_PATTERN |
static Pattern |
HEX_PATTERN |
Constructor and Description |
---|
SnmpUtils() |
public static final Pattern HEX_PATTERN
public static final Pattern HEX_CHUNK_PATTERN
public static SnmpWalker createWalker(SnmpAgentConfig agentConfig, String name, CollectionTracker... trackers)
public static SnmpWalker createWalker(SnmpAgentConfig agentConfig, String name, CollectionTracker tracker)
public static SnmpValue get(SnmpAgentConfig agentConfig, SnmpObjId oid)
public static SnmpValue[] get(SnmpAgentConfig agentConfig, SnmpObjId[] oids)
public static SnmpValue getNext(SnmpAgentConfig agentConfig, SnmpObjId oid)
public static SnmpValue[] getNext(SnmpAgentConfig agentConfig, SnmpObjId[] oids)
public static SnmpValue[] getBulk(SnmpAgentConfig agentConfig, SnmpObjId[] oids)
public static SnmpValue set(SnmpAgentConfig agentConfig, SnmpObjId oid, SnmpValue value)
public static SnmpValue[] set(SnmpAgentConfig agentConfig, SnmpObjId[] oids, SnmpValue[] values)
public static Properties getConfig()
public static List<SnmpValue> getColumns(SnmpAgentConfig agentConfig, String name, SnmpObjId oid) throws InterruptedException
InterruptedException
public static Map<SnmpInstId,SnmpValue> getOidValues(SnmpAgentConfig agentConfig, String name, SnmpObjId oid) throws InterruptedException
InterruptedException
public static void setConfig(Properties config)
public static SnmpStrategy getStrategy()
public static void registerForTraps(TrapNotificationListener listener, TrapProcessorFactory processorFactory, InetAddress address, int snmpTrapPort, List<SnmpV3User> snmpUsers) throws IOException
IOException
public static void registerForTraps(TrapNotificationListener listener, TrapProcessorFactory processorFactory, InetAddress address, int snmpTrapPort) throws IOException
IOException
public static void unregisterForTraps(TrapNotificationListener listener, InetAddress address, int snmpTrapPort) throws IOException
IOException
public static SnmpValueFactory getValueFactory()
public static SnmpV1TrapBuilder getV1TrapBuilder()
public static SnmpTrapBuilder getV2TrapBuilder()
public static SnmpV3TrapBuilder getV3TrapBuilder()
public static SnmpV2TrapBuilder getV2InformBuilder()
public static SnmpV3TrapBuilder getV3InformBuilder()
public static String getLocalEngineID()
public static String getHexString(byte[] raw)
public static boolean allBytesDisplayable(byte[] bytes)
If the value is in the unprintable ASCII range (< 32) and is not a:
or the byte is Delete (127) then this method will return false. Also, if the byte array has a NULL byte (0) that occurs anywhere besides the last character, return false. We will allow the NULL byte as a special case at the end of the string.
public static Properties loadProperties(org.springframework.core.io.Resource propertiesFile)
loadProperties
propertiesFile
- a Resource
object.Properties
object.Copyright © 2015. All Rights Reserved.