All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.myfaces.renderkit.html.HtmlRenderer Maven / Gradle / Ivy

Go to download

The MyFaces Commons Subproject provides base classes for usage in both the MyFaces implementation and the MyFaces Tomahawk components. This is also a general set of utility classes for usage in your JSF projects independent of the implementation you might be deciding upon.

The newest version!
/*
 * Copyright 2004 The Apache Software Foundation.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.apache.myfaces.renderkit.html;

import java.util.List;

import javax.faces.component.UIComponent;
import javax.faces.render.Renderer;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;


/**
 * @author Manfred Geiler (latest modification by $Author: skitching $)
 * @version $Revision: 349370 $ $Date: 2005-11-28 05:01:41 +0000 (Mon, 28 Nov 2005) $
 */
public abstract class HtmlRenderer
        extends Renderer
{
    private static final Log log = LogFactory.getLog(HtmlRenderer.class);

    /**
     * Return the list of children of the specified component.
     * 

* This default implementation simply returns component.getChildren(). * However this method should always be used in order to allow * renderer subclasses to override it and provide filtered or * reordered views of the component children to rendering * methods defined in their ancestor classes. *

* Any method that overrides this to "hide" child components * should also override the getChildCount method. * * @return a list of UIComponent objects. */ public List getChildren(UIComponent component) { return component.getChildren(); } /** * Return the number of children of the specified component. *

* See {@link #getChildren(UIComponent)} for more information. */ public int getChildCount(UIComponent component) { return component.getChildCount(); } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy