KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > alfresco > web > ui > repo > tag > SimpleSearchTag


1 /*
2  * Copyright (C) 2005 Alfresco, Inc.
3  *
4  * Licensed under the Mozilla Public License version 1.1
5  * with a permitted attribution clause. You may obtain a
6  * copy of the License at
7  *
8  * http://www.alfresco.org/legal/license.txt
9  *
10  * Unless required by applicable law or agreed to in writing,
11  * software distributed under the License is distributed on an
12  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
13  * either express or implied. See the License for the specific
14  * language governing permissions and limitations under the
15  * License.
16  */

17 package org.alfresco.web.ui.repo.tag;
18
19 import javax.faces.component.UICommand;
20 import javax.faces.component.UIComponent;
21
22 import org.alfresco.web.ui.common.tag.HtmlComponentTag;
23
24 /**
25  * @author Kevin Roast
26  */

27 public class SimpleSearchTag extends HtmlComponentTag
28 {
29    /**
30     * @see javax.faces.webapp.UIComponentTag#getComponentType()
31     */

32    public String JavaDoc getComponentType()
33    {
34       return "org.alfresco.faces.SimpleSearch";
35    }
36
37    /**
38     * @see javax.faces.webapp.UIComponentTag#getRendererType()
39     */

40    public String JavaDoc getRendererType()
41    {
42       // self rendering component
43
return null;
44    }
45
46    /**
47     * @see javax.faces.webapp.UIComponentTag#setProperties(javax.faces.component.UIComponent)
48     */

49    protected void setProperties(UIComponent component)
50    {
51       super.setProperties(component);
52       
53       setActionProperty((UICommand)component, this.action);
54       setActionListenerProperty((UICommand)component, this.actionListener);
55    }
56    
57    /**
58     * @see org.alfresco.web.ui.common.tag.HtmlComponentTag#release()
59     */

60    public void release()
61    {
62       super.release();
63       
64       this.action = null;
65       this.actionListener = null;
66    }
67    
68    /**
69     * Set the action
70     *
71     * @param action the action
72     */

73    public void setAction(String JavaDoc action)
74    {
75       this.action = action;
76    }
77
78    /**
79     * Set the actionListener
80     *
81     * @param actionListener the actionListener
82     */

83    public void setActionListener(String JavaDoc actionListener)
84    {
85       this.actionListener = actionListener;
86    }
87
88
89    /** the action */
90    private String JavaDoc action;
91
92    /** the actionListener */
93    private String JavaDoc actionListener;
94 }
95
Popular Tags