Added MBean description
This commit is contained in:
parent
3d6727d221
commit
e04bf81085
|
@ -31,7 +31,7 @@ public interface DefaultEnumInstanceᴶᴹˣ<T,K extends BãßBȍőnCoffinStoreK
|
||||||
|
|
||||||
MBeanServer server = ManagementFactory.getPlatformMBeanServer();
|
MBeanServer server = ManagementFactory.getPlatformMBeanServer();
|
||||||
ObjectName objectName1 = new ObjectName(name.toString());
|
ObjectName objectName1 = new ObjectName(name.toString());
|
||||||
server.registerMBean(new MBeanDynamicᴶᴹˣ(GET_BBC().GET_MAP_OBJ(key)), objectName1);
|
server.registerMBean(new MBeanDynamicᴶᴹˣ(BãßClassPurpose(), GET_BBC().GET_MAP_OBJ(key)), objectName1);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,7 +35,7 @@ public interface DefaultEnumSetᴶᴹˣ<T,K extends BãßBȍőnCoffinStoreKeyʸ
|
||||||
|
|
||||||
MBeanServer server = ManagementFactory.getPlatformMBeanServer();
|
MBeanServer server = ManagementFactory.getPlatformMBeanServer();
|
||||||
ObjectName objectName1 = new ObjectName(name.toString());
|
ObjectName objectName1 = new ObjectName(name.toString());
|
||||||
server.registerMBean(new MBeanDynamicᴶᴹˣ(GET_BBC().GET_MAP_OBJ(key)), objectName1);
|
server.registerMBean(new MBeanDynamicᴶᴹˣ(BãßClassPurpose(), GET_BBC().GET_MAP_OBJ(key)), objectName1);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,9 +20,11 @@ import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
||||||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||||
public class MBeanDynamicᴶᴹˣ implements DynamicMBean {
|
public class MBeanDynamicᴶᴹˣ implements DynamicMBean {
|
||||||
|
|
||||||
|
private final String description;
|
||||||
private final Map<String, Object> guages;
|
private final Map<String, Object> guages;
|
||||||
|
|
||||||
public MBeanDynamicᴶᴹˣ(Map<String, Object> guages) {
|
public MBeanDynamicᴶᴹˣ(String description, Map<String, Object> guages) {
|
||||||
|
this.description = description;
|
||||||
this.guages = guages;
|
this.guages = guages;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -36,7 +38,7 @@ public class MBeanDynamicᴶᴹˣ implements DynamicMBean {
|
||||||
dAttributes[i] = new MBeanAttributeInfo(gc.getName(), gc.BãßValueType().getSimpleName(),
|
dAttributes[i] = new MBeanAttributeInfo(gc.getName(), gc.BãßValueType().getSimpleName(),
|
||||||
gc.getDescription(), true, false, false);
|
gc.getDescription(), true, false, false);
|
||||||
}
|
}
|
||||||
return new MBeanInfo(this.getClass().getName(), null, dAttributes, null, null,
|
return new MBeanInfo(this.getClass().getName(), description, dAttributes, null, null,
|
||||||
new MBeanNotificationInfo[0]);
|
new MBeanNotificationInfo[0]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue