org.jboss.console.manager
Class PluginManager

java.lang.Object
  extended byorg.jboss.mx.util.JBossNotificationBroadcasterSupport (src) 
      extended byorg.jboss.system.ServiceMBeanSupport (src) 
          extended byorg.jboss.console.manager.PluginManager
All Implemented Interfaces:
java.util.EventListener, MBeanRegistration (src) , NotificationBroadcaster (src) , NotificationEmitter (src) , NotificationListener (src) , Service (src) , ServiceMBean (src)

public class PluginManager
extends ServiceMBeanSupport (src)
implements NotificationListener (src)


Field Summary
protected  ManageableResource (src) bootstrapResource
           
protected  java.util.HashMap currentTrees
           
protected  boolean enableShutdown
           
 java.lang.String jndiName
           
protected  java.lang.String mainLinkUrl
           
protected  java.lang.String mainLogoUrl
           
static java.lang.String PLUGIN_MANAGER_NAME
           
protected  java.util.ArrayList plugins
           
protected  long treeVersion
           
 
Fields inherited from class org.jboss.system.ServiceMBeanSupport (src)
log, server, SERVICE_CONTROLLER_SIG, serviceName
 
Fields inherited from interface org.jboss.system.ServiceMBean (src)
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED
 
Constructor Summary
PluginManager()
           
 
Method Summary
protected  void bindProxyInJndi()
           
 void createService()
          Sub-classes should override this method to provide custum 'create' logic.
protected  java.util.HashSet findSubResources(TreeNode (src)  tree)
           
 ManageableResource (src) getBootstrapResource()
           
 java.lang.String getJndiName()
           
 java.lang.String getMainLinkUrl()
           
 java.lang.String getMainLogoUrl()
           
 MBeanServer (src) getMBeanServer()
           
protected  java.util.ArrayList getPluginsSubsetForProfile(java.lang.String profile)
           
 TreeInfo (src) getTreeForProfile(java.lang.String profile)
           
protected  java.util.Iterator getTreesForResource(ManageableResource (src)  res, java.lang.String profile, java.util.ArrayList pluginsSubset)
           
 TreeInfo (src) getUpdateTreeForProfile(java.lang.String profile, long knownVersion)
          Only return the tree if the actual version is bigger than the known version
 void handleNotification(Notification (src)  notif, java.lang.Object handback)
          Callback method from the broadcaster MBean this listener implementation is registered to.
protected  void initNotificationReception()
           
 boolean isEnableShutdown()
           
 void regenerateAdminTree()
           
 void regenerateAdminTreeForProfile(java.lang.String profile)
           
 void registerPlugin(ConsolePlugin (src)  plugin)
          send a message
 void registerPlugin(java.lang.String consolePluginClassName)
          send a message
 void setEnableShutdown(boolean enableShutdown)
           
 void setJndiName(java.lang.String jndiName)
           
 void setMainLinkUrl(java.lang.String mainLinkUrl)
           
 void setMainLogoUrl(java.lang.String mainLogoUrl)
           
 void startService()
          Sub-classes should override this method to provide custum 'start' logic.
 void stopService()
          Sub-classes should override this method to provide custum 'stop' logic.
 void unregisterPlugin(ConsolePlugin (src)  plugin)
          send a message
 
Methods inherited from class org.jboss.system.ServiceMBeanSupport (src)
create, destroy, destroyService, getLog, getName, getNextNotificationSequenceNumber, getObjectName, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, preDeregister, preRegister, start, stop
 
Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport (src)
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PLUGIN_MANAGER_NAME

public static java.lang.String PLUGIN_MANAGER_NAME

plugins

protected java.util.ArrayList plugins

bootstrapResource

protected ManageableResource (src)  bootstrapResource

jndiName

public java.lang.String jndiName

treeVersion

protected long treeVersion

currentTrees

protected java.util.HashMap currentTrees

mainLogoUrl

protected java.lang.String mainLogoUrl

mainLinkUrl

protected java.lang.String mainLinkUrl

enableShutdown

protected boolean enableShutdown
Constructor Detail

PluginManager

public PluginManager()
Method Detail

createService

public void createService()
                   throws java.lang.Exception
Description copied from class: ServiceMBeanSupport (src)
Sub-classes should override this method to provide custum 'create' logic.

This method is empty, and is provided for convenience when concrete service classes do not need to perform anything specific for this state change.

Overrides:
createService in class ServiceMBeanSupport (src)
Throws:
java.lang.Exception

startService

public void startService()
                  throws java.lang.Exception
Description copied from class: ServiceMBeanSupport (src)
Sub-classes should override this method to provide custum 'start' logic.

This method is empty, and is provided for convenience when concrete service classes do not need to perform anything specific for this state change.

Overrides:
startService in class ServiceMBeanSupport (src)
Throws:
java.lang.Exception

stopService

public void stopService()
Description copied from class: ServiceMBeanSupport (src)
Sub-classes should override this method to provide custum 'stop' logic.

This method is empty, and is provided for convenience when concrete service classes do not need to perform anything specific for this state change.

Overrides:
stopService in class ServiceMBeanSupport (src)

registerPlugin

public void registerPlugin(java.lang.String consolePluginClassName)
                    throws java.lang.Exception
send a message

Throws:
java.lang.Exception

registerPlugin

public void registerPlugin(ConsolePlugin (src)  plugin)
send a message


unregisterPlugin

public void unregisterPlugin(ConsolePlugin (src)  plugin)
send a message


regenerateAdminTree

public void regenerateAdminTree()

regenerateAdminTreeForProfile

public void regenerateAdminTreeForProfile(java.lang.String profile)

getTreeForProfile

public TreeInfo (src)  getTreeForProfile(java.lang.String profile)

getUpdateTreeForProfile

public TreeInfo (src)  getUpdateTreeForProfile(java.lang.String profile,
                                        long knownVersion)
Only return the tree if the actual version is bigger than the known version


getMBeanServer

public MBeanServer (src)  getMBeanServer()

getBootstrapResource

public ManageableResource (src)  getBootstrapResource()

getJndiName

public java.lang.String getJndiName()

setJndiName

public void setJndiName(java.lang.String jndiName)

isEnableShutdown

public boolean isEnableShutdown()

setEnableShutdown

public void setEnableShutdown(boolean enableShutdown)

getMainLinkUrl

public java.lang.String getMainLinkUrl()

setMainLinkUrl

public void setMainLinkUrl(java.lang.String mainLinkUrl)

getMainLogoUrl

public java.lang.String getMainLogoUrl()

setMainLogoUrl

public void setMainLogoUrl(java.lang.String mainLogoUrl)

handleNotification

public void handleNotification(Notification (src)  notif,
                               java.lang.Object handback)
Description copied from interface: NotificationListener (src)
Callback method from the broadcaster MBean this listener implementation is registered to.

Specified by:
handleNotification in interface NotificationListener (src)
Parameters:
notif - the notification object
handback - the handback object given to the broadcaster upon listener registration

getTreesForResource

protected java.util.Iterator getTreesForResource(ManageableResource (src)  res,
                                                 java.lang.String profile,
                                                 java.util.ArrayList pluginsSubset)

getPluginsSubsetForProfile

protected java.util.ArrayList getPluginsSubsetForProfile(java.lang.String profile)

findSubResources

protected java.util.HashSet findSubResources(TreeNode (src)  tree)

bindProxyInJndi

protected void bindProxyInJndi()
                        throws java.lang.Exception
Throws:
java.lang.Exception

initNotificationReception

protected void initNotificationReception()
                                  throws java.lang.Exception
Throws:
java.lang.Exception