KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > beehive > netui > pageflow > EmptyNestingStackException


1 /*
2  * Copyright 2004 The Apache Software Foundation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  * $Header:$
17  */

18 package org.apache.beehive.netui.pageflow;
19
20
21 /**
22  * Exception that occurs when the user invokes an action in a nested page flow that uses a
23  * <code>{@link org.apache.beehive.netui.pageflow.annotations.Jpf.Forward &#64;Jpf.Forward}(</code>...<code>
24  * returnAction="</code><i>action-name-in-calling-pageflow</i><code>")</code>
25  * annotation, but there is no calling page flow. This can happen in iterative
26  * development mode when you have modified files and caused the web application to be redeployed,
27  * or when the session expires.
28  */

29 public class EmptyNestingStackException extends PageFlowException
30 {
31     public EmptyNestingStackException( String JavaDoc actionName, FlowController fc )
32     {
33         super( actionName, fc );
34     }
35
36     protected Object JavaDoc[] getMessageArgs()
37     {
38         return new Object JavaDoc[]{ getActionName(), getFlowControllerURI() };
39     }
40
41     protected String JavaDoc[] getMessageParts()
42     {
43         return new String JavaDoc[]{ "Empty nesting stack for returned action ", " from Page Flow ", "." };
44     }
45
46     /**
47      * Tell whether the root cause may be session expiration in cases where the requested session ID is different than
48      * the actual session ID. In this case, the answer is <code>true</code>.
49      */

50     public boolean causeMayBeSessionExpiration()
51     {
52         return true;
53     }
54 }
55
Popular Tags