__log.debug( "doAction(" + uri + ")" );
}
/* Perform the action */
PortletServiceFactory serviceFactory = _application.getPortletServiceFactory( );
PortletProxy proxy = ( PortletProxy ) _application.getPortlet( uri.getPortletName( ) );
PortletRequestImpl req = new PortletRequestImpl( proxy, request, serviceFactory );
PortletResponseImpl resp = new PortletResponseImpl( proxy, req, response );
HttpServletRequest hreq = req.getHttpRequest( );
String action = uri.getAction( );
ActionEventImpl event = new ActionEventImpl( action, req, resp );
proxy.actionPerformed( event );
/* Get the URI where to move*/
PortletURI nextURI = event.getNextURI( );
String nextUri;
if ( nextURI != null )
{
nextUri = nextURI.toString( ).substring( request.getContextPath( ).length( ) );
}
else
{
WebflowActionDescriptor webflow = proxy.getDescriptor( ).getWebflowAction( action );
nextUri = ( webflow != null )
? webflow.getReturnURI( event.getReturnCode( ) )
: null;
}