KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > alfresco > web > bean > wizard > NewForumWizard


1 /*
2  * Copyright (C) 2005 Alfresco, Inc.
3  *
4  * Licensed under the GNU Lesser General Public License as
5  * published by the Free Software Foundation; either version
6  * 2.1 of the License, or (at your option) any later version.
7  * You may obtain a copy of the License at
8  *
9  * http://www.gnu.org/licenses/lgpl.txt
10  *
11  * Unless required by applicable law or agreed to in writing,
12  * software distributed under the License is distributed on an
13  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
14  * either express or implied. See the License for the specific
15  * language governing permissions and limitations under the
16  * License.
17  */

18 package org.alfresco.web.bean.wizard;
19
20 import org.alfresco.model.ForumModel;
21 import org.alfresco.web.app.AlfrescoNavigationHandler;
22
23 /**
24  * Wizard bean used for creating and editing forum spaces
25  *
26  * @author gavinc
27  */

28 public class NewForumWizard extends NewSpaceWizard
29 {
30    /**
31     * @see org.alfresco.web.bean.wizard.AbstractWizardBean#init()
32     */

33    public void init()
34    {
35       super.init();
36       
37       this.spaceType = ForumModel.TYPE_FORUM.toString();
38    }
39    
40    /**
41     * @see org.alfresco.web.bean.wizard.AbstractWizardBean#finish()
42     */

43    @Override JavaDoc
44    public String JavaDoc finish()
45    {
46       String JavaDoc outcome = super.finish();
47       
48       // if we had a successful outcome from the creation close the dialog
49
if (outcome != null);
50       {
51          outcome = AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
52       }
53       
54       return outcome;
55    }
56
57    /**
58     * @see org.alfresco.web.bean.wizard.AbstractWizardBean#cancel()
59     */

60    @Override JavaDoc
61    public String JavaDoc cancel()
62    {
63       super.cancel();
64       
65       return AlfrescoNavigationHandler.CLOSE_DIALOG_OUTCOME;
66    }
67 }
68
Popular Tags