org.alfresco.web.app.servlet.ajax
Class InvokeCommand

java.lang.Object
  extended by org.alfresco.web.app.servlet.ajax.BaseAjaxCommand
      extended by org.alfresco.web.app.servlet.ajax.InvokeCommand
All Implemented Interfaces:
AjaxCommand

public class InvokeCommand
extends BaseAjaxCommand

Command that invokes the method represented by the expression.

The managed bean method called is responsible for writing the response by getting hold of the JSF ResponseWriter. Parameters can also be retrieved via the JSF ExternalContext object.

In a future release (if required) annotations may be used to state what content type to use for the response.


Nested Class Summary
static interface InvokeCommand.ResponseMimetype
          Annotation for a bean method that handles an ajax request.
 
Field Summary
 
Fields inherited from class org.alfresco.web.app.servlet.ajax.BaseAjaxCommand
logger
 
Constructor Summary
InvokeCommand()
           
 
Method Summary
 void execute(javax.faces.context.FacesContext facesContext, java.lang.String expression, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Invokes the relevant method on the bean represented by the given expression.
 
Methods inherited from class org.alfresco.web.app.servlet.ajax.BaseAjaxCommand
makeBindingExpression
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InvokeCommand

public InvokeCommand()
Method Detail

execute

public void execute(javax.faces.context.FacesContext facesContext,
                    java.lang.String expression,
                    javax.servlet.http.HttpServletRequest request,
                    javax.servlet.http.HttpServletResponse response)
             throws javax.servlet.ServletException,
                    java.io.IOException
Description copied from interface: AjaxCommand
Invokes the relevant method on the bean represented by the given expression. Parameters required to call the method can be retrieved from the request. Currently the content type of the response will always be text/xml, in the future sublcasses may provide a mechanism to allow the content type to be set dynamically.

Parameters:
facesContext - FacesContext
expression - The binding expression
request - The request
response - The response
Throws:
javax.servlet.ServletException
java.io.IOException


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.