You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lu...@apache.org on 2008/01/30 03:59:04 UTC

svn commit: r616601 [6/7] - in /myfaces/tomahawk/branches/1_2_0: ./ assembly/ core/ core/src/main/conf/ core/src/main/java-templates/ core/src/main/java-templates/org/ core/src/main/java-templates/org/apache/ core/src/main/java-templates/org/apache/myf...

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/component/html/ext/HtmlDataTable.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/component/html/ext/HtmlDataTable.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/component/html/ext/HtmlDataTable.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/component/html/ext/HtmlDataTable.java Tue Jan 29 18:58:48 2008
@@ -29,8 +29,8 @@
 import org.apache.myfaces.renderkit.html.util.TableContext;
 import org.apache.myfaces.shared_tomahawk.renderkit.JSFAttr;
 
+import javax.el.ValueExpression;
 import javax.faces.context.FacesContext;
-import javax.faces.el.ValueBinding;
 import javax.faces.model.DataModel;
 import java.io.IOException;
 import java.sql.ResultSet;
@@ -67,39 +67,12 @@
     public static final String SPACER_FACET_NAME = "spacer";
     public static final String NEWSPAPER_ORIENTATION_PROPERTY = "newspaperOrientation";
 
-    /**
-     * the value of the column count property
-     */
-    private Integer _newspaperColumns = null;
-    /**
-     * the value of the newspaper orientation property
-     */
-    private String _newspaperOrientation = null;
-
     private _SerializableDataModel _preservedDataModel;
 
     private String _forceIdIndexFormula = null;
     private String _sortColumn = null;
     private Boolean _sortAscending = null;
     private String _sortProperty = null;
-    private Boolean _sortable = null;
-    private String _rowOnClick = null;
-    private String _rowOnDblClick = null;
-    private String _rowOnMouseDown = null;
-    private String _rowOnMouseUp = null;
-    private String _rowOnMouseOver = null;
-    private String _rowOnMouseMove = null;
-    private String _rowOnMouseOut = null;
-    private String _rowOnKeyPress = null;
-    private String _rowOnKeyDown = null;
-    private String _rowOnKeyUp = null;
-    private String _rowStyleClass = null;
-    private String _rowStyle = null;
-    private String _rowGroupStyle = null;
-    private String _rowGroupStyleClass = null;
-    private String _varDetailToggler = null;
-    private String _bodyStyleClass = null;
-    private String _bodyStyle = null;
 
     private int _sortColumnIndex = -1;
 
@@ -475,23 +448,23 @@
 
     private void updateModelFromPreservedDataModel(FacesContext context)
     {
-        ValueBinding vb = getValueBinding("value");
-        if (vb != null && !vb.isReadOnly(context))
+        ValueExpression vb = getValueExpression("value");
+        if (vb != null && !vb.isReadOnly(context.getELContext()))
         {
             _SerializableDataModel dm = (_SerializableDataModel) getDataModel();
-            Class type = vb.getType(context);
+            Class type = vb.getType(context.getELContext());
             if (DataModel.class.isAssignableFrom(type))
             {
-                vb.setValue(context, dm);
+                vb.setValue(context.getELContext(), dm);
             }
             else if (List.class.isAssignableFrom(type))
             {
-                vb.setValue(context, dm.getWrappedData());
+                vb.setValue(context.getELContext(), dm.getWrappedData());
             }
             else if (OBJECT_ARRAY_CLASS.isAssignableFrom(type))
             {
                 List lst = (List) dm.getWrappedData();
-                vb.setValue(context, lst.toArray(new Object[lst.size()]));
+                vb.setValue(context.getELContext(), lst.toArray(new Object[lst.size()]));
             }
             else if (ResultSet.class.isAssignableFrom(type))
             {
@@ -504,11 +477,11 @@
                 List lst = (List) dm.getWrappedData();
                 if (lst.size() > 0)
                 {
-                    vb.setValue(context, lst.get(0));
+                    vb.setValue(context.getELContext(), lst.get(0));
                 }
                 else
                 {
-                    vb.setValue(context, null);
+                    vb.setValue(context.getELContext(), null);
                 }
             }
         }
@@ -654,7 +627,7 @@
             UIComponent aChild = (UIComponent) iter.next();
             if (aChild.isRendered())
             {
-                ValueBinding vb = aChild.getValueBinding("value");
+                ValueExpression vb = aChild.getValueExpression("value");
                 if (vb != null)
                 {
                     String expressionString = vb.getExpressionString();
@@ -933,16 +906,16 @@
             Boolean sortAscending = (Boolean) values[25];
             if (sortColumn != null && sortAscending != null)
             {
-                ValueBinding vb = getValueBinding("sortColumn");
-                if (vb != null && !vb.isReadOnly(context))
+                ValueExpression vb = getValueExpression("sortColumn");
+                if (vb != null && !vb.isReadOnly(context.getELContext()))
                 {
-                    vb.setValue(context, sortColumn);
+                    vb.setValue(context.getELContext(), sortColumn);
                 }
 
-                vb = getValueBinding("sortAscending");
-                if (vb != null && !vb.isReadOnly(context))
+                vb = getValueExpression("sortAscending");
+                if (vb != null && !vb.isReadOnly(context.getELContext()))
                 {
-                    vb.setValue(context, sortAscending);
+                    vb.setValue(context.getELContext(), sortAscending);
                 }
             }
         }
@@ -1018,25 +991,41 @@
         return super.isRendered();
     }
 
+    /**
+     * Sets A formula that overrides the default row index in the construction of table's
+     *                 body components.
+     *                 Example : #{myRowVar.key}
+     *                 Warning, the EL should evaluate to a unique value for each row !
+     * 
+     * @param forceIdIndexFormula  the new forceIdIndexFormula value
+     */
     public void setForceIdIndexFormula(String forceIdIndexFormula)
     {
         _forceIdIndexFormula = forceIdIndexFormula;
-        ValueBinding vb = getValueBinding("forceIdIndexFormula");
+        ValueExpression vb = getValueExpression("forceIdIndexFormula");
         if (vb != null)
         {
-            vb.setValue(getFacesContext(), _forceIdIndexFormula);
+            vb.setValue(getFacesContext().getELContext(), _forceIdIndexFormula);
             _forceIdIndexFormula = null;
         }
     }
 
+    /**
+     * Gets A formula that overrides the default row index in the construction of table's
+     *                 body components.
+     *                 Example : #{myRowVar.key}
+     *                 Warning, the EL should evaluate to a unique value for each row !
+     *
+     * @return  the new forceIdIndexFormula value
+     */
     public String getForceIdIndexFormula()
     {
         if (_forceIdIndexFormula != null)
             return _forceIdIndexFormula;
-        ValueBinding vb = getValueBinding("forceIdIndexFormula");
+        ValueExpression vb = getValueExpression("forceIdIndexFormula");
         if (vb == null)
             return null;
-        Object eval = vb.getValue(getFacesContext());
+        Object eval = vb.getValue(getFacesContext().getELContext());
         return eval == null ? null : eval.toString();
     }
 
@@ -1058,42 +1047,71 @@
         _sortColumn = sortColumn;
         // update model is necessary here, because processUpdates is never called
         // reason: HtmlCommandSortHeader.isImmediate() == true
-        ValueBinding vb = getValueBinding("sortColumn");
+        ValueExpression vb = getValueExpression("sortColumn");
         if (vb != null)
         {
-            vb.setValue(getFacesContext(), _sortColumn);
+            vb.setValue(getFacesContext().getELContext(), _sortColumn);
             _sortColumn = null;
         }
 
         setSortColumnIndex(columnNameToIndex(sortColumn));
     }
 
+    /**
+     * Gets Value reference to a model property that gives the current sort column name.
+     *                 The target String property is set to the "columnName" of whichever column has been
+     *                 chosen to sort by, and the method which is bound to the "value" attribute
+     *                 of this table (ie which provides the DataModel used) is expected to use this
+     *                 property to determine how to sort the DataModel's contents.
+     *
+     * @return  the new sortColumn value
+     */
     public String getSortColumn()
     {
         if (_sortColumn != null) return _sortColumn;
-        ValueBinding vb = getValueBinding("sortColumn");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+        ValueExpression vb = getValueExpression("sortColumn");
+        return vb != null ? (String) vb.getValue(getFacesContext().getELContext()) : null;
     }
 
+    /**
+     * Sets Value reference to a model property that gives the current sort direction.
+     *                 The target Boolean property is set to true when the selected sortColumn
+     *                 should be sorted in ascending order, and false otherwise. The method which
+     *                 is bound to the "value" attribute of this table (ie which provides the DataModel
+     *                 used) is expected to use this property to determine how to sort the DataModel's
+     *                 contents.
+     * 
+     * @param sortAscending  the new sortAscending value
+     */
     public void setSortAscending(boolean sortAscending)
     {
         _sortAscending = Boolean.valueOf(sortAscending);
         // update model is necessary here, because processUpdates is never called
         // reason: HtmlCommandSortHeader.isImmediate() == true
-        ValueBinding vb = getValueBinding("sortAscending");
+        ValueExpression vb = getValueExpression("sortAscending");
         if (vb != null)
         {
-            vb.setValue(getFacesContext(), _sortAscending);
+            vb.setValue(getFacesContext().getELContext(), _sortAscending);
             _sortAscending = null;
         }
     }
 
