import org.jboss.console.manager.interfaces.*;
import org.jboss.console.manager.interfaces.impl.*;
import org.jboss.console.plugins.*;
import org.jboss.console.plugins.helpers.*;


   TreeNode getTreeForResource(ManageableResource resource,
   PluginContext ctx)
   {
      try
      {
         return ctx.createResourceNode ( 
               "J2EE", // name
               "J2EE Management", // description
               "images/elements32.gif", // Icon URL
               null, // Default URL
               null,
               null,
               null,
               new SimpleFolderResource ("ROOT/J2EE")).setVisibility(ResourceTreeNode.INVISIBLE_IF_SUBNODE_EXISTS);
      }
      catch (Exception e)
      {
         e.printStackTrace ();
         return null;
      }
   }
