use SigarVersion bean
This commit is contained in:
parent
0a1a3de69f
commit
6ef73dcbcb
|
@ -19,8 +19,6 @@
|
|||
package org.hyperic.sigar.jmx;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.management.AttributeNotFoundException;
|
||||
import javax.management.MBeanConstructorInfo;
|
||||
|
@ -65,8 +63,6 @@ public class SigarRegistry extends AbstractMBean {
|
|||
|
||||
private static final String MBEAN_TYPE = "SigarRegistry";
|
||||
|
||||
private static final Map VERSION_ATTRS = new LinkedHashMap();
|
||||
|
||||
private static final MBeanInfo MBEAN_INFO;
|
||||
|
||||
private static final MBeanConstructorInfo MBEAN_CONSTR_DEFAULT;
|
||||
|
@ -116,12 +112,8 @@ public class SigarRegistry extends AbstractMBean {
|
|||
* @see javax.management.DynamicMBean#getAttribute(java.lang.String)
|
||||
*/
|
||||
public Object getAttribute(String attr) throws AttributeNotFoundException {
|
||||
Object obj = VERSION_ATTRS.get(attr);
|
||||
if (obj == null) {
|
||||
throw new AttributeNotFoundException(attr);
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see javax.management.DynamicMBean#getMBeanInfo()
|
||||
|
|
Loading…
Reference in New Issue