2009/05/20 - Apache Shale has been retired.

For more information, please explore the Attic.

View Javadoc

1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one or more
3    * contributor license agreements.  See the NOTICE file distributed with
4    * this work for additional information regarding copyright ownership.
5    * The ASF licenses this file to you under the Apache License, Version 2.0
6    * (the "License"); you may not use this file except in compliance with
7    * the License.  You may obtain a copy of the License at
8    *
9    *      http://www.apache.org/licenses/LICENSE-2.0
10   *
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  
18  package org.apache.shale.dialog.scxml;
19  
20  import java.io.Serializable;
21  
22  /***
23   * <p>Simple POJO properties class that gets stored in the root context
24   * of each state machine instance driving a Shale dialog.</p>
25   *
26   * @since 1.0.4
27   *
28   * $Id: DialogProperties.java 491384 2006-12-31 04:43:49Z rahul $
29   */
30  public class DialogProperties implements Serializable {
31  
32      //--------------------------------------------------------- Constructors
33  
34      /***
35       * This is part of the internal contract of Shale dialogs and should never
36       * need to be instantiated outside the parent package.
37       */
38      DialogProperties() {
39          super();
40      }
41  
42      //---------------------------------  Properties, with getters and setters
43  
44  
45      //------------------------------------------------------------- Redirects
46  
47      /***
48       * Whether the next view rendered by this dialog should use a redirect.
49       */
50      private boolean nextRedirect = false;
51  
52      /***
53       * Should next view rendered by this dialog be redirected.
54       *
55       * @return true, if next view is to be redirected.
56       */
57      public boolean isNextRedirect() {
58          return nextRedirect;
59      }
60  
61      /***
62       * Set next view redirect property.
63       *
64       * @param nextRedirect Whether next view rendered should be redirected.
65       */
66      public void setNextRedirect(boolean nextRedirect) {
67          this.nextRedirect = nextRedirect;
68      }
69  
70  
71      //------------------------------------------------------ View Identifiers
72  
73      /***
74       * The JSF view identifier of the next view to be rendered in
75       * this dialog.
76       */
77      private String nextViewId = null;
78  
79      /***
80       * Get the JSF view identifier of the next view to be rendered in
81       * this dialog.
82       *
83       * @return The JSF view identifier
84       */
85      public String getNextViewId() {
86          return nextViewId;
87      }
88  
89      /***
90       * Set the JSF view identifier of the next view to be rendered in
91       * this dialog.
92       *
93       * @param nextViewId The JSF view identifier
94       */
95      public void setNextViewId(String nextViewId) {
96          this.nextViewId = nextViewId;
97      }
98  
99  
100     //---------------------------------------------- Other instance variables
101 
102     /***
103      * Serial version UID.
104      */
105     private static final long serialVersionUID = 1L;
106 
107 }