// WARNING: This file was automatically generated. Do not edit it directly,
//          or you will lose your changes.
/*
 *  Licensed to the Apache Software Foundation (ASF) under one
 *  or more contributor license agreements.  See the NOTICE file
 *  distributed with this work for additional information
 *  regarding copyright ownership.  The ASF licenses this file
 *  to you 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.custom.tree.taglib;

import javax.faces.component.UIComponent;
import javax.faces.el.ValueBinding;
import javax.faces.context.FacesContext;
import org.apache.myfaces.custom.tree.model.TreeModel;


// Generated from class org.apache.myfaces.custom.tree.HtmlTree.
//
// WARNING: This file was automatically generated. Do not edit it directly,
//          or you will lose your changes.
public class TreeTag
    extends org.apache.myfaces.custom.tree.taglib.AbstractTreeTag
{
    public TreeTag()
    {    
    }
    
    public String getComponentType()
    {
        return "org.apache.myfaces.HtmlTree";
    }

    public String getRendererType()
    {
        return "org.apache.myfaces.HtmlTree";
    }

 
    private String _var;
    
    public void setVar(String var)
    {
        _var = var;
    }
 
    private String _iconLine;
    
    public void setIconLine(String iconLine)
    {
        _iconLine = iconLine;
    }
 
    private String _iconNoline;
    
    public void setIconNoline(String iconNoline)
    {
        _iconNoline = iconNoline;
    }
 
    private String _iconChildFirst;
    
    public void setIconChildFirst(String iconChildFirst)
    {
        _iconChildFirst = iconChildFirst;
    }
 
    private String _iconChildMiddle;
    
    public void setIconChildMiddle(String iconChildMiddle)
    {
        _iconChildMiddle = iconChildMiddle;
    }
 
    private String _iconChildLast;
    
    public void setIconChildLast(String iconChildLast)
    {
        _iconChildLast = iconChildLast;
    }
 
    private String _iconNodeOpen;
    
    public void setIconNodeOpen(String iconNodeOpen)
    {
        _iconNodeOpen = iconNodeOpen;
    }
 
    private String _iconNodeOpenFirst;
    
    public void setIconNodeOpenFirst(String iconNodeOpenFirst)
    {
        _iconNodeOpenFirst = iconNodeOpenFirst;
    }
 
    private String _iconNodeOpenMiddle;
    
    public void setIconNodeOpenMiddle(String iconNodeOpenMiddle)
    {
        _iconNodeOpenMiddle = iconNodeOpenMiddle;
    }
 
    private String _iconNodeOpenLast;
    
    public void setIconNodeOpenLast(String iconNodeOpenLast)
    {
        _iconNodeOpenLast = iconNodeOpenLast;
    }
 
    private String _iconNodeClose;
    
    public void setIconNodeClose(String iconNodeClose)
    {
        _iconNodeClose = iconNodeClose;
    }
 
    private String _iconNodeCloseFirst;
    
    public void setIconNodeCloseFirst(String iconNodeCloseFirst)
    {
        _iconNodeCloseFirst = iconNodeCloseFirst;
    }
 
    private String _iconNodeCloseMiddle;
    
    public void setIconNodeCloseMiddle(String iconNodeCloseMiddle)
    {
        _iconNodeCloseMiddle = iconNodeCloseMiddle;
    }
 
    private String _iconNodeCloseLast;
    
    public void setIconNodeCloseLast(String iconNodeCloseLast)
    {
        _iconNodeCloseLast = iconNodeCloseLast;
    }
 
    private String _nodeClass;
    
    public void setNodeClass(String nodeClass)
    {
        _nodeClass = nodeClass;
    }
 
    private String _rowClasses;
    
    public void setRowClasses(String rowClasses)
    {
        _rowClasses = rowClasses;
    }
 
    private String _columnClasses;
    
    public void setColumnClasses(String columnClasses)
    {
        _columnClasses = columnClasses;
    }
 
    private String _selectedNodeClass;
    
    public void setSelectedNodeClass(String selectedNodeClass)
    {
        _selectedNodeClass = selectedNodeClass;
    }
 
    private String _iconClass;
    
    public void setIconClass(String iconClass)
    {
        _iconClass = iconClass;
    }
 
    private String _expireListeners;
    
    public void setExpireListeners(String expireListeners)
    {
        _expireListeners = expireListeners;
    }
 
    private String _headerClass;
    
    public void setHeaderClass(String headerClass)
    {
        _headerClass = headerClass;
    }
 
    private String _footerClass;
    
    public void setFooterClass(String footerClass)
    {
        _footerClass = footerClass;
    }

    protected void setProperties(UIComponent component)
    {
        if (!(component instanceof org.apache.myfaces.custom.tree.HtmlTree))
        {
            throw new IllegalArgumentException("Component "+
                component.getClass().getName() +" is no org.apache.myfaces.custom.tree.HtmlTree");
        }
        
        org.apache.myfaces.custom.tree.HtmlTree comp = (org.apache.myfaces.custom.tree.HtmlTree) component;
        
        super.setProperties(component);
        
        FacesContext context = getFacesContext();

        if (_var != null)
        {
            if (isValueReference(_var))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_var);
                comp.setValueBinding("var", vb);
            }
            else
            {
                comp.getAttributes().put("var", _var);
            }
        } 
        if (_iconLine != null)
        {
            if (isValueReference(_iconLine))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconLine);
                comp.setValueBinding("iconLine", vb);
            }
            else
            {
                comp.getAttributes().put("iconLine", _iconLine);
            }
        } 
        if (_iconNoline != null)
        {
            if (isValueReference(_iconNoline))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNoline);
                comp.setValueBinding("iconNoline", vb);
            }
            else
            {
                comp.getAttributes().put("iconNoline", _iconNoline);
            }
        } 
        if (_iconChildFirst != null)
        {
            if (isValueReference(_iconChildFirst))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconChildFirst);
                comp.setValueBinding("iconChildFirst", vb);
            }
            else
            {
                comp.getAttributes().put("iconChildFirst", _iconChildFirst);
            }
        } 
        if (_iconChildMiddle != null)
        {
            if (isValueReference(_iconChildMiddle))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconChildMiddle);
                comp.setValueBinding("iconChildMiddle", vb);
            }
            else
            {
                comp.getAttributes().put("iconChildMiddle", _iconChildMiddle);
            }
        } 
        if (_iconChildLast != null)
        {
            if (isValueReference(_iconChildLast))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconChildLast);
                comp.setValueBinding("iconChildLast", vb);
            }
            else
            {
                comp.getAttributes().put("iconChildLast", _iconChildLast);
            }
        } 
        if (_iconNodeOpen != null)
        {
            if (isValueReference(_iconNodeOpen))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeOpen);
                comp.setValueBinding("iconNodeOpen", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeOpen", _iconNodeOpen);
            }
        } 
        if (_iconNodeOpenFirst != null)
        {
            if (isValueReference(_iconNodeOpenFirst))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeOpenFirst);
                comp.setValueBinding("iconNodeOpenFirst", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeOpenFirst", _iconNodeOpenFirst);
            }
        } 
        if (_iconNodeOpenMiddle != null)
        {
            if (isValueReference(_iconNodeOpenMiddle))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeOpenMiddle);
                comp.setValueBinding("iconNodeOpenMiddle", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeOpenMiddle", _iconNodeOpenMiddle);
            }
        } 
        if (_iconNodeOpenLast != null)
        {
            if (isValueReference(_iconNodeOpenLast))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeOpenLast);
                comp.setValueBinding("iconNodeOpenLast", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeOpenLast", _iconNodeOpenLast);
            }
        } 
        if (_iconNodeClose != null)
        {
            if (isValueReference(_iconNodeClose))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeClose);
                comp.setValueBinding("iconNodeClose", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeClose", _iconNodeClose);
            }
        } 
        if (_iconNodeCloseFirst != null)
        {
            if (isValueReference(_iconNodeCloseFirst))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeCloseFirst);
                comp.setValueBinding("iconNodeCloseFirst", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeCloseFirst", _iconNodeCloseFirst);
            }
        } 
        if (_iconNodeCloseMiddle != null)
        {
            if (isValueReference(_iconNodeCloseMiddle))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeCloseMiddle);
                comp.setValueBinding("iconNodeCloseMiddle", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeCloseMiddle", _iconNodeCloseMiddle);
            }
        } 
        if (_iconNodeCloseLast != null)
        {
            if (isValueReference(_iconNodeCloseLast))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconNodeCloseLast);
                comp.setValueBinding("iconNodeCloseLast", vb);
            }
            else
            {
                comp.getAttributes().put("iconNodeCloseLast", _iconNodeCloseLast);
            }
        } 
        if (_nodeClass != null)
        {
            if (isValueReference(_nodeClass))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_nodeClass);
                comp.setValueBinding("nodeClass", vb);
            }
            else
            {
                comp.getAttributes().put("nodeClass", _nodeClass);
            }
        } 
        if (_rowClasses != null)
        {
            if (isValueReference(_rowClasses))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_rowClasses);
                comp.setValueBinding("rowClasses", vb);
            }
            else
            {
                comp.getAttributes().put("rowClasses", _rowClasses);
            }
        } 
        if (_columnClasses != null)
        {
            if (isValueReference(_columnClasses))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_columnClasses);
                comp.setValueBinding("columnClasses", vb);
            }
            else
            {
                comp.getAttributes().put("columnClasses", _columnClasses);
            }
        } 
        if (_selectedNodeClass != null)
        {
            if (isValueReference(_selectedNodeClass))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_selectedNodeClass);
                comp.setValueBinding("selectedNodeClass", vb);
            }
            else
            {
                comp.getAttributes().put("selectedNodeClass", _selectedNodeClass);
            }
        } 
        if (_iconClass != null)
        {
            if (isValueReference(_iconClass))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_iconClass);
                comp.setValueBinding("iconClass", vb);
            }
            else
            {
                comp.getAttributes().put("iconClass", _iconClass);
            }
        } 
        if (_expireListeners != null)
        {
            if (isValueReference(_expireListeners))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_expireListeners);
                comp.setValueBinding("expireListeners", vb);
            }
            else
            {
                comp.getAttributes().put("expireListeners", Long.valueOf(_expireListeners));
            }
        } 
        if (_headerClass != null)
        {
            if (isValueReference(_headerClass))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_headerClass);
                comp.setValueBinding("headerClass", vb);
            }
            else
            {
                comp.getAttributes().put("headerClass", _headerClass);
            }
        } 
        if (_footerClass != null)
        {
            if (isValueReference(_footerClass))
            {
                ValueBinding vb = context.getApplication().createValueBinding(_footerClass);
                comp.setValueBinding("footerClass", vb);
            }
            else
            {
                comp.getAttributes().put("footerClass", _footerClass);
            }
        } 
    }

    public void release()
    {
        super.release();
        _var = null;
        _iconLine = null;
        _iconNoline = null;
        _iconChildFirst = null;
        _iconChildMiddle = null;
        _iconChildLast = null;
        _iconNodeOpen = null;
        _iconNodeOpenFirst = null;
        _iconNodeOpenMiddle = null;
        _iconNodeOpenLast = null;
        _iconNodeClose = null;
        _iconNodeCloseFirst = null;
        _iconNodeCloseMiddle = null;
        _iconNodeCloseLast = null;
        _nodeClass = null;
        _rowClasses = null;
        _columnClasses = null;
        _selectedNodeClass = null;
        _iconClass = null;
        _expireListeners = null;
        _headerClass = null;
        _footerClass = null;
    }
}