KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > myfaces > wap > renderkit > WmlRenderer


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.wap.renderkit;
17
18 import javax.faces.component.NamingContainer;
19 import javax.faces.render.Renderer;
20 /**
21  *
22  * @author <a HREF="mailto:Jiri.Zaloudek@ivancice.cz">Jiri Zaloudek</a> (latest modification by $Author: matzew $)
23  * @version $Revision: 1.1 $ $Date: 2004/12/30 09:37:27 $
24  * $Log: WmlRenderer.java,v $
25  * Revision 1.1 2004/12/30 09:37:27 matzew
26  * added a new RenderKit for WML. Thanks to Jirí Žaloudek
27  *
28  */

29 public class WmlRenderer extends Renderer {
30     
31     /** Converts the standard char separator (':') to underscore ('_').
32      * The names of WML variables can consist of any combination of letters, digits, and underscores.
33      */

34     public String JavaDoc convertClientId(javax.faces.context.FacesContext context, String JavaDoc clientId) {
35
36         String JavaDoc retValue = super.convertClientId(context, clientId);
37         retValue = retValue.replace(NamingContainer.SEPARATOR_CHAR, '_');
38
39         return (retValue);
40     }
41 }
42
Popular Tags