Class PluginContainer

java.lang.Object
ecmwf.common.plugin.PluginContainer
All Implemented Interfaces:
MBeanService, MonitorCallback

public final class PluginContainer extends Object implements MBeanService, MonitorCallback
The Class PluginContainer.
  • Constructor Details

    • PluginContainer

      public PluginContainer(Object caller)
      Instantiates a new plugin container.
      Parameters:
      caller - the caller
  • Method Details

    • getPluginInfos

      public PluginInfo[] getPluginInfos()
      Gets the plugin infos.
      Returns:
      the plugin infos
    • getMonitorManager

      public MonitorManager getMonitorManager(String name) throws MonitorException
      Gets the monitor manager. Gets the monitor manager.
      Specified by:
      getMonitorManager in interface MonitorCallback
      Parameters:
      name - the name
      Returns:
      the monitor manager
      Throws:
      MonitorException - the monitor exception
    • getPluginStatus

      public String getPluginStatus(String ref)
      Gets the plugin status.
      Parameters:
      ref - the ref
      Returns:
      the plugin status
    • loadPlugins

      public void loadPlugins()
      Load plugins.
    • notifyCallerBack

      public void notifyCallerBack(boolean reset)
      Notify caller back.
      Parameters:
      reset - the reset
    • notifyCallerGone

      public void notifyCallerGone()
      Notify caller gone.
    • startPlugin

      public boolean startPlugin(String ref)
      Start plugin.
      Parameters:
      ref - the ref
      Returns:
      true, if successful
    • stopPlugin

      public boolean stopPlugin(String ref)
      Stop plugin.
      Parameters:
      ref - the ref
      Returns:
      true, if successful
    • stopPlugins

      public void stopPlugins()
      Stop plugins.
    • notify

      public void notify(PluginEvent<?>[] events)
      Notify.
      Parameters:
      events - the events
    • handle

      public void handle(PluginEvent<?>[] events)
      Handle.
      Parameters:
      events - the events
    • getAttribute

      public Object getAttribute(String attributeName) throws AttributeNotFoundException, MBeanException
      Gets the attribute. Gets the attribute.
      Specified by:
      getAttribute in interface MBeanService
      Parameters:
      attributeName - the attribute name
      Returns:
      the attribute
      Throws:
      AttributeNotFoundException - the attribute not found exception
      MBeanException - the MBean exception
    • getMBeanInfo

      public MBeanInfo getMBeanInfo()
      Gets the MBean info. Gets the MBean info.
      Specified by:
      getMBeanInfo in interface MBeanService
      Returns:
      the MBean info
    • getPluginStatusUpdateDate

      public Date getPluginStatusUpdateDate(String ref)
      Gets the plugin status update date.
      Parameters:
      ref - the ref
      Returns:
      the plugin status update date
    • invoke

      public Object invoke(String operationName, Object[] params, String[] signature) throws NoSuchMethodException, MBeanException
      Invoke. Invoke.
      Specified by:
      invoke in interface MBeanService
      Parameters:
      operationName - the operation name
      params - the params
      signature - the signature
      Returns:
      the object
      Throws:
      NoSuchMethodException - the no such method exception
      MBeanException - the MBean exception
    • setAttribute

      public boolean setAttribute(String name, Object value)
      Sets the attribute. Sets the attribute.
      Specified by:
      setAttribute in interface MBeanService
      Parameters:
      name - the name
      value - the value
      Returns:
      true, if successful
    • unregisterPlugins

      public void unregisterPlugins()
      Unregister plugins.
    • startPlugins

      public void startPlugins()
      Start plugins.