+    /**
+     * Gets Value reference to a model property that gives the current sort direction.
+     *                 The target Boolean property is set to true when the selected sortColumn
+     *                 should be sorted in ascending order, and false otherwise. The method which
+     *                 is bound to the "value" attribute of this table (ie which provides the DataModel
+     *                 used) is expected to use this property to determine how to sort the DataModel's
+     *                 contents.
+     *
+     * @return  the new sortAscending value
+     */
     public boolean isSortAscending()
     {
         if (_sortAscending != null)
             return _sortAscending.booleanValue();
-        ValueBinding vb = getValueBinding("sortAscending");
-        Boolean v = vb != null ? (Boolean) vb.getValue(getFacesContext()) : null;
+        ValueExpression vb = getValueExpression("sortAscending");
+        Boolean v = vb != null ? (Boolean) vb.getValue(getFacesContext().getELContext()) : null;
         return v != null ? v.booleanValue() : DEFAULT_SORTASCENDING;
     }
 
@@ -1107,569 +1125,1169 @@
         return _sortProperty;
     }
 
-    public void setSortable(boolean sortable)
+    protected boolean isValidChildren()
     {
-        _sortable = sortable ? Boolean.TRUE : Boolean.FALSE;
+        return _isValidChildren;
     }
 
-    public boolean isSortable()
+    protected void setIsValidChildren(boolean isValidChildren)
     {
-        if (_sortable != null) return _sortable.booleanValue();
-        ValueBinding vb = getValueBinding("sortable");
-        Boolean v = vb != null ? (Boolean) vb.getValue(getFacesContext()) : null;
-        return v != null ? v.booleanValue() : DEFAULT_SORTABLE;
+        _isValidChildren = isValidChildren;
     }
 
-    public void setRowOnMouseOver(String rowOnMouseOver)
+    protected _SerializableDataModel getPreservedDataModel()
     {
-        _rowOnMouseOver = rowOnMouseOver;
+        return _preservedDataModel;
     }
 
-    public String getRowOnMouseOver()
+    protected void setPreservedDataModel(_SerializableDataModel preservedDataModel)
     {
-        if (_rowOnMouseOver != null)
-            return _rowOnMouseOver;
-        ValueBinding vb = getValueBinding("rowOnMouseOver");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+        _preservedDataModel = preservedDataModel;
     }
 
-    public void setRowOnMouseOut(String rowOnMouseOut)
-    {
-        _rowOnMouseOut = rowOnMouseOut;
-    }
 
-    public String getRowOnMouseOut()
+    public boolean isCurrentDetailExpanded()
     {
-        if (_rowOnMouseOut != null)
-            return _rowOnMouseOut;
-        ValueBinding vb = getValueBinding("rowOnMouseOut");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+        return _expandedNodes.contains(new Integer(getRowIndex()));
     }
 
-    public void setRowOnClick(String rowOnClick)
+    public HtmlDataTable()
     {
-        _rowOnClick = rowOnClick;
+        setRendererType(DEFAULT_RENDERER_TYPE);
     }
 
-    public String getRowOnClick()
+    /**
+     * Change the status of the current detail row from collapsed to expanded or
+     * viceversa.
+     */
+    public void toggleDetail()
     {
-        if (_rowOnClick != null)
-            return _rowOnClick;
-        ValueBinding vb = getValueBinding("rowOnClick");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
-    }
+        Integer rowIndex = new Integer(getRowIndex());
 
-    public void setRowOnDblClick(String rowOnDblClick)
-    {
-        _rowOnDblClick = rowOnDblClick;
+        if (_expandedNodes.contains(rowIndex))
+        {
+            _expandedNodes.remove(rowIndex);
+        }
+        else
+        {
+            _expandedNodes.add(rowIndex);
+        }
     }
 
-    public String getRowOnDblClick()
+    /**
+     * Return true if the current detail row is expanded.
+     *
+     * @return true if the current detail row is expanded.
+     */
+    public boolean isDetailExpanded()
     {
-        if (_rowOnDblClick != null)
-            return _rowOnDblClick;
-        ValueBinding vb = getValueBinding("rowOnDblClick");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
-    }
+        Integer rowIndex = new Integer(getRowIndex());
 
-    public String getRowOnKeyDown()
-    {
-        if (_rowOnKeyDown != null)
-            return _rowOnKeyDown;
-        ValueBinding vb = getValueBinding("rowOnKeyDown");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+        return _expandedNodes.contains(rowIndex);
     }
 
-    public void setRowOnKeyDown(String rowOnKeyDown)
+    public int getSortColumnIndex()
     {
-        _rowOnKeyDown = rowOnKeyDown;
-    }
+        if (_sortColumnIndex == -1)
+            _sortColumnIndex = columnNameToIndex(getSortColumn());
 
-    public String getRowOnKeyPress()
-    {
-        if (_rowOnKeyPress != null)
-            return _rowOnKeyPress;
-        ValueBinding vb = getValueBinding("rowOnKeyPress");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+        return _sortColumnIndex;
     }
 
-    public void setRowOnKeyPress(String rowOnKeyPress)
+    public void setSortColumnIndex(int sortColumnIndex)
     {
-        _rowOnKeyPress = rowOnKeyPress;
+        _sortColumnIndex = sortColumnIndex;
     }
 
-    public String getRowOnKeyUp()
+    /**
+     * Gets the spacer facet, between each pair of newspaper columns.
+     */
+    public UIComponent getSpacer()
     {
-        if (_rowOnKeyUp != null)
-            return _rowOnKeyUp;
-        ValueBinding vb = getValueBinding("rowOnKeyUp");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+        return (UIComponent) getFacets().get(SPACER_FACET_NAME);
     }
 
-    public void setRowOnKeyUp(String rowOnKeyUp)
+    public void setSpacer(UIComponent spacer)
     {
-        _rowOnKeyUp = rowOnKeyUp;
+        getFacets().put(SPACER_FACET_NAME, spacer);
     }
 
-    public String getRowStyleClass()
+    /**
+     * Expand all details
+     */
+    public void expandAllDetails()
     {
-	if (_rowStyleClass != null)
-	    return _rowStyleClass;
+        int rowCount = getRowCount();
 
-	// TODO: temporarily support fully-qualified ext. dataTable attribute names.
-	ValueBinding vb = getValueBinding("org.apache.myfaces.dataTable.ROW_STYLECLASS");
-	if (vb != null)
-	    log.warn("org.apache.myfaces.dataTable.ROW_STYLECLASS is deprecated. Please use rowStyleClass instead.");
-	else
-	    vb = getValueBinding(JSFAttr.ROW_STYLECLASS_ATTR);
-	if(vb == null)
-	    return null;
-	String bindingValue = (String) vb.getValue(getFacesContext());
-	if(bindingValue == "")
-	    return null;  // Fix for JSF 1.2 EL coercing nulls to empty string
-	return bindingValue;
+        _expandedNodes.clear();
+        for (int row = 0; row < rowCount; row++)
+        {
+            _expandedNodes.add(new Integer(row));
+        }
     }
 
-    public void setRowStyleClass(String rowStyleClass)
+    /**
+     * Collapse all details
+     */
+    public void collapseAllDetails()
     {
-        _rowStyleClass = rowStyleClass;
+        _expandedNodes.clear();
     }
 
-    public String getRowStyle()
+    /**
+     * @return true is any of the details is expanded
+     */
+    public boolean isExpandedEmpty()
     {
-        if (_rowStyle != null)
-            return _rowStyle;
-	
-	// TODO: temporarily support fully-qualified ext. dataTable attribute names.
-        ValueBinding vb = getValueBinding("org.apache.myfaces.dataTable.ROW_STYLE");
-	if (vb != null)
-	    log.warn("org.apache.myfaces.dataTable.ROW_STYLE is deprecated. Please use rowStyle instead.");
-	else
-	    vb = getValueBinding(JSFAttr.ROW_STYLE_ATTR);
-	if(vb == null)
-	    return null;
-	String bindingValue = (String) vb.getValue(getFacesContext());
-	if(bindingValue == "")
-	    return null;  // Fix for JSF 1.2 EL coercing nulls to empty string
-	return bindingValue;
+        boolean expandedEmpty = true;
+        if (_expandedNodes != null)
+        {
+            expandedEmpty = _expandedNodes.isEmpty();
+        }
+        return expandedEmpty;
     }
 
-    public void setRowStyle(String rowStyle)
+    /**
+     * Clears expanded nodes set if expandedEmpty is true
+     *
+     * @param expandedEmpty
+     */
+    public void setExpandedEmpty(boolean expandedEmpty)
     {
-        _rowStyle = rowStyle;
+        if (expandedEmpty)
+        {
+            if (_expandedNodes != null)
+            {
+                _expandedNodes.clear();
+            }
+        }
     }
 
