本文整理汇总了Java中sun.management.snmp.util.SnmpTableHandler.contains方法的典型用法代码示例。如果您正苦于以下问题:Java SnmpTableHandler.contains方法的具体用法?Java SnmpTableHandler.contains怎么用?Java SnmpTableHandler.contains使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sun.management.snmp.util.SnmpTableHandler
的用法示例。
在下文中一共展示了SnmpTableHandler.contains方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: contains
import sun.management.snmp.util.SnmpTableHandler; //导入方法依赖的package包/类
protected boolean contains(SnmpOid oid, Object userData) {
// Get the handler.
//
SnmpTableHandler handler = getHandler(userData);
// handler should never be null.
//
if (handler == null)
return false;
if(!handler.contains(oid))
return false;
JvmThreadInstanceEntryImpl inst = getJvmThreadInstance(userData, oid);
return (inst != null);
}
示例2: contains
import sun.management.snmp.util.SnmpTableHandler; //导入方法依赖的package包/类
protected boolean contains(SnmpOid oid, Object userData) {
// Get the handler.
//
SnmpTableHandler handler = getHandler(userData);
// handler should never be null.
//
if (handler == null)
return false;
return handler.contains(oid);
}
示例3: getEntry
import sun.management.snmp.util.SnmpTableHandler; //导入方法依赖的package包/类
public Object getEntry(SnmpOid oid)
throws SnmpStatusException {
log.debug("*** **** **** **** getEntry", "oid [" + oid + "]");
if (oid == null || oid.getLength() != 8) {
log.debug("getEntry", "Invalid oid [" + oid + "]");
throw new SnmpStatusException(SnmpStatusException.noSuchInstance);
}
// Get the request contextual cache (userData).
//
final Map<Object,Object> m = JvmContextFactory.getUserData();
// Get the handler.
//
SnmpTableHandler handler = getHandler(m);
// handler should never be null.
//
if (handler == null || !handler.contains(oid))
throw new SnmpStatusException(SnmpStatusException.noSuchInstance);
final JvmThreadInstanceEntryImpl entry = getJvmThreadInstance(m,oid);
if (entry == null)
throw new SnmpStatusException(SnmpStatusException.noSuchInstance);
return entry;
}
示例4: getEntry
import sun.management.snmp.util.SnmpTableHandler; //导入方法依赖的package包/类
public Object getEntry(SnmpOid oid)
throws SnmpStatusException {
log.debug("*** **** **** **** getEntry", "oid [" + oid + "]");
if (oid == null || oid.getLength() != 8) {
log.debug("getEntry", "Invalid oid [" + oid + "]");
throw new SnmpStatusException(SnmpStatusException.noSuchInstance);
}
// Get the request contextual cache (userData).
//
final Map m = JvmContextFactory.getUserData();
// Get the handler.
//
SnmpTableHandler handler = getHandler(m);
// handler should never be null.
//
if (handler == null || !handler.contains(oid))
throw new SnmpStatusException(SnmpStatusException.noSuchInstance);
final JvmThreadInstanceEntryImpl entry = getJvmThreadInstance(m,oid);
if (entry == null)
throw new SnmpStatusException(SnmpStatusException.noSuchInstance);
return entry;
}