本文整理汇总了Java中javax.management.MBeanInfo.getDescription方法的典型用法代码示例。如果您正苦于以下问题:Java MBeanInfo.getDescription方法的具体用法?Java MBeanInfo.getDescription怎么用?Java MBeanInfo.getDescription使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类javax.management.MBeanInfo
的用法示例。
在下文中一共展示了MBeanInfo.getDescription方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getColumnText
import javax.management.MBeanInfo; //导入方法依赖的package包/类
@Override
public String getColumnText(Object element, int columnIndex) {
// 0:ObjectName | 1:Class Name | 2:Description
MBeanModel model = (MBeanModel) element;
MBean mbean = model.getData();
MBeanInfo info = mbean.getInfo();
switch (columnIndex) {
case 0:
return mbean.getObjectName().toString();
case 1:
return info.getClassName();
case 2:
return info.getDescription();
}
return null;
}
示例2: getMBeanInfo
import javax.management.MBeanInfo; //导入方法依赖的package包/类
/**
* Return the MBeanInfo for the given resource, based on the given
* per-interface data.
*/
final MBeanInfo getMBeanInfo(Object resource, PerInterface<M> perInterface) {
MBeanInfo mbi =
getClassMBeanInfo(resource.getClass(), perInterface);
MBeanNotificationInfo[] notifs = findNotifications(resource);
if (notifs == null || notifs.length == 0)
return mbi;
else {
return new MBeanInfo(mbi.getClassName(),
mbi.getDescription(),
mbi.getAttributes(),
mbi.getConstructors(),
mbi.getOperations(),
notifs,
mbi.getDescriptor());
}
}
示例3: getMBeanInfo
import javax.management.MBeanInfo; //导入方法依赖的package包/类
@Override
public MBeanInfo getMBeanInfo() {
MBeanInfo mbi = super.getMBeanInfo();
Class<?> resourceClass = getResource().getClass();
if (StandardMBeanIntrospector.isDefinitelyImmutableInfo(resourceClass))
return mbi;
return new MBeanInfo(mbi.getClassName(), mbi.getDescription(),
mbi.getAttributes(), mbi.getConstructors(),
mbi.getOperations(),
MBeanIntrospector.findNotifications(getResource()),
mbi.getDescriptor());
}