portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wea...@apache.org
Subject cvs commit: jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session FailedToCreateNavStateException.java FailedToCreatePortalUrlException.java NavigationalState.java NavigationalStateComponent.java
Date Tue, 20 Jul 2004 18:50:32 GMT
weaver      2004/07/20 11:50:32

  Modified:    jetspeed-api/src/java/org/apache/jetspeed/container/session
                        NavigationalState.java
                        NavigationalStateComponent.java
  Added:       jetspeed-api/src/java/org/apache/jetspeed/container/session
                        FailedToCreateNavStateException.java
                        FailedToCreatePortalUrlException.java
  Log:
  Become a good citizen:
  - create() and createUrl() never return null and throw unchecked exceptions as this should
not happen
    under normal circumstances.
  
  Revision  Changes    Path
  1.2       +5 -1      jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session/NavigationalState.java
  
  Index: NavigationalState.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session/NavigationalState.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- NavigationalState.java	28 May 2004 18:51:55 -0000	1.1
  +++ NavigationalState.java	20 Jul 2004 18:50:32 -0000	1.2
  @@ -90,6 +90,8 @@
        * Necessary to do so per request invocation.
        * 
        * @param context 
  +     * @throws java.lang.IllegalArgumentException if the <code>context</code>
  +     * id <code>null</code>.
        */
       void init(RequestContext context);
       
  @@ -100,6 +102,8 @@
        * 
        * @param page
        * @return The maximized window or null
  +     * @throws java.lang.IllegalArgumentException if <code>page</code> is
  +     * <code>null</code>.
        */
       PortletWindow getMaximizedWindow(Page page);
       
  
  
  
  1.3       +7 -3      jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session/NavigationalStateComponent.java
  
  Index: NavigationalStateComponent.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session/NavigationalStateComponent.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- NavigationalStateComponent.java	1 Jun 2004 20:24:23 -0000	1.2
  +++ NavigationalStateComponent.java	20 Jul 2004 18:50:32 -0000	1.3
  @@ -37,7 +37,9 @@
        * and window states of portlets on a page.
        *  
        * @param context The request context for which this navigational state is valid.
  -     * @return A new navigational state context for the given request.
  +     * @return A new navigational state context for the given request.  This method will
never return <code>null</code>
  +     * @throws FailedToCreateNavStateException if the nav state could not be created. 
Under normal
  +     * circumstances, this should not happen.
        */
       NavigationalState create(RequestContext context);
   
  @@ -61,7 +63,9 @@
        * Creates a Portlet URL representing the URL of the request.
        * 
        * @param context The ubiqitious request context.
  -     * @return A new Portal URL
  +     * @return A new Portal URL.  This method will never return <code>null</code>;
  +     * @throws FailedToCreatePortalUrlException if the portelt url could not be created.
 Under normal
  +     * circumstances, this should not happen.
        */
       PortalURL createURL(RequestContext context);
       
  
  
  
  1.1                  jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session/FailedToCreateNavStateException.java
  
  Index: FailedToCreateNavStateException.java
  ===================================================================
  /*
   * Created on Jul 20, 2004
   *
   * TODO To change the template for this generated file go to
   * Window - Preferences - Java - Code Generation - Code and Comments
   */
  package org.apache.jetspeed.container.session;
  
  import org.apache.jetspeed.exception.JetspeedRuntimeException;
  
  /**
   * <p>
   * FailedToCreateNavStateException
   * </p>
   * <p>
   *  Thrown if an attempt to create a {@link NavigationalState} met with an unexpected
   *  failure. 
   * </p>
   * @author <a href="mailto:weaver@apache.org">Scott T. Weaver</a>
   * @version $Id: FailedToCreateNavStateException.java,v 1.1 2004/07/20 18:50:32 weaver Exp
$
   *
   */
  public class FailedToCreateNavStateException extends JetspeedRuntimeException
  {
  
      /**
       * 
       */
      public FailedToCreateNavStateException()
      {
          super();
          // TODO Auto-generated constructor stub
      }
  
      /**
       * @param arg0
       */
      public FailedToCreateNavStateException( String arg0 )
      {
          super(arg0);
          // TODO Auto-generated constructor stub
      }
  
      /**
       * @param arg0
       */
      public FailedToCreateNavStateException( Throwable arg0 )
      {
          super(arg0);
          // TODO Auto-generated constructor stub
      }
  
      /**
       * @param arg0
       * @param arg1
       */
      public FailedToCreateNavStateException( String arg0, Throwable arg1 )
      {
          super(arg0, arg1);
          // TODO Auto-generated constructor stub
      }
  
  }
  
  
  
  1.1                  jakarta-jetspeed-2/jetspeed-api/src/java/org/apache/jetspeed/container/session/FailedToCreatePortalUrlException.java
  
  Index: FailedToCreatePortalUrlException.java
  ===================================================================
  /*
   * Created on Jul 20, 2004
   *
   * TODO To change the template for this generated file go to
   * Window - Preferences - Java - Code Generation - Code and Comments
   */
  package org.apache.jetspeed.container.session;
  
  import org.apache.jetspeed.exception.JetspeedRuntimeException;
  
  /**
   * <p>
   * FailedToCreatePortalUrl
   * </p>
   * <p>
   *  Thrown if an attempt to create a Portal URL met with an unexpected
   *  failure. 
   * </p>
   * @author <a href="mailto:weaver@apache.org">Scott T. Weaver</a>
   * @version $Id: FailedToCreatePortalUrlException.java,v 1.1 2004/07/20 18:50:32 weaver
Exp $
   *
   */
  public class FailedToCreatePortalUrlException extends JetspeedRuntimeException
  {
  
      /**
       * 
       */
      public FailedToCreatePortalUrlException()
      {
          super();
          // TODO Auto-generated constructor stub
      }
  
      /**
       * @param arg0
       */
      public FailedToCreatePortalUrlException( String arg0 )
      {
          super(arg0);
          // TODO Auto-generated constructor stub
      }
  
      /**
       * @param arg0
       */
      public FailedToCreatePortalUrlException( Throwable arg0 )
      {
          super(arg0);
          // TODO Auto-generated constructor stub
      }
  
      /**
       * @param arg0
       * @param arg1
       */
      public FailedToCreatePortalUrlException( String arg0, Throwable arg1 )
      {
          super(arg0, arg1);
          // TODO Auto-generated constructor stub
      }
  
  }
  
  
  

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


Mime
View raw message