org.apache.servicemix.console
Class ServiceMixPortlet

java.lang.Object
  extended by javax.portlet.GenericPortlet
      extended by org.apache.servicemix.console.ServiceMixPortlet
All Implemented Interfaces:
javax.portlet.Portlet, javax.portlet.PortletConfig
Direct Known Subclasses:
JBIAuditPortlet, JBIComponentsPortlet, JBIContainerPortlet

public abstract class ServiceMixPortlet
extends javax.portlet.GenericPortlet


Field Summary
protected  javax.portlet.PortletRequestDispatcher errorView
           
protected  javax.portlet.PortletRequestDispatcher helpView
           
protected  Log log
           
protected  javax.portlet.PortletRequestDispatcher normalView
           
 
Constructor Summary
ServiceMixPortlet()
           
 
Method Summary
protected  void closeConnector()
           
 void destroy()
           
protected  void doHelp(javax.portlet.RenderRequest renderRequest, javax.portlet.RenderResponse renderResponse)
           
protected  void doProcessAction(javax.portlet.ActionRequest actionRequest, javax.portlet.ActionResponse actionResponse)
           
protected  void doView(javax.portlet.RenderRequest renderRequest, javax.portlet.RenderResponse renderResponse)
           
protected  void fillViewRequest(javax.portlet.RenderRequest request)
           
protected  String getConfigString(String name, String defValue)
           
 String getContainerName()
           
 DeploymentServiceMBean getDeploymentService()
          Get the DeploymentServiceMBean
 InstallationServiceMBean getInstallationService()
          Get the InstallationServiceMBean
 LifeCycleMBean getJBIContainer()
           
 AuditorMBean getJdbcAuditor()
           
 JMXConnector getJMXConnector(JMXServiceURL url)
          Get a JMXConnector from a url
 ManagementContextMBean getManagementContext()
          Get the ManagementContextMBean
protected  ObjectName getObjectName(Class systemClass)
          Get a servicemix internal system management instance, from it's class name
protected  String getPassword()
           
 Object getProxy(ObjectName name, Class type)
           
 MBeanServerConnection getServerConnection()
           
 JMXServiceURL getServiceURL()
          Get the JMXServiceURL - built from the protocol used and host names
protected  String getUsername()
           
 void init(javax.portlet.PortletConfig portletConfig)
           
 void processAction(javax.portlet.ActionRequest actionRequest, javax.portlet.ActionResponse actionResponse)
           
protected  void renderView(javax.portlet.RenderRequest renderRequest, javax.portlet.RenderResponse renderResponse)
           
 void setContainerName(String containerName)
           
protected  void setPassword(String password)
           
protected  void setUsername(String username)
           
 
Methods inherited from class javax.portlet.GenericPortlet
doDispatch, doEdit, getInitParameter, getInitParameterNames, getPortletConfig, getPortletContext, getPortletName, getResourceBundle, getTitle, init, render
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected final Log log

normalView

protected javax.portlet.PortletRequestDispatcher normalView

helpView

protected javax.portlet.PortletRequestDispatcher helpView

errorView

protected javax.portlet.PortletRequestDispatcher errorView
Constructor Detail

ServiceMixPortlet

public ServiceMixPortlet()
Method Detail

getServiceURL

public JMXServiceURL getServiceURL()
Get the JMXServiceURL - built from the protocol used and host names

Returns:
the url

getJMXConnector

public JMXConnector getJMXConnector(JMXServiceURL url)
                             throws IOException
Get a JMXConnector from a url

Parameters:
url -
Returns:
the JMXConnector
Throws:
IOException

doHelp

protected void doHelp(javax.portlet.RenderRequest renderRequest,
                      javax.portlet.RenderResponse renderResponse)
               throws javax.portlet.PortletException,
                      IOException
Overrides:
doHelp in class javax.portlet.GenericPortlet
Throws:
javax.portlet.PortletException
IOException

doView

protected void doView(javax.portlet.RenderRequest renderRequest,
                      javax.portlet.RenderResponse renderResponse)
               throws javax.portlet.PortletException,
                      IOException
Overrides:
doView in class javax.portlet.GenericPortlet
Throws:
javax.portlet.PortletException
IOException

renderView

protected void renderView(javax.portlet.RenderRequest renderRequest,
                          javax.portlet.RenderResponse renderResponse)
                   throws Exception
Throws:
Exception

getObjectName

protected ObjectName getObjectName(Class systemClass)
Get a servicemix internal system management instance, from it's class name

Parameters:
systemClass -
Returns:
the object name

fillViewRequest

protected void fillViewRequest(javax.portlet.RenderRequest request)
                        throws Exception
Throws:
Exception

init

public void init(javax.portlet.PortletConfig portletConfig)
          throws javax.portlet.PortletException
Specified by:
init in interface javax.portlet.Portlet
Overrides:
init in class javax.portlet.GenericPortlet
Throws:
javax.portlet.PortletException

getConfigString

protected String getConfigString(String name,
                                 String defValue)

processAction

public void processAction(javax.portlet.ActionRequest actionRequest,
                          javax.portlet.ActionResponse actionResponse)
                   throws javax.portlet.PortletException,
                          IOException
Specified by:
processAction in interface javax.portlet.Portlet
Overrides:
processAction in class javax.portlet.GenericPortlet
Throws:
javax.portlet.PortletException
IOException

doProcessAction

protected void doProcessAction(javax.portlet.ActionRequest actionRequest,
                               javax.portlet.ActionResponse actionResponse)
                        throws Exception
Throws:
Exception

destroy

public void destroy()
Specified by:
destroy in interface javax.portlet.Portlet
Overrides:
destroy in class javax.portlet.GenericPortlet

closeConnector

protected void closeConnector()

getInstallationService

public InstallationServiceMBean getInstallationService()
                                                throws IOException
Get the InstallationServiceMBean

Returns:
the installation service MBean
Throws:
IOException

getDeploymentService

public DeploymentServiceMBean getDeploymentService()
                                            throws IOException
Get the DeploymentServiceMBean

Returns:
the deployment service mbean
Throws:
IOException

getManagementContext

public ManagementContextMBean getManagementContext()
                                            throws IOException
Get the ManagementContextMBean

Returns:
the management service mbean
Throws:
IOException

getJdbcAuditor

public AuditorMBean getJdbcAuditor()
                            throws IOException
Throws:
IOException

getJBIContainer

public LifeCycleMBean getJBIContainer()
                               throws IOException
Throws:
IOException

getProxy

public Object getProxy(ObjectName name,
                       Class type)
                throws IOException
Throws:
IOException

getServerConnection

public MBeanServerConnection getServerConnection()
                                          throws IOException
Throws:
IOException

getContainerName

public String getContainerName()

setContainerName

public void setContainerName(String containerName)

getPassword

protected String getPassword()
Returns:
the password

setPassword

protected void setPassword(String password)
Parameters:
password - the password to set

getUsername

protected String getUsername()
Returns:
the username

setUsername

protected void setUsername(String username)
Parameters:
username - the username to set


Copyright © 2005-2009 Apache Software Foundation. All Rights Reserved.