org.apache.myfaces.shared_tomahawk.taglib.html.HtmlOutputTextTag Maven / Gradle / Ivy
// 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.shared_tomahawk.taglib.html;
import javax.faces.component.UIComponent;
import javax.faces.el.ValueBinding;
import javax.faces.context.FacesContext;
import javax.faces.convert.Converter;
public class HtmlOutputTextTag
extends javax.faces.webapp.UIComponentTag
{
public HtmlOutputTextTag()
{
}
public String getComponentType()
{
return "javax.faces.HtmlOutputText";
}
public String getRendererType()
{
return "javax.faces.Text";
}
private String _style;
public void setStyle(String style)
{
_style = style;
}
private String _styleClass;
public void setStyleClass(String styleClass)
{
_styleClass = styleClass;
}
private String _title;
public void setTitle(String title)
{
_title = title;
}
private String _escape;
public void setEscape(String escape)
{
_escape = escape;
}
private String _converter;
public void setConverter(String converter)
{
_converter = converter;
}
private String _value;
public void setValue(String value)
{
_value = value;
}
protected void setProperties(UIComponent component)
{
if (!(component instanceof javax.faces.component.html.HtmlOutputText))
{
throw new IllegalArgumentException("Component "+
component.getClass().getName() +" is no javax.faces.component.html.HtmlOutputText");
}
javax.faces.component.html.HtmlOutputText comp = (javax.faces.component.html.HtmlOutputText) component;
super.setProperties(component);
FacesContext context = getFacesContext();
if (_style != null)
{
if (isValueReference(_style))
{
ValueBinding vb = context.getApplication().createValueBinding(_style);
comp.setValueBinding("style", vb);
}
else
{
comp.getAttributes().put("style", _style);
}
}
if (_styleClass != null)
{
if (isValueReference(_styleClass))
{
ValueBinding vb = context.getApplication().createValueBinding(_styleClass);
comp.setValueBinding("styleClass", vb);
}
else
{
comp.getAttributes().put("styleClass", _styleClass);
}
}
if (_title != null)
{
if (isValueReference(_title))
{
ValueBinding vb = context.getApplication().createValueBinding(_title);
comp.setValueBinding("title", vb);
}
else
{
comp.getAttributes().put("title", _title);
}
}
if (_escape != null)
{
if (isValueReference(_escape))
{
ValueBinding vb = context.getApplication().createValueBinding(_escape);
comp.setValueBinding("escape", vb);
}
else
{
comp.getAttributes().put("escape", Boolean.valueOf(_escape));
}
}
if (_converter != null)
{
if (isValueReference(_converter))
{
ValueBinding vb = context.getApplication().createValueBinding(_converter);
comp.setValueBinding("converter", vb);
}
else
{
Converter converter = getFacesContext().getApplication().createConverter(_converter);
comp.setConverter(converter);
}
}
if (_value != null)
{
if (isValueReference(_value))
{
ValueBinding vb = context.getApplication().createValueBinding(_value);
comp.setValueBinding("value", vb);
}
else
{
comp.getAttributes().put("value", _value);
}
}
}
public void release()
{
super.release();
_style = null;
_styleClass = null;
_title = null;
_escape = null;
_converter = null;
_value = null;
}
}