KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > facelets > tag > jsf > core > CoreLibrary


1 /**
2  * Licensed under the Common Development and Distribution License,
3  * you may not use this file except in compliance with the License.
4  * You may obtain a copy of the License at
5  *
6  * http://www.sun.com/cddl/
7  *
8  * Unless required by applicable law or agreed to in writing, software
9  * distributed under the License is distributed on an "AS IS" BASIS,
10  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
11  * implied. See the License for the specific language governing
12  * permissions and limitations under the License.
13  */

14
15 package com.sun.facelets.tag.jsf.core;
16
17 import javax.faces.component.UIOutput;
18 import javax.faces.component.UIParameter;
19 import javax.faces.component.UISelectItem;
20 import javax.faces.component.UISelectItems;
21 import javax.faces.convert.DateTimeConverter;
22 import javax.faces.convert.NumberConverter;
23 import javax.faces.validator.DoubleRangeValidator;
24 import javax.faces.validator.LengthValidator;
25 import javax.faces.validator.LongRangeValidator;
26
27 import com.sun.facelets.tag.AbstractTagLibrary;
28
29 /**
30  * For Tag details, see JSF Core <a target="_new"
31  * HREF="http://java.sun.com/j2ee/javaserverfaces/1.1_01/docs/tlddocs/f/tld-summary.html">taglib
32  * documentation</a>.
33  *
34  * @author Jacob Hookom
35  * @version $Id: CoreLibrary.java,v 1.9 2006/06/12 05:20:23 jhook Exp $
36  */

37 public final class CoreLibrary extends AbstractTagLibrary {
38
39     public final static String JavaDoc Namespace = "http://java.sun.com/jsf/core";
40
41     public final static CoreLibrary Instance = new CoreLibrary();
42
43     public CoreLibrary() {
44         super(Namespace);
45
46         this.addTagHandler("actionListener", ActionListenerHandler.class);
47
48         this.addTagHandler("attribute", AttributeHandler.class);
49
50         this.addConverter("convertDateTime", DateTimeConverter.CONVERTER_ID, ConvertDateTimeHandler.class);
51
52         this.addConverter("convertNumber", NumberConverter.CONVERTER_ID, ConvertNumberHandler.class);
53
54         this.addConverter("converter", null, ConvertDelegateHandler.class);
55
56         this.addTagHandler("facet", FacetHandler.class);
57
58         this.addTagHandler("loadBundle", LoadBundleHandler.class);
59
60         this.addComponent("param", UIParameter.COMPONENT_TYPE, null);
61
62         this.addComponent("selectItem", UISelectItem.COMPONENT_TYPE, null);
63
64         this.addComponent("selectItems", UISelectItems.COMPONENT_TYPE, null);
65         
66         this.addTagHandler("setPropertyActionListener", SetPropertyActionListenerHandler.class);
67         
68         this.addComponent("subview", "javax.faces.NamingContainer", null);
69         
70         this.addValidator("validateLength", LengthValidator.VALIDATOR_ID);
71         
72         this.addValidator("validateLongRange", LongRangeValidator.VALIDATOR_ID);
73         
74         this.addValidator("validateDoubleRange", DoubleRangeValidator.VALIDATOR_ID);
75
76         this.addValidator("validator", null, ValidateDelegateHandler.class);
77
78         this.addTagHandler("valueChangeListener",
79                 ValueChangeListenerHandler.class);
80
81         this.addTagHandler("view", ViewHandler.class);
82         
83         this.addComponent("verbatim", "javax.faces.HtmlOutputText",
84                           "javax.faces.Text", VerbatimHandler.class);
85     }
86 }
87
Popular Tags