/**
* @param jmxServerConnection
* @param name
* @return The value of the given named attribute
* @throws Exception
*/
protected String jmxGet(MBeanServerConnection jmxServerConnection, String name) throws Exception {
String error = null;
if (isEcho()) {
handleOutput("MBean " + name + " get attribute " + attribute);
}
Object result = jmxServerConnection.getAttribute(new ObjectName(name), attribute);
if (result != null) {
echoResult(attribute, result);
createProperty(result);
} else
error = "Attribute " + attribute + " is empty";
return error;
}
JMXAccessorGetTask.java 文件源码
java
阅读 28
收藏 0
点赞 0
评论 0
项目:lazycat
作者:
评论列表
文章目录