KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > myfaces > custom > collapsiblepanel > HtmlCollapsiblePanelTag


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 package org.apache.myfaces.custom.collapsiblepanel;
17
18 import org.apache.myfaces.taglib.html.ext.HtmlPanelGroupTag;
19
20 import javax.faces.component.UIComponent;
21
22 /**
23  * @author Kalle Korhonen (latest modification by $Author: matzew $)
24  * @version $Revision: 1.2 $ $Date: 2005/02/18 17:19:30 $
25  */

26 public class HtmlCollapsiblePanelTag
27         extends HtmlPanelGroupTag
28 {
29     //private static final Log log = LogFactory.getLog(HtmlCollapsiblePanelTag.class);
30

31     public String JavaDoc getComponentType()
32     {
33         return HtmlCollapsiblePanel.COMPONENT_TYPE;
34     }
35
36     public String JavaDoc getRendererType()
37     {
38         return "org.apache.myfaces.CollapsiblePanel";
39     }
40
41     private String JavaDoc _collapsed;
42     private String JavaDoc _value;
43     // User Role support --> already handled by HtmlPanelGroupTag
44

45     public void release() {
46         super.release();
47         _collapsed=null;
48         _value=null;
49     }
50
51     protected void setProperties(UIComponent component)
52     {
53         super.setProperties(component);
54
55         setBooleanProperty(component, "collapsed", _collapsed);
56         setStringProperty(component, "value", _value);
57
58     }
59
60
61     public void setCollapsed(String JavaDoc collapsed)
62     {
63         _collapsed = collapsed;
64     }
65     
66     public void setValue(String JavaDoc value)
67     {
68         _value = value;
69     }
70 }
71
Popular Tags