MBeanSupport.java 文件源码

java
阅读 27 收藏 0 点赞 0 评论 0

项目:OpenJSharp 作者:
<T> MBeanSupport(T resource, Class<T> mbeanInterfaceType)
        throws NotCompliantMBeanException {
    if (mbeanInterfaceType == null)
        throw new NotCompliantMBeanException("Null MBean interface");
    if (!mbeanInterfaceType.isInstance(resource)) {
        final String msg =
            "Resource class " + resource.getClass().getName() +
            " is not an instance of " + mbeanInterfaceType.getName();
        throw new NotCompliantMBeanException(msg);
    }
    ReflectUtil.checkPackageAccess(mbeanInterfaceType);
    this.resource = resource;
    MBeanIntrospector<M> introspector = getMBeanIntrospector();
    this.perInterface = introspector.getPerInterface(mbeanInterfaceType);
    this.mbeanInfo = introspector.getMBeanInfo(resource, perInterface);
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号