Sun Java System Portal Server 7.1 Developer's Guide

DesktopServlet process Action


DesktopServletURL?action=process&provider=editContainer&targetprovider=channelName

In this URL, the provider parameter specifies the edit container for the container, and the targetprovider parameter is the leaf channel inside the container. When the DesktopServlet receives a request where the action is process (see Action process), the DesktopServlet:

  1. Determines whether the edit container is editable.

    If the edit container is not editable, an exception is thrown on the Desktop and control is returned to the web container. If the edit container is editable, it calls the edit container processEdit() method and determines the channel’s name from the request parameter.

  2. Once the channel name is determined, it determines whether the channel is editable.

    If the channel is not editable, it throws a provider exception. If the channel is determined to be editable, it calls the channel’s processEdit() method.

  3. Re-directs to the URL returned from the provider’s processEdit() method.

    If there is an InvalidEditFormDataException, the DesktopServlet will redirect the browser back to the channel’s edit page and include a URL parameter error so that the channel may display the cause of the exception to the user. That is, the DesktopServlet will get the error message and generate a new request as follows:


    DesktopServletURL?action=edit&provider=channelName&error=errormessage
    

    If there is no InvalidEditFormDataException, the DesktopServlet generates the new URL and returns control to the web container.

Figure 3–5 DesktopServlet process Action

This flowchart shows the DesktopServlet process action.