You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by Jeff Marshall <jm...@cavion.com> on 2001/06/09 19:19:53 UTC

Re: cvs commit: jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/controls Restore.java

Raphael,

I had to add org.apache.turbine.util.Log to the import section to get this to compile.

Jeff

raphael@apache.org wrote:

> raphael     01/06/09 08:33:05
>
>   Modified:    src/java/org/apache/jetspeed/modules/actions/controls
>                         Restore.java
>   Log:
>   catch a PortletException when trying to restore a PortletSet
>
>   Revision  Changes    Path
>   1.4       +12 -3     jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/controls/Restore.java
>
>   Index: Restore.java
>   ===================================================================
>   RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/controls/Restore.java,v
>   retrieving revision 1.3
>   retrieving revision 1.4
>   diff -u -r1.3 -r1.4
>   --- Restore.java      2001/06/04 17:46:45     1.3
>   +++ Restore.java      2001/06/09 15:33:05     1.4
>   @@ -86,11 +86,20 @@
>                return;
>            }
>
>   -        Portlet portlet = PortletFactory.getPortlet( name );
>   -        if (( portlet != null )&&( portlet instanceof PortletState ))
>   +        try
>            {
>   -            ((PortletState)portlet).setMinimized( false, rundata );
>   +            Portlet portlet = PortletFactory.getPortlet( name );
>   +            if (( portlet != null )&&( portlet instanceof PortletState ))
>   +            {
>   +                ((PortletState)portlet).setMinimized( false, rundata );
>   +            }
>            }
>   +        catch (Exception e)
>   +        {
>   +            // this is most likely a normal occurence, ie portlet was removed
>   +            // from registry, portlet is actually a portlet set, etc...
>   +            Log.debug("Exception occured while trying to get portlet "+name);
>   +        }
>
>            // if restore was called because of maximize, remove the maximize state
>            PortalState.reset(rundata);
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org