Package org.xulfaces.tag.tree

Source Code of org.xulfaces.tag.tree.TreeCellTag

/*
*   xulfaces : bring XUL power to Java
*  
*  Copyright (C) 2005  Olivier SCHMITT
*  This library is free software; you can redistribute it and/or
*  modify it under the terms of the GNU Lesser General Public
*  License as published by the Free Software Foundation; either
*  version 2.1 of the License, or (at your option) any later version.
*
*  This library is distributed in the hope that it will be useful,
*  but WITHOUT ANY WARRANTY; without even the implied warranty of
*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
*  Lesser General Public License for more details.
*
*  You should have received a copy of the GNU Lesser General Public
*  License along with this library; if not, write to the Free Software
*  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
*/


package org.xulfaces.tag.tree;

import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;

import org.xulfaces.annotation.taglib.ATTRIBUTE;
import org.xulfaces.annotation.taglib.TAG;
import org.xulfaces.tag.XULComponentTag;

/**
*
* @author kito31
* @version $Id: TreeCellTag.java,v 1.11 2007/05/08 14:21:31 kito31 Exp $
*/
@TAG(name="treecell",description="Defines a tree cell  (see XUL treecell element).")
public class TreeCellTag extends XULComponentTag {

  @ATTRIBUTE(mappedType="java.lang.Boolean",description="Indicates whether the tree is editable or not. (Firefox 1.5)")
  private String editable;  
 
  @ATTRIBUTE(description="The treecell's label")
  private String label;

  @ATTRIBUTE(description = "For columns that are progress meters, this determines the type of progress meter to use.")
  private String mode;

  @ATTRIBUTE(description = "Sets the properties of the treecell, which can be used to style the cell."
  private String properties;

  @ATTRIBUTE(description = "Points to the treecol the cell is in.")
  private String ref;

  @ATTRIBUTE(description="The treecell's src : an image url.")
  private String src;

  @ATTRIBUTE(mappedType="java.lang.Object",description = "A percentage value that specifies the amount of the progress meter that is filled in or value of a checkbox.")   
  private String value;
 
  @ATTRIBUTE(description="The icon provider for this treecell.")
  private String iconProvider;
 
  @ATTRIBUTE(rtexprvalue=true,description="The label provider for this treecell.")
  private String labelProvider;

  public String getComponentType() {
        return "xul.component.TreeCell";
    }

    public String getRendererType() {
        return "xul.renderer.TreeCell";
    }

  public String getLabel() {
    return label;
  }

  public void setLabel(String label) {
    this.label = label;
  }

  public String getSrc() {
    return src;
  }

  public void setSrc(String src) {
    this.src = src;
  }
         
  public String getIconProvider() {
    return iconProvider;
  }

  public void setIconProvider(String iconProvider) {
    this.iconProvider = iconProvider;
  }

  public String getLabelProvider() {
    return labelProvider;
  }

  public void setLabelProvider(String labelProvider) {
    this.labelProvider = labelProvider;
  }

  public String getMode() {
    return mode;
  }

  public void setMode(String mode) {
    this.mode = mode;
  }

  public String getProperties() {
    return properties;
  }

  public void setProperties(String properties) {
    this.properties = properties;
  }

  public String getRef() {
    return ref;
  }

  public void setRef(String ref) {
    this.ref = ref;
  }

  public String getValue() {
    return value;
  }

  public void setValue(String value) {
    this.value = value;
  }

  public String getEditable() {
    return editable;
  }

  public void setEditable(String editable) {
    this.editable = editable;
  }

  // @StartGeneration

  protected void setProperties(UIComponent component) {
        super.setProperties(component);
        FacesContext facesContext  = getFacesContext();

    setBooleanAttribute(facesContext,component,"editable",editable);
    setStringAttribute(facesContext,component,"label",label);
    setStringAttribute(facesContext,component,"mode",mode);
    setStringAttribute(facesContext,component,"properties",properties);
    setStringAttribute(facesContext,component,"ref",ref);
    setStringAttribute(facesContext,component,"src",src);
    setStringAttribute(facesContext,component,"value",value);
    setStringAttribute(facesContext,component,"iconProvider",iconProvider);
    setStringAttribute(facesContext,component,"labelProvider",labelProvider);

  }
 
                        // @EndGeneration
 

}
TOP

Related Classes of org.xulfaces.tag.tree.TreeCellTag

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.