-    public String getRowOnMouseDown()
+    //------------------ GENERATED CODE BEGIN (do not modify!) --------------------
+
+    public static final String COMPONENT_TYPE = "org.apache.myfaces.HtmlDataTable";
+    public static final String DEFAULT_RENDERER_TYPE = "org.apache.myfaces.Table";
+
+    // Property: sortable
+    private boolean _sortable = false;
+    private boolean _sortableSet;
+
+    /**
+     * Gets 
+     *
+     * @return  the new sortable value
+     */
+    public boolean isSortable()
     {
-        if (_rowOnMouseDown != null)
-            return _rowOnMouseDown;
-        ValueBinding vb = getValueBinding("rowOnMouseDown");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_sortableSet)
+      {
+        return _sortable;
+      }
+      ValueExpression expression = getValueExpression("sortable");
+      if (expression != null)
+      {
+        return (Boolean)expression.getValue(getFacesContext().getELContext());
+      }
+      return false;
     }
 
-    public void setRowOnMouseDown(String rowOnMouseDown)
+    /**
+     * Sets 
+     * 
+     * @param sortable  the new sortable value
+     */
+    public void setSortable(boolean sortable)
     {
-        _rowOnMouseDown = rowOnMouseDown;
+      this._sortable = sortable;
+      this._sortableSet = true;
     }
+    
+    // Property: varDetailToggler
+    private String _varDetailToggler;
 
-    public String getRowOnMouseMove()
+    /**
+     * Gets This variable has the boolean property
+     *                "currentdetailExpanded" which is true if the current
+     *                detail row is expanded and the action method
+     *                "toggleDetail" which expand/collapse the current detail
+     *                row.
+     *
+     * @return  the new varDetailToggler value
+     */
+    public String getVarDetailToggler()
     {
-        if (_rowOnMouseMove != null)
-            return _rowOnMouseMove;
-        ValueBinding vb = getValueBinding("rowOnMouseMove");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_varDetailToggler != null)
+      {
+        return _varDetailToggler;
+      }
+      ValueExpression expression = getValueExpression("varDetailToggler");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setRowOnMouseMove(String rowOnMouseMove)
+    /**
+     * Sets This variable has the boolean property
+     *                "currentdetailExpanded" which is true if the current
+     *                detail row is expanded and the action method
+     *                "toggleDetail" which expand/collapse the current detail
+     *                row.
+     * 
+     * @param varDetailToggler  the new varDetailToggler value
+     */
+    public void setVarDetailToggler(String varDetailToggler)
     {
-        _rowOnMouseMove = rowOnMouseMove;
+      this._varDetailToggler = varDetailToggler;
     }
+    
+    // Property: rowGroupStyle
+    private String _rowGroupStyle;
 
-    public String getRowOnMouseUp()
+    /**
+     * Gets Corresponds to the HTML style attribute for grouped
+     *                rows.
+     *
+     * @return  the new rowGroupStyle value
+     */
+    public String getRowGroupStyle()
     {
-        if (_rowOnMouseUp != null)
-            return _rowOnMouseUp;
-        ValueBinding vb = getValueBinding("rowOnMouseUp");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_rowGroupStyle != null)
+      {
+        return _rowGroupStyle;
+      }
+      ValueExpression expression = getValueExpression("rowGroupStyle");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setRowOnMouseUp(String rowOnMouseUp)
+    /**
+     * Sets Corresponds to the HTML style attribute for grouped
+     *                rows.
+     * 
+     * @param rowGroupStyle  the new rowGroupStyle value
+     */
+    public void setRowGroupStyle(String rowGroupStyle)
     {
-        _rowOnMouseUp = rowOnMouseUp;
+      this._rowGroupStyle = rowGroupStyle;
     }
 
