public static SnmpManager createSNMPv2c(String host,
int port,
String community)
throws SnmpException {
SnmpContextv2cPool pool;
try {
pool = new SnmpContextv2cPool(host, port);
pool.setCommunity(community);
return new SnmpManager(pool);
} catch (IOException e) {
throw new SnmpException("SNMP communication error: " +
e.getMessage());
}