FileDocCategorySizeDatePackage
UCLLister.javaAPI DocJBoss 4.2.13500Fri Jul 13 21:02:14 BST 2007org.jboss.console.plugins

UCLLister

public class UCLLister extends org.jboss.console.plugins.helpers.AbstractPluginWrapper
As the number of UCL can be very big, we use a real Java class which is far faster than beanshell
see
author
Sacha Labourey.
version
$Revision: 57191 $

Revisions:

2 janv. 2003 Sacha Labourey:

  • First implementation

Fields Summary
Constructors Summary
public UCLLister()

 super(); 
Methods Summary
org.jboss.console.manager.interfaces.ResourceTreeNodecreateUCLSubResource(javax.management.ObjectInstance instance)

      String uclName = instance.getObjectName().getKeyProperty ("UCL");
            
      return createResourceNode ( 
            "UCL " + uclName, // name
            "UCL with id " + uclName, // description
            "images/service.gif", // Icon URL
            "/jmx-console/HtmlAdaptor?action=inspectMBean&name=" + encode(instance.getObjectName().toString()), // Default URL
            null,
            null,
            null,
            instance.getObjectName().toString(),
            instance.getClassName () );
   
org.jboss.console.manager.interfaces.ResourceTreeNode[]createUCLSubResources()

      ObjectInstance[] insts = 
         getMBeansForClass("jmx.loading:*", 
            "org.jboss.mx.loading.UnifiedClassLoader3");
      
      ResourceTreeNode[] result = new ResourceTreeNode[insts.length];
      for (int i=0; i<result.length; i++)
      {
         result[i] = createUCLSubResource (insts[i]);
      }
      
      return result;                  
   
protected org.jboss.console.manager.interfaces.TreeNodegetTreeForResource(java.lang.String profile, org.jboss.console.manager.interfaces.ManageableResource resource)

      try
      {
         return createTreeNode (
               "Unified ClassLoaders", // name
               "Display all JBoss UCLs", // description
               "images/recycle.gif", // Icon URL
               null, // Default URL
               null,
               null, // sub nodes
               createUCLSubResources ()   // Sub-Resources                  
            );            
      }
      catch (Exception e)
      {
         e.printStackTrace ();
         return null;
      }