public static SnmpOidTable getOidTable() { SnmpOidTable table = null; if(tableRef == null) { table = new JVM_MANAGEMENT_MIBOidTable(); tableRef = new WeakReference<>(table); return table; } table = tableRef.get(); if(table == null) { table = new JVM_MANAGEMENT_MIBOidTable(); tableRef = new WeakReference<>(table); } return table; }
public static SnmpOidTable getOidTable() { SnmpOidTable table = null; if(tableRef == null) { table = new JVM_MANAGEMENT_MIBOidTable(); tableRef = new WeakReference<SnmpOidTable>(table); return table; } table = tableRef.get(); if(table == null) { table = new JVM_MANAGEMENT_MIBOidTable(); tableRef = new WeakReference<SnmpOidTable>(table); } return table; }
public static String getJvmThreadInstIndexOid() throws SnmpStatusException { if (jvmThreadInstIndexOid == null) { final SnmpOidTable table = new JVM_MANAGEMENT_MIBOidTable(); final SnmpOidRecord record = table.resolveVarName("jvmThreadInstIndex"); jvmThreadInstIndexOid = record.getOid(); } return jvmThreadInstIndexOid; }