-    protected boolean isValidChildren()
+    // Property: rowGroupStyleClass
+    private String _rowGroupStyleClass;
+
+    /**
+     * Gets StyleClass for grouped rows.
+     *
+     * @return  the new rowGroupStyleClass value
+     */
+    public String getRowGroupStyleClass()
     {
-        return _isValidChildren;
+      if (_rowGroupStyleClass != null)
+      {
+        return _rowGroupStyleClass;
+      }
+      ValueExpression expression = getValueExpression("rowGroupStyleClass");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    protected void setIsValidChildren(boolean isValidChildren)
+    /**
+     * Sets StyleClass for grouped rows.
+     * 
+     * @param rowGroupStyleClass  the new rowGroupStyleClass value
+     */
+    public void setRowGroupStyleClass(String rowGroupStyleClass)
     {
-        _isValidChildren = isValidChildren;
+      this._rowGroupStyleClass = rowGroupStyleClass;
     }
+    
+    // Property: rowStyle
+    private String _rowStyle;
 
-    protected _SerializableDataModel getPreservedDataModel()
+    /**
+     * Gets Corresponds to the HTML style attribute for the row tr
+     *                tag.
+     *
+     * @return  the new rowStyle value
+     */
+    public String getRowStyle()
     {
-        return _preservedDataModel;
+      if (_rowStyle != null)
+      {
+        return _rowStyle;
+      }
+      ValueExpression expression = getValueExpression("rowStyle");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    protected void setPreservedDataModel(_SerializableDataModel preservedDataModel)
+    /**
+     * Sets Corresponds to the HTML style attribute for the row tr
+     *                tag.
+     * 
+     * @param rowStyle  the new rowStyle value
+     */
+    public void setRowStyle(String rowStyle)
     {
-        _preservedDataModel = preservedDataModel;
+      this._rowStyle = rowStyle;
     }
 
+    // Property: rowStyleClass
+    private String _rowStyleClass;
 
-    public boolean isCurrentDetailExpanded()
+    /**
+     * Gets Corresponds to the HTML class attribute for the row tr
+     *                tag.
+     *
+     * @return  the new rowStyleClass value
+     */
+    public String getRowStyleClass()
     {
-        return _expandedNodes.contains(new Integer(getRowIndex()));
+      if (_rowStyleClass != null)
+      {
+        return _rowStyleClass;
+      }
+      ValueExpression expression = getValueExpression("rowStyleClass");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setVarDetailToggler(String varDetailToggler)
+    /**
+     * Sets Corresponds to the HTML class attribute for the row tr
+     *                tag.
+     * 
+     * @param rowStyleClass  the new rowStyleClass value
+     */
+    public void setRowStyleClass(String rowStyleClass)
     {
-        _varDetailToggler = varDetailToggler;
+      this._rowStyleClass = rowStyleClass;
     }
+    
+    
+    // Property: rowOnClick
+    private String _rowOnClick;
 
-    public String getVarDetailToggler()
+    /**
+     * Gets Defines a JavaScript onclick event handler for each table row
+     *
+     * @return  the new rowOnClick value
+     */
+    public String getRowOnClick()
     {
-        if (_varDetailToggler != null)
-            return _varDetailToggler;
-        ValueBinding vb = getValueBinding("varDetailToggler");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_rowOnClick != null)
+      {
+        return _rowOnClick;
+      }
+      ValueExpression expression = getValueExpression("rowOnClick");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public String getRowGroupStyle()
+    /**
+     * Sets Defines a JavaScript onclick event handler for each table row
+     * 
+     * @param rowOnClick  the new rowOnClick value
+     */
+    public void setRowOnClick(String rowOnClick)
     {
-        if (_rowGroupStyle != null)
-            return _rowGroupStyle;
-        ValueBinding vb = getValueBinding("rowGroupStyle");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      this._rowOnClick = rowOnClick;
     }
 
-    public void setRowGroupStyle(String rowGroupStyle)
+    // Property: rowOnDblClick
+    private String _rowOnDblClick;
+
+    /**
+     * Gets Defines a JavaScript ondblclick event handler for each table row
+     *
+     * @return  the new rowOnDblClick value
+     */
+    public String getRowOnDblClick()
     {
-        _rowGroupStyle = rowGroupStyle;
+      if (_rowOnDblClick != null)
+      {
+        return _rowOnDblClick;
+      }
+      ValueExpression expression = getValueExpression("rowOnDblClick");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public String getRowGroupStyleClass()
+    /**
+     * Sets Defines a JavaScript ondblclick event handler for each table row
+     * 
+     * @param rowOnDblClick  the new rowOnDblClick value
+     */
+    public void setRowOnDblClick(String rowOnDblClick)
     {
-        if (_rowGroupStyleClass != null)
-            return _rowGroupStyleClass;
-        ValueBinding vb = getValueBinding("rowGroupStyleClass");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      this._rowOnDblClick = rowOnDblClick;
     }
 
-    public void setRowGroupStyleClass(String rowGroupStyleClass)
+    // Property: rowOnKeyDown
+    private String _rowOnKeyDown;
+
+    /**
+     * Gets Defines a JavaScript onkeydown event handler for each table row
+     *
+     * @return  the new rowOnKeyDown value
+     */
+    public String getRowOnKeyDown()
     {
-        _rowGroupStyleClass = rowGroupStyleClass;
+      if (_rowOnKeyDown != null)
+      {
+        return _rowOnKeyDown;
+      }
+      ValueExpression expression = getValueExpression("rowOnKeyDown");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public String getBodyStyle()
+    /**
+     * Sets Defines a JavaScript onkeydown event handler for each table row
+     * 
+     * @param rowOnKeyDown  the new rowOnKeyDown value
+     */
+    public void setRowOnKeyDown(String rowOnKeyDown)
     {
-        if (_bodyStyle != null)
-            return _bodyStyle;
-        ValueBinding vb = getValueBinding("bodyStyle");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      this._rowOnKeyDown = rowOnKeyDown;
     }
 
-    public void setBodyStyle(String bodyStyle)
+    // Property: rowOnKeyPress
+    private String _rowOnKeyPress;
+
+    /**
+     * Gets Defines a JavaScript onkeypress event handler for each table row
+     *
+     * @return  the new rowOnKeyPress value
+     */
+    public String getRowOnKeyPress()
     {
-        _bodyStyle = bodyStyle;
+      if (_rowOnKeyPress != null)
+      {
+        return _rowOnKeyPress;
+      }
+      ValueExpression expression = getValueExpression("rowOnKeyPress");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public String getBodyStyleClass()
+    /**
+     * Sets Defines a JavaScript onkeypress event handler for each table row
+     * 
+     * @param rowOnKeyPress  the new rowOnKeyPress value
+     */
+    public void setRowOnKeyPress(String rowOnKeyPress)
     {
-        if (_bodyStyleClass != null)
-            return _bodyStyleClass;
-        ValueBinding vb = getValueBinding("bodyStyleClass");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      this._rowOnKeyPress = rowOnKeyPress;
     }
 
-    public void setBodyStyleClass(String bodyStyleClass)
+    // Property: rowOnKeyUp
+    private String _rowOnKeyUp;
+
+    /**
+     * Gets Defines a JavaScript onkeyup event handler for each table row
+     *
+     * @return  the new rowOnKeyUp value
+     */
+    public String getRowOnKeyUp()
     {
-        _bodyStyleClass = bodyStyleClass;
+      if (_rowOnKeyUp != null)
+      {
+        return _rowOnKeyUp;
+      }
+      ValueExpression expression = getValueExpression("rowOnKeyUp");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public HtmlDataTable()
+    /**
+     * Sets Defines a JavaScript onkeyup event handler for each table row
+     * 
+     * @param rowOnKeyUp  the new rowOnKeyUp value
+     */
+    public void setRowOnKeyUp(String rowOnKeyUp)
     {
-        setRendererType(DEFAULT_RENDERER_TYPE);
+      this._rowOnKeyUp = rowOnKeyUp;
     }
+    
+    // Property: rowOnMouseDown
+    private String _rowOnMouseDown;
 
     /**
-     * Change the status of the current detail row from collapsed to expanded or
-     * viceversa.
+     * Gets 
+     *
+     * @return  the new rowOnMouseDown value
      */
-    public void toggleDetail()
+    public String getRowOnMouseDown()
     {
-        Integer rowIndex = new Integer(getRowIndex());
+      if (_rowOnMouseDown != null)
+      {
+        return _rowOnMouseDown;
+      }
+      ValueExpression expression = getValueExpression("rowOnMouseDown");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
+    }
 
-        if (_expandedNodes.contains(rowIndex))
-        {
-            _expandedNodes.remove(rowIndex);
-        }
-        else
-        {
-            _expandedNodes.add(rowIndex);
-        }
+    /**
+     * Sets 
+     * 
+     * @param rowOnMouseDown  the new rowOnMouseDown value
+     */
+    public void setRowOnMouseDown(String rowOnMouseDown)
+    {
+      this._rowOnMouseDown = rowOnMouseDown;
     }
 
+    // Property: rowOnMouseMove
+    private String _rowOnMouseMove;
+
     /**
-     * Return true if the current detail row is expanded.
+     * Gets Defines a JavaScript onmousemove event handler for each table row
      *
-     * @return true if the current detail row is expanded.
+     * @return  the new rowOnMouseMove value
      */
-    public boolean isDetailExpanded()
+    public String getRowOnMouseMove()
     {
-        Integer rowIndex = new Integer(getRowIndex());
-
-        return _expandedNodes.contains(rowIndex);
+      if (_rowOnMouseMove != null)
+      {
+        return _rowOnMouseMove;
+      }
+      ValueExpression expression = getValueExpression("rowOnMouseMove");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public int getSortColumnIndex()
+    /**
+     * Sets Defines a JavaScript onmousemove event handler for each table row
+     * 
+     * @param rowOnMouseMove  the new rowOnMouseMove value
+     */
+    public void setRowOnMouseMove(String rowOnMouseMove)
     {
-        if (_sortColumnIndex == -1)
-            _sortColumnIndex = columnNameToIndex(getSortColumn());
-
-        return _sortColumnIndex;
+      this._rowOnMouseMove = rowOnMouseMove;
     }
 
-    public void setSortColumnIndex(int sortColumnIndex)
+    // Property: rowOnMouseOut
+    private String _rowOnMouseOut;
+
+    /**
+     * Gets Defines a JavaScript onmouseout event handler for each table row
+     *
+     * @return  the new rowOnMouseOut value
+     */
+    public String getRowOnMouseOut()
     {
-        _sortColumnIndex = sortColumnIndex;
+      if (_rowOnMouseOut != null)
+      {
+        return _rowOnMouseOut;
+      }
+      ValueExpression expression = getValueExpression("rowOnMouseOut");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
     /**
-     * Set the number of columns the table will be divided over.
+     * Sets Defines a JavaScript onmouseout event handler for each table row
+     * 
+     * @param rowOnMouseOut  the new rowOnMouseOut value
      */
-    public int getNewspaperColumns() {
-        if (_newspaperColumns != null) return _newspaperColumns.intValue();
-        ValueBinding vb = getValueBinding(NEWSPAPER_COLUMNS_PROPERTY);
-		Integer v = vb != null ? (Integer)vb.getValue(getFacesContext()) : DEFAULT_NEWSPAPER_COLUMNS;
-		return v.intValue();
+    public void setRowOnMouseOut(String rowOnMouseOut)
+    {
+      this._rowOnMouseOut = rowOnMouseOut;
     }
 
-    public void setNewspaperColumns(int newspaperColumns)
+    // Property: rowOnMouseOver
+    private String _rowOnMouseOver;
+
+    /**
+     * Gets Defines a JavaScript onmouseover event handler for each table row
+     *
+     * @return  the new rowOnMouseOver value
+     */
+    public String getRowOnMouseOver()
     {
-        this._newspaperColumns = new Integer(newspaperColumns);
+      if (_rowOnMouseOver != null)
+      {
+        return _rowOnMouseOver;
+      }
+      ValueExpression expression = getValueExpression("rowOnMouseOver");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
     /**
-     * Set the orientation of the newspaper columns.
+     * Sets Defines a JavaScript onmouseover event handler for each table row
+     * 
+     * @param rowOnMouseOver  the new rowOnMouseOver value
      */
-    public void setNewspaperOrientation(String newspaperOrientation)
+    public void setRowOnMouseOver(String rowOnMouseOver)
     {
-        this._newspaperOrientation = newspaperOrientation;
+      this._rowOnMouseOver = rowOnMouseOver;
     }
 
-	public String getNewspaperOrientation() {
-		if(_newspaperOrientation != null)
-			return _newspaperOrientation;
-		
-		ValueBinding vb = getValueBinding(NEWSPAPER_ORIENTATION_PROPERTY);
-		String v = vb != null ? (String)vb.getValue(getFacesContext()) : DEFAULT_NEWSPAPER_ORIENTATION;
-		return v;
-	}
+    // Property: rowOnMouseUp
+    private String _rowOnMouseUp;
 
     /**
-     * Gets the spacer facet, between each pair of newspaper columns.
+     * Gets Defines a JavaScript onmouseup event handler for each table row
+     *
+     * @return  the new rowOnMouseUp value
      */
-    public UIComponent getSpacer()
+    public String getRowOnMouseUp()
     {
-        return (UIComponent) getFacets().get(SPACER_FACET_NAME);
+      if (_rowOnMouseUp != null)
+      {
+        return _rowOnMouseUp;
+      }
+      ValueExpression expression = getValueExpression("rowOnMouseUp");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setSpacer(UIComponent spacer)
+    /**
+     * Sets Defines a JavaScript onmouseup event handler for each table row
+     * 
+     * @param rowOnMouseUp  the new rowOnMouseUp value
+     */
+    public void setRowOnMouseUp(String rowOnMouseUp)
     {
-        getFacets().put(SPACER_FACET_NAME, spacer);
+      this._rowOnMouseUp = rowOnMouseUp;
     }
+        
+    // Property: bodyStyle
+    private String _bodyStyle;
 
     /**
-     * Expand all details
+     * Gets Corresponds to the HTML style attribute for the table
+     *                body tag.
+     *
+     * @return  the new bodyStyle value
      */
-    public void expandAllDetails()
+    public String getBodyStyle()
     {
-        int rowCount = getRowCount();
+      if (_bodyStyle != null)
+      {
+        return _bodyStyle;
+      }
+      ValueExpression expression = getValueExpression("bodyStyle");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
+    }
 
-        _expandedNodes.clear();
-        for (int row = 0; row < rowCount; row++)
-        {
-            _expandedNodes.add(new Integer(row));
-        }
+    /**
+     * Sets Corresponds to the HTML style attribute for the table
+     *                body tag.
+     * 
+     * @param bodyStyle  the new bodyStyle value
+     */
+    public void setBodyStyle(String bodyStyle)
+    {
+      this._bodyStyle = bodyStyle;
     }
 
+    // Property: bodyStyleClass
+    private String _bodyStyleClass;
+
     /**
-     * Collapse all details
+     * Gets Corresponds to the HTML class attribute for the table
+     *                body tag.
+     *
+     * @return  the new bodyStyleClass value
      */
-    public void collapseAllDetails()
+    public String getBodyStyleClass()
     {
-        _expandedNodes.clear();
+      if (_bodyStyleClass != null)
+      {
+        return _bodyStyleClass;
+      }
+      ValueExpression expression = getValueExpression("bodyStyleClass");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
     /**
-     * @return true is any of the details is expanded
+     * Sets Corresponds to the HTML class attribute for the table
+     *                body tag.
+     * 
+     * @param bodyStyleClass  the new bodyStyleClass value
      */
-    public boolean isExpandedEmpty()
+    public void setBodyStyleClass(String bodyStyleClass)
     {
-        boolean expandedEmpty = true;
-        if (_expandedNodes != null)
-        {
-            expandedEmpty = _expandedNodes.isEmpty();
-        }
-        return expandedEmpty;
+      this._bodyStyleClass = bodyStyleClass;
     }
+    
+    // Property: newspaperColumns
+    private int _newspaperColumns = 1;
+    private boolean _newspaperColumnsSet;
 
     /**
-     * Clears expanded nodes set if expandedEmpty is true
+     * Gets The number of columns to wrap the table over. Default: 1
      *
-     * @param expandedEmpty
+     * @return  the new newspaperColumns value
      */
-    public void setExpandedEmpty(boolean expandedEmpty)
+    public int getNewspaperColumns()
     {
-        if (expandedEmpty)
-        {
-            if (_expandedNodes != null)
-            {
-                _expandedNodes.clear();
-            }
-        }
+      if (_newspaperColumnsSet)
+      {
+        return _newspaperColumns;
+      }
+      ValueExpression expression = getValueExpression("newspaperColumns");
+      if (expression != null)
+      {
+        return (Integer)expression.getValue(getFacesContext().getELContext());
+      }
+      return 1;
     }
 
-    //------------------ GENERATED CODE BEGIN (do not modify!) --------------------
-
-    public static final String COMPONENT_TYPE = "org.apache.myfaces.HtmlDataTable";
-    public static final String DEFAULT_RENDERER_TYPE = "org.apache.myfaces.Table";
+    /**
+     * Sets The number of columns to wrap the table over. Default: 1
+     * 
+     * @param newspaperColumns  the new newspaperColumns value
+     */
+    public void setNewspaperColumns(int newspaperColumns)
+    {
+      this._newspaperColumns = newspaperColumns;
+      this._newspaperColumnsSet = true;
+    }
 
-    private static final boolean DEFAULT_PRESERVEDATAMODEL = false;
-    private static final boolean DEFAULT_PRESERVESORT = true;
-    private static final boolean DEFAULT_RENDEREDIFEMPTY = true;
-
-    private Boolean _preserveDataModel = null;
-    private Boolean _preserveSort = null;
-    private String _enabledOnUserRole = null;
-    private String _visibleOnUserRole = null;
-    private Boolean _renderedIfEmpty = null;
-    private String _rowIndexVar = null;
-    private String _rowCountVar = null;
-    private String _sortedColumnVar = null;
-    private String _previousRowDataVar = null;
+    // Property: newspaperOrientation
+    private String _newspaperOrientation = "vertical";
 
-    public void setPreserveDataModel(boolean preserveDataModel)
+    /**
+     * Gets The orientation of the newspaper columns in the newspaper table - "horizontal" or "vertical". Default: vertical
+     *
+     * @return  the new newspaperOrientation value
+     */
+    public String getNewspaperOrientation()
     {
-        _preserveDataModel = Boolean.valueOf(preserveDataModel);
+      if (_newspaperOrientation != null)
+      {
+        return _newspaperOrientation;
+      }
+      ValueExpression expression = getValueExpression("newspaperOrientation");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return "vertical";
     }
 
+    /**
+     * Sets The orientation of the newspaper columns in the newspaper table - "horizontal" or "vertical". Default: vertical
+     * 
+     * @param newspaperOrientation  the new newspaperOrientation value
+     */
+    public void setNewspaperOrientation(String newspaperOrientation)
+    {
+      this._newspaperOrientation = newspaperOrientation;
+    }
+    
+    // Property: preserveDataModel
+    private boolean _preserveDataModel = false;
+    private boolean _preserveDataModelSet;
+
+    /**
+     * Gets Indicates whether the state of the whole DataModel should be saved and
+     *                 restored. When set to false, the value-binding for the "value" attribute
+     *                 of this table is executed each time the page is rendered. When set to 
+     *                 true, that value-binding is only executed when the component is first
+     *                 created, and the DataModel state is thereafter saved/restored automatically
+     *                 by the component.
+     *                 
+     *                 When column sorting is used for a table this property needs to be false
+     *                 so that the DataModel can be updated to reflect any changes in the
+     *                 sort criteria.
+     *                 
+     *                 Default: false
+     *
+     * @return  the new preserveDataModel value
+     */
     public boolean isPreserveDataModel()
     {
-        if (_preserveDataModel != null)
-            return _preserveDataModel.booleanValue();
-        ValueBinding vb = getValueBinding("preserveDataModel");
-        Boolean v = vb != null ? (Boolean) vb.getValue(getFacesContext()) : null;
-        return v != null ? v.booleanValue() : DEFAULT_PRESERVEDATAMODEL;
+      if (_preserveDataModelSet)
+      {
+        return _preserveDataModel;
+      }
+      ValueExpression expression = getValueExpression("preserveDataModel");
+      if (expression != null)
+      {
+        return (Boolean)expression.getValue(getFacesContext().getELContext());
+      }
+      return false;
     }
 
-    public void setPreserveSort(boolean preserveSort)
+    /**
+     * Sets Indicates whether the state of the whole DataModel should be saved and
+     *                 restored. When set to false, the value-binding for the "value" attribute
+     *                 of this table is executed each time the page is rendered. When set to 
+     *                 true, that value-binding is only executed when the component is first
+     *                 created, and the DataModel state is thereafter saved/restored automatically
+     *                 by the component.
+     *                 
+     *                 When column sorting is used for a table this property needs to be false
+     *                 so that the DataModel can be updated to reflect any changes in the
+     *                 sort criteria.
+     *                 
+     *                 Default: false
+     * 
+     * @param preserveDataModel  the new preserveDataModel value
+     */
+    public void setPreserveDataModel(boolean preserveDataModel)
     {
-        _preserveSort = Boolean.valueOf(preserveSort);
+      this._preserveDataModel = preserveDataModel;
+      this._preserveDataModelSet = true;
     }
 
+    // Property: preserveSort
+    private boolean _preserveSort = true;
+    private boolean _preserveSortSet;
+
+    /**
+     * Gets Indicates whether the state of the sortColumn and sortAscending attribute
+     *                 should be saved and restored and written back to the model during the
+     *                 update model phase.
+     *                 Default: true
+     *
+     * @return  the new preserveSort value
+     */
     public boolean isPreserveSort()
     {
-        if (_preserveSort != null)
-            return _preserveSort.booleanValue();
-        ValueBinding vb = getValueBinding("preserveSort");
-        Boolean v = vb != null ? (Boolean) vb.getValue(getFacesContext()) : null;
-        return v != null ? v.booleanValue() : DEFAULT_PRESERVESORT;
+      if (_preserveSortSet)
+      {
+        return _preserveSort;
+      }
+      ValueExpression expression = getValueExpression("preserveSort");
+      if (expression != null)
+      {
+        return (Boolean)expression.getValue(getFacesContext().getELContext());
+      }
+      return true;
     }
 
-    public void setEnabledOnUserRole(String enabledOnUserRole)
+    /**
+     * Sets Indicates whether the state of the sortColumn and sortAscending attribute
+     *                 should be saved and restored and written back to the model during the
+     *                 update model phase.
+     *                 Default: true
+     * 
+     * @param preserveSort  the new preserveSort value
+     */
+    public void setPreserveSort(boolean preserveSort)
     {
-        _enabledOnUserRole = enabledOnUserRole;
+      this._preserveSort = preserveSort;
+      this._preserveSortSet = true;
     }
+    
+    // Property: enabledOnUserRole
+    private String _enabledOnUserRole;
 
+    /**
+     * Gets If user is in given role, this component will be rendered
+     *                 normally. If not, no hyperlink is rendered but all nested
+     *                 tags (=body) are rendered.
+     *
+     * @return  the new enabledOnUserRole value
+     */
     public String getEnabledOnUserRole()
     {
-        if (_enabledOnUserRole != null)
-            return _enabledOnUserRole;
-        ValueBinding vb = getValueBinding("enabledOnUserRole");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_enabledOnUserRole != null)
+      {
+        return _enabledOnUserRole;
+      }
+      ValueExpression expression = getValueExpression("enabledOnUserRole");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setVisibleOnUserRole(String visibleOnUserRole)
+    /**
+     * Sets If user is in given role, this component will be rendered
+     *                 normally. If not, no hyperlink is rendered but all nested
+     *                 tags (=body) are rendered.
+     * 
+     * @param enabledOnUserRole  the new enabledOnUserRole value
+     */
+    public void setEnabledOnUserRole(String enabledOnUserRole)
     {
-        _visibleOnUserRole = visibleOnUserRole;
+      this._enabledOnUserRole = enabledOnUserRole;
     }
 
+    // Property: visibleOnUserRole
+    private String _visibleOnUserRole;
+
+    /**
+     * Gets If user is in given role, this component will be rendered
+     *                 normally. If not, nothing is rendered and the body of this tag
+     *                 will be skipped.
+     *
+     * @return  the new visibleOnUserRole value
+     */
     public String getVisibleOnUserRole()
     {
-        if (_visibleOnUserRole != null)
-            return _visibleOnUserRole;
-        ValueBinding vb = getValueBinding("visibleOnUserRole");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_visibleOnUserRole != null)
+      {
+        return _visibleOnUserRole;
+      }
+      ValueExpression expression = getValueExpression("visibleOnUserRole");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setRenderedIfEmpty(boolean renderedIfEmpty)
+    /**
+     * Sets If user is in given role, this component will be rendered
+     *                 normally. If not, nothing is rendered and the body of this tag
+     *                 will be skipped.
+     * 
+     * @param visibleOnUserRole  the new visibleOnUserRole value
+     */
+    public void setVisibleOnUserRole(String visibleOnUserRole)
     {
-        _renderedIfEmpty = Boolean.valueOf(renderedIfEmpty);
+      this._visibleOnUserRole = visibleOnUserRole;
     }
-
+    
+    // Property: renderedIfEmpty
+    private boolean _renderedIfEmpty = true;
+    private boolean _renderedIfEmptySet;
+
+    /**
+     * Gets Indicates whether this table should be rendered if the underlying DataModel is
+     *                 empty.
+     *                 You could as well use rendered="#{not empty bean.list}", but this one causes
+     *                 the getList method of your model bean beeing called up to five times per
+     *                 request, which is not optimal when the list is backed by a DB table.
+     *                 Using renderedIfEmpty="false" solves this problem, because the MyFaces
+     *                 extended HtmlDataTable automatically caches the DataModel and calles the
+     *                 model getter only once per request.
+     *                 Default: true
+     *
+     * @return  the new renderedIfEmpty value
+     */
     public boolean isRenderedIfEmpty()
     {
-        if (_renderedIfEmpty != null)
-            return _renderedIfEmpty.booleanValue();
-        ValueBinding vb = getValueBinding("renderedIfEmpty");
-        Boolean v = vb != null ? (Boolean) vb.getValue(getFacesContext()) : null;
-        return v != null ? v.booleanValue() : DEFAULT_RENDEREDIFEMPTY;
+      if (_renderedIfEmptySet)
+      {
+        return _renderedIfEmpty;
+      }
+      ValueExpression expression = getValueExpression("renderedIfEmpty");
+      if (expression != null)
+      {
+        return (Boolean)expression.getValue(getFacesContext().getELContext());
+      }
+      return true;
     }
 
-    public void setRowIndexVar(String rowIndexVar)
+    /**
+     * Sets Indicates whether this table should be rendered if the underlying DataModel is
+     *                 empty.
+     *                 You could as well use rendered="#{not empty bean.list}", but this one causes
+     *                 the getList method of your model bean beeing called up to five times per
+     *                 request, which is not optimal when the list is backed by a DB table.
+     *                 Using renderedIfEmpty="false" solves this problem, because the MyFaces
+     *                 extended HtmlDataTable automatically caches the DataModel and calles the
+     *                 model getter only once per request.
+     *                 Default: true
+     * 
+     * @param renderedIfEmpty  the new renderedIfEmpty value
+     */
+    public void setRenderedIfEmpty(boolean renderedIfEmpty)
     {
-        _rowIndexVar = rowIndexVar;
+      this._renderedIfEmpty = renderedIfEmpty;
+      this._renderedIfEmptySet = true;
     }
+    
+    // Property: rowIndexVar
+    private String _rowIndexVar;
 
+    /**
+     * Gets A parameter name, under which the current rowIndex is set in request scope
+     *                 similar to the var parameter.
+     *
+     * @return  the new rowIndexVar value
+     */
     public String getRowIndexVar()
     {
-        if (_rowIndexVar != null)
-            return _rowIndexVar;
-        ValueBinding vb = getValueBinding("rowIndexVar");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_rowIndexVar != null)
+      {
+        return _rowIndexVar;
+      }
+      ValueExpression expression = getValueExpression("rowIndexVar");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setRowCountVar(String rowCountVar)
+    /**
+     * Sets A parameter name, under which the current rowIndex is set in request scope
+     *                 similar to the var parameter.
+     * 
+     * @param rowIndexVar  the new rowIndexVar value
+     */
+    public void setRowIndexVar(String rowIndexVar)
     {
-        _rowCountVar = rowCountVar;
+      this._rowIndexVar = rowIndexVar;
     }
+    
+    // Property: rowCountVar
+    private String _rowCountVar;
 
+    /**
+     * Gets A parameter name, under which the rowCount is set in request scope
+     *                 similar to the var parameter.
+     *
+     * @return  the new rowCountVar value
+     */
     public String getRowCountVar()
     {
-        if (_rowCountVar != null)
-            return _rowCountVar;
-        ValueBinding vb = getValueBinding("rowCountVar");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_rowCountVar != null)
+      {
+        return _rowCountVar;
+      }
+      ValueExpression expression = getValueExpression("rowCountVar");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setPreviousRowDataVar(String previousRowDataVar)
+    /**
+     * Sets A parameter name, under which the rowCount is set in request scope
+     *                 similar to the var parameter.
+     * 
+     * @param rowCountVar  the new rowCountVar value
+     */
+    public void setRowCountVar(String rowCountVar)
     {
-        _previousRowDataVar = previousRowDataVar;
+      this._rowCountVar = rowCountVar;
     }
+        
+    // Property: previousRowDataVar
+    private String _previousRowDataVar;
 
+    /**
+     * Gets A parameter name, under which the previous RowData Object is set in request scope
+     *                 similar to the rowIndexVar and rowCountVar parameters.
+     *                 Mind that the value of this request scope attribute is null in the first row
+     *                 or when isRowAvailable returns false for the previous row.
+     *
+     * @return  the new previousRowDataVar value
+     */
     public String getPreviousRowDataVar()
     {
-        if (_previousRowDataVar != null)
-            return _previousRowDataVar;
-        ValueBinding vb = getValueBinding("previousRowDataVar");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_previousRowDataVar != null)
+      {
+        return _previousRowDataVar;
+      }
+      ValueExpression expression = getValueExpression("previousRowDataVar");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
-    public void setSortedColumnVar(String sortedColumnVar)
+    /**
+     * Sets A parameter name, under which the previous RowData Object is set in request scope
+     *                 similar to the rowIndexVar and rowCountVar parameters.
+     *                 Mind that the value of this request scope attribute is null in the first row
+     *                 or when isRowAvailable returns false for the previous row.
+     * 
+     * @param previousRowDataVar  the new previousRowDataVar value
+     */
+    public void setPreviousRowDataVar(String previousRowDataVar)
     {
-        _sortedColumnVar = sortedColumnVar;
+      this._previousRowDataVar = previousRowDataVar;
     }
+    
+    // Property: sortedColumnVar
+    private String _sortedColumnVar;
 
+    /**
+     * Gets A parameter name, under which the a boolean is set in request scope
+     *                 similar to the var parameter. TRUE for the column that is currently sorted, FALSE otherwise.
+     *
+     * @return  the new sortedColumnVar value
+     */
     public String getSortedColumnVar()
     {
-        if (_sortedColumnVar != null) return _sortedColumnVar;
-        ValueBinding vb = getValueBinding("sortedColumnVar");
-        return vb != null ? (String) vb.getValue(getFacesContext()) : null;
+      if (_sortedColumnVar != null)
+      {
+        return _sortedColumnVar;
+      }
+      ValueExpression expression = getValueExpression("sortedColumnVar");
+      if (expression != null)
+      {
+        return (String)expression.getValue(getFacesContext().getELContext());
+      }
+      return null;
     }
 
+    /**
+     * Sets A parameter name, under which the a boolean is set in request scope
+     *                 similar to the var parameter. TRUE for the column that is currently sorted, FALSE otherwise.
+     * 
+     * @param sortedColumnVar  the new sortedColumnVar value
+     */
+    public void setSortedColumnVar(String sortedColumnVar)
+    {
+      this._sortedColumnVar = sortedColumnVar;
+    }
+    
     //------------------ GENERATED CODE END ---------------------------------------
 }

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/Alias.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/Alias.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/Alias.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/Alias.java Tue Jan 29 18:58:48 2008
@@ -18,6 +18,7 @@
  */
 package org.apache.myfaces.custom.aliasbean;
 
+import javax.el.ValueExpression;
 import javax.faces.component.UIComponent;
 import javax.faces.context.FacesContext;
 import javax.faces.el.ValueBinding;
@@ -92,21 +93,24 @@
 		if( evaluatedExpression != null )
 			return;
 		
-		ValueBinding valueVB = null;
+		ValueExpression valueVB = null;
         if (_valueExpression == null) {
-            valueVB = _aliasComponent.getValueBinding("value");
+            valueVB = _aliasComponent.getValueExpression("value");
             _valueExpression = valueVB.getExpressionString();
         }
 
         if( valueVB == null ){
             if( _valueExpression.startsWith("#{") ){
-                valueVB = facesContext.getApplication().createValueBinding(_valueExpression);
-				evaluatedExpression = valueVB.getValue(facesContext);
+                valueVB = facesContext.getApplication().getExpressionFactory()
+                    .createValueExpression(facesContext.getELContext(),                            
+                            _valueExpression,
+                            Object.class);
+				evaluatedExpression = valueVB.getValue(facesContext.getELContext());
             }else{
 				evaluatedExpression = _valueExpression;
             }
         }else{
-			evaluatedExpression = valueVB.getValue(facesContext);
+			evaluatedExpression = valueVB.getValue(facesContext.getELContext());
         }
 	}
 
@@ -117,21 +121,22 @@
 		if( _active )
 			return;
 
-        ValueBinding aliasVB;
+        ValueExpression aliasVB;
         if (_aliasBeanExpression == null) {
-            aliasVB = _aliasComponent.getValueBinding("alias");
+            aliasVB = _aliasComponent.getValueExpression("alias");
 			if( aliasVB == null )
 				return;
             _aliasBeanExpression = aliasVB.getExpressionString();
 			if( _aliasBeanExpression == null )
 				return;
         } else {
-            aliasVB = facesContext.getApplication().createValueBinding(_aliasBeanExpression);
+            aliasVB = facesContext.getApplication().getExpressionFactory().
+                createValueExpression(facesContext.getELContext(),_aliasBeanExpression,Object.class);
         }
 
 		computeEvaluatedExpression( facesContext );
 		
-        aliasVB.setValue(facesContext, evaluatedExpression);
+        aliasVB.setValue(facesContext.getELContext(), evaluatedExpression);
 		_active = true;
 
         log.debug("makeAlias: " + _valueExpression + " = " + _aliasBeanExpression);
@@ -148,8 +153,8 @@
         evaluatedExpression = null;
 
         log.debug("removeAlias: " + _valueExpression + " != " + _aliasBeanExpression);
-        ValueBinding aliasVB = _aliasComponent.getValueBinding("alias");
+        ValueExpression aliasVB = _aliasComponent.getValueExpression("alias");
         if( aliasVB != null )
-			aliasVB.setValue(facesContext, null);
+			aliasVB.setValue(facesContext.getELContext(), null);
 	}
 }

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBean.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBean.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBean.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBean.java Tue Jan 29 18:58:48 2008
@@ -18,26 +18,26 @@
  */
 package org.apache.myfaces.custom.aliasbean;
 
+import java.io.IOException;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-import java.io.IOException;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.myfaces.shared_tomahawk.util._ComponentUtils;
-import org.apache.myfaces.shared_tomahawk.util.RestoreStateUtils;
-import org.apache.myfaces.shared_tomahawk.component.BindingAware;
 
+import javax.el.ValueExpression;
 import javax.faces.component.UIComponent;
 import javax.faces.component.UIComponentBase;
 import javax.faces.context.FacesContext;
-import javax.faces.el.ValueBinding;
 import javax.faces.event.AbortProcessingException;
 import javax.faces.event.FacesEvent;
 
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.myfaces.shared_tomahawk.component.BindingAware;
+import org.apache.myfaces.shared_tomahawk.util.RestoreStateUtils;
+import org.apache.myfaces.shared_tomahawk.util._ComponentUtils;
+
 /**
  * The aliasBean tag allows you to create a temporary name for a real bean.
  * The temporary name exists (is visible) only to the children of the aliasBean.
@@ -120,8 +120,8 @@
         // passes that data on to the alias instead. However it is possible for someone
         // to use f:attribute (or other mechanism?) to set the value instead. So when the
         // alias has no value, look for it there.
-        ValueBinding vb = getValueBinding("value");
-        return vb != null ? _ComponentUtils.getStringValue(getFacesContext(), vb) : null;
+        ValueExpression vb = getValueExpression("value");
+        return vb != null ?  (String) vb.getValue(getFacesContext().getELContext()) : null;
     }
 
     public void setValue(String valueExpression)

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeanTag.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeanTag.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeanTag.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeanTag.java Tue Jan 29 18:58:48 2008
@@ -18,10 +18,11 @@
  */
 package org.apache.myfaces.custom.aliasbean;
 
+import javax.el.ValueExpression;
 import javax.faces.component.UIComponent;
+import javax.faces.webapp.UIComponentELTag;
 import javax.servlet.jsp.JspException;
 
-import org.apache.myfaces.shared_tomahawk.taglib.UIComponentTagBase;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 
@@ -29,44 +30,17 @@
  * @author Sylvain Vieujot (latest modification by $Author$)
  * @version $Revision$ $Date$
  */
-public class AliasBeanTag extends UIComponentTagBase {
+public class AliasBeanTag extends UIComponentELTag
+{
 
     private Log log = LogFactory.getLog(AliasBeanTag.class);
-
-    private String _alias;
-    private String _valueExpression;
-
-    public void release() {
-        super.release();
-
-        _alias=null;
-        _valueExpression=null;
-
-    }
-
-    protected void setProperties(UIComponent component) {
-        super.setProperties(component);
-
-        setStringProperty(component, "alias", _alias);
-        setStringProperty(component, "value", _valueExpression);
-    }
-
-    public String getComponentType() {
-        return AliasBean.COMPONENT_TYPE;
-    }
-
-    public String getRendererType() {
-        return null;
-    }
-
-    public void setAlias(String alias){
-        _alias = alias;
-    }
-
-    public void setValue(String valueExpression){
-        _valueExpression = valueExpression;
+    /**
+     * Construct an instance of the AliasBeanELTag.
+     */
+    public AliasBeanTag()
+    {
     }
-
+    
     public int doStartTag() throws JspException
     {
         int retVal= super.doStartTag();
@@ -100,4 +74,71 @@
 
         return super.doEndTag();
     }
-}
\ No newline at end of file
+    
+    @Override
+    public String getComponentType()
+    {
+        return "org.apache.myfaces.AliasBean";
+    }
+
+    public String getRendererType()
+    {
+        return null;
+    }
+
+    private java.lang.String _id;
+
+    public void setId(java.lang.String id)
+    {
+        _id = id;
+    }
+
+    private ValueExpression _alias;
+
+    public void setAlias(ValueExpression alias)
+    {
+        _alias = alias;
+    }
+
+    private ValueExpression _value;
+
+    public void setValue(ValueExpression value)
+    {
+        _value = value;
+    }
+
+    @Override
+    protected void setProperties(UIComponent component)
+    {
+        if (!(component instanceof AliasBean))
+        {
+            throw new IllegalArgumentException("Component "
+                    + component.getClass().getName() + " is no AliasBean");
+        }
+        AliasBean comp = (AliasBean) component;
+
+        super.setProperties(component);
+
+        if (_id != null)
+        {
+            comp.getAttributes().put("id", _id);
+        }
+        if (_alias != null)
+        {
+            comp.setValueExpression("alias", _alias);
+        }
+        if (_value != null)
+        {
+            comp.setValueExpression("value", _value);
+        }
+    }
+
+    @Override
+    public void release()
+    {
+        super.release();
+        _id = null;
+        _alias = null;
+        _value = null;
+    }
+}

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeansScopeTag.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeansScopeTag.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeansScopeTag.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/aliasbean/AliasBeansScopeTag.java Tue Jan 29 18:58:48 2008
@@ -18,18 +18,18 @@
  */
 package org.apache.myfaces.custom.aliasbean;
 
-import org.apache.myfaces.shared_tomahawk.taglib.UIComponentTagBase;
+import javax.faces.component.UIComponent;
+import javax.faces.webapp.UIComponentELTag;
+import javax.servlet.jsp.JspException;
+
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 
-import javax.servlet.jsp.JspException;
-import javax.faces.component.UIComponent;
-
 /**
  * @author Sylvain Vieujot (latest modification by $Author$)
  * @version $Revision$ $Date$
  */
-public class AliasBeansScopeTag extends UIComponentTagBase
+public class AliasBeansScopeTag extends UIComponentELTag
 {
     private Log log = LogFactory.getLog(AliasBeansScopeTag.class);
 

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/calendar/HtmlCalendarRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/calendar/HtmlCalendarRenderer.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/calendar/HtmlCalendarRenderer.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/calendar/HtmlCalendarRenderer.java Tue Jan 29 18:58:48 2008
@@ -396,7 +396,7 @@
                                                     int firstDayOfWeek, UIComponent uiComponent,
                                                     String popupCalendarVariable)
     {
-        HtmlInputCalendar calendar = (HtmlInputCalendar) uiComponent;
+        
 
         int realFirstDayOfWeek = firstDayOfWeek-1;//Java has different starting-point;
 
@@ -421,29 +421,31 @@
         StringBuffer script = new StringBuffer();
         AddResource ar = AddResourceFactory.getInstance(facesContext);
 
-        // Set the themePrefix variable
-        String popupTheme = calendar.getPopupTheme();
-        if (popupTheme == null)
-        {
-            popupTheme = "DB";
-        }
-        setStringVariable(script,popupCalendarVariable + ".initData.themePrefix", "jscalendar-" + popupTheme);
-
-        // specify the URL for the directory in which all the .gif images can be found
-        String imageLocation = HtmlRendererUtils.getImageLocation(uiComponent);
-        if(imageLocation == null)
-        {
-            String uri = ar.getResourceUri(facesContext, HtmlCalendarRenderer.class, popupTheme + "/");
-            setStringVariable(script,popupCalendarVariable + ".initData.imgDir",
+        if (uiComponent instanceof HtmlInputCalendar){
+            HtmlInputCalendar calendar = (HtmlInputCalendar) uiComponent;
+            // Set the themePrefix variable
+            String popupTheme = calendar.getPopupTheme();
+            if (popupTheme == null)
+            {
+                popupTheme = "DB";
+            }
+            setStringVariable(script,popupCalendarVariable + ".initData.themePrefix", "jscalendar-" + popupTheme);
+
+            // specify the URL for the directory in which all the .gif images can be found
+            String imageLocation = HtmlRendererUtils.getImageLocation(uiComponent);
+            if(imageLocation == null)
+            {
+                String uri = ar.getResourceUri(facesContext, HtmlCalendarRenderer.class, popupTheme + "/");
+                setStringVariable(script,popupCalendarVariable + ".initData.imgDir",
                               JavascriptUtils.encodeString(uri));
-        }
-        else
-        {
-            setStringVariable(script, popupCalendarVariable +".initData.imgDir",
+            }
+            else
+            {
+                setStringVariable(script, popupCalendarVariable +".initData.imgDir",
                               (JavascriptUtils.encodeString(AddResourceFactory.getInstance(facesContext)
                                                             .getResourceUri(facesContext, imageLocation+"/"))) );
+            }
         }
-
         defineStringArray(script, popupCalendarVariable +".initData.monthName", mapMonths(symbols));
         defineStringArray(script, popupCalendarVariable +".initData.dayName", weekDays);
         setIntegerVariable(script, popupCalendarVariable +".initData.startAt",realFirstDayOfWeek);

Added: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/collapsiblepanel/HtmlCollapsiblePanelTagBase.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/collapsiblepanel/HtmlCollapsiblePanelTagBase.java?rev=616601&view=auto
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/collapsiblepanel/HtmlCollapsiblePanelTagBase.java (added)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/collapsiblepanel/HtmlCollapsiblePanelTagBase.java Tue Jan 29 18:58:48 2008
@@ -0,0 +1,96 @@
+/*
+ * 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.collapsiblepanel;
+
+import org.apache.myfaces.shared_tomahawk.taglib.html.HtmlInputTextTag;
+
+import javax.faces.component.UIComponent;
+import javax.servlet.jsp.tagext.BodyTag;
+import javax.servlet.jsp.tagext.BodyContent;
+import javax.servlet.jsp.JspException;
+import javax.servlet.jsp.JspWriter;
+import javax.faces.webapp.UIComponentELTag;
+
+/**
+ * 
+ * @author Kalle Korhonen (latest modification by $Author$)
+ * @version $Revision$ $Date$
+ */
+public abstract class HtmlCollapsiblePanelTagBase
+        extends UIComponentELTag implements BodyTag
+{
+    //private static final Log log = LogFactory.getLog(HtmlCollapsiblePanelTag.class);
+
+    public void release() {
+        super.release();
+        bodyContent = null;
+    }
+
+    protected void setProperties(UIComponent component)
+    {
+        super.setProperties(component);
+
+    }
+
+    // API field
+    //protected BodyContent bodyContent;
+
+
+    /*
+    public int doAfterBody()
+            throws JspException
+    {
+        return getDoAfterBodyValue();
+    }
+    */
+
+    public BodyContent getBodyContent()
+    {
+        return bodyContent;
+    }
+
+    public void setBodyContent(BodyContent bodyContent)
+    {
+        this.bodyContent = bodyContent;
+    }
+
+    /*
+    public JspWriter getPreviousOut()
+    {
+        return bodyContent.getEnclosingWriter();
+    }
+    */
+
+    /*
+    protected int getDoStartValue()
+            throws JspException
+    {
+        return BodyTag.EVAL_BODY_BUFFERED;
+    }
+    */
+
+    /*
+    protected int getDoAfterBodyValue()
+            throws JspException
+    {
+        return BodyTag.SKIP_BODY;
+    }
+    */
+
+}

Propchange: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/collapsiblepanel/HtmlCollapsiblePanelTagBase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/collapsiblepanel/HtmlCollapsiblePanelTagBase.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocument.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocument.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocument.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocument.java Tue Jan 29 18:58:48 2008
@@ -37,7 +37,12 @@
 	{
 		setRendererType(renderType);
 	}
-
+	
+    public AbstractDocument()
+    {
+        setRendererType(null);
+    }
+	
 	public String getFamily()
 	{
 		return COMPONENT_FAMILY;

Modified: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTag.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTag.java?rev=616601&r1=616600&r2=616601&view=diff
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTag.java (original)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTag.java Tue Jan 29 18:58:48 2008
@@ -19,8 +19,11 @@
 package org.apache.myfaces.custom.document;
 
 import javax.faces.component.UIComponent;
+import javax.faces.webapp.UIComponentELTag;
+
+import org.apache.myfaces.custom.document.AbstractDocument;
+
 
-import org.apache.myfaces.shared_tomahawk.taglib.html.HtmlComponentTagBase;
 
 /**
  * Document to enclose the whole document. If not otherwise possible you can use
@@ -29,30 +32,42 @@
  * @author Mario Ivankovits (latest modification by $Author$)
  * @version $Revision$ $Date$
  */
-public abstract class AbstractDocumentTag extends HtmlComponentTagBase
+public abstract class AbstractDocumentTag extends UIComponentELTag
 {
-	private String _state = null;
-
-	public void release()
-	{
-		super.release();
-		_state = null;
-	}
 
 	public abstract String getComponentType();
 	public abstract String getRendererType();
 
-	protected void setProperties(UIComponent component)
+	private java.lang.String _state;
+	public void setState(java.lang.String state)
 	{
-		super.setProperties(component);
-		setStringProperty(component, "state", _state);
+	  _state = state;
 	}
 
-	public void setState(String state)
+	  @Override
+	protected void setProperties(UIComponent component)
 	{
-		this._state = state;
+	  if (!(component instanceof AbstractDocument))
+	  {
+	    throw new IllegalArgumentException("Component " + component.getClass().getName() + " is no AbstractDocument");
+	  }
+	  AbstractDocument comp = (AbstractDocument)component;
+
+	  super.setProperties(component);
+
+	  if (_state != null) 
+	  {
+	    comp.getAttributes().put("state", _state);
+	  }
 	}
 
+	@Override
+	public void release()
+	{
+	  super.release();
+	  _state = null;
+	}
+	
 	public String getState()
 	{
 		return _state;

Added: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTagBase.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTagBase.java?rev=616601&view=auto
==============================================================================
--- myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTagBase.java (added)
+++ myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTagBase.java Tue Jan 29 18:58:48 2008
@@ -0,0 +1,38 @@
+/*
+ * 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.document;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.shared_tomahawk.taglib.html.HtmlComponentTagBase;
+
+/**
+ * Document to enclose the whole document. If not otherwise possible you can use
+ * state="start|end" to demarkate the document boundaries
+ * 
+ * @author Mario Ivankovits (latest modification by $Author$)
+ * @version $Revision$ $Date$
+ */
+public abstract class AbstractDocumentTagBase extends HtmlComponentTagBase
+{
+
+	public abstract String getComponentType();
+	public abstract String getRendererType();
+
+}
\ No newline at end of file

Propchange: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTagBase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: myfaces/tomahawk/branches/1_2_0/core/src/main/java/org/apache/myfaces/custom/document/AbstractDocumentTagBase.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL