shale-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gvanma...@apache.org
Subject svn commit: r471910 - in /shale/framework/trunk/shale-clay/src: main/java/org/apache/shale/clay/component/ main/java/org/apache/shale/clay/component/chain/ main/java/org/apache/shale/clay/parser/builder/ main/resources/META-INF/ main/resources/org/apac...
Date Mon, 06 Nov 2006 22:44:57 GMT
Author: gvanmatre
Date: Mon Nov  6 14:44:56 2006
New Revision: 471910

URL: http://svn.apache.org/viewvc?view=rev&rev=471910
Log:
Provided "binding" attribute support for Converters, Validators, ActionListeners and ValueChangeListeners as part of the JSF 1.2 spec enhancements (SHALE-67).

Added:
    shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java   (with props)
    shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html   (with props)
Modified:
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/Clay.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/AbstractCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateActionListenerCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateComponentCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateConverterCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValidatorCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValueChangeListenerCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionListenerCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyConverterCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValidatorCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueChangeListenerCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueCommand.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/ElementBuilder.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/JsfDefaultBuilder.java
    shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/OutputLinkBuilder.java
    shale/framework/trunk/shale-clay/src/main/resources/META-INF/clay-config.xml
    shale/framework/trunk/shale-clay/src/main/resources/org/apache/shale/clay/component/chain/shale-clay-config.xml

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/Clay.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/Clay.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/Clay.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/Clay.java Mon Nov  6 14:44:56 2006
@@ -552,7 +552,7 @@
     }
 
     /**
-     * <p>Returns the component's family.</p>
+     * @return Returns the component's family.
      */
     public String getFamily() {
         return "org.apache.shale.clay";

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/AbstractCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/AbstractCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/AbstractCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/AbstractCommand.java Mon Nov  6 14:44:56 2006
@@ -37,6 +37,7 @@
 import org.apache.shale.clay.config.Globals;
 import org.apache.shale.clay.config.beans.SymbolBean;
 import org.apache.shale.util.Messages;
+import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -62,6 +63,20 @@
     }
 
     /**
+     * <p>Shale tag helper class that contains utility methods for setting
+     * component binding and method properties.</p>
+     */
+    private Tags tagUtils = new Tags();
+
+    /**
+     * @return Shale tag helper class that contains utility methods for setting
+     * component binding and method properties.
+     */
+    protected Tags getTagUtils() {
+        return tagUtils;
+    }
+
+    /**
      * <p>
      * Returns the {@link Catalog} from the
      * <code>Globals.CLAY_CATALOG_NAME</code> in the
@@ -342,6 +357,30 @@
      * @exception Exception checked
      */
     public abstract boolean execute(Context context) throws Exception;
+
+    /**
+     * <p>Return true if the specified string contains an EL expression.</p>
+     *
+     * <p>This is taken almost verbatim from {@link javax.faces.webapp.UIComponentTag}
+     * in order to remove JSP dependencies from the renderers.</p>
+     *
+     * @param value String to be checked for being an expression
+     * @return <code>true</code> if the value is a binding expression
+     */
+    protected boolean isValueReference(String value) {
+
+        if (value == null) {
+            return false;
+        }
+
+        int start = value.indexOf("#{");
+        if (start < 0) {
+            return false;
+        }
+
+        int end = value.lastIndexOf('}');
+        return (end >= 0) && (start < end);
+    }
 
 }
 

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateActionListenerCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateActionListenerCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateActionListenerCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateActionListenerCommand.java Mon Nov  6 14:44:56 2006
@@ -23,11 +23,13 @@
 import javax.faces.component.ActionSource;
 import javax.faces.component.UIComponent;
 import javax.faces.context.FacesContext;
+import javax.faces.el.ValueBinding;
 import javax.faces.event.ActionListener;
 
 import org.apache.commons.chain.Context;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
 
 /**
@@ -99,20 +101,30 @@
         ActionListener listener = null;
         try {
 
-            ClassLoader loader = Thread.currentThread().getContextClassLoader();
-            if (loader == null) {
-                loader = getClass().getClassLoader();
-            }
+            AttributeBean attr = displayElement.getAttribute("binding");
+            if (attr != null && isValueReference(attr.getValue())) {
+                clayContext.setAttribute(attr);
+                String expr = replaceMnemonic(clayContext);
+                ValueBinding vb = facesContext.getApplication().createValueBinding(expr);
+                listener = (ActionListener) vb.getValue(facesContext);
+            } else {
+
+                ClassLoader loader = Thread.currentThread().getContextClassLoader();
+                if (loader == null) {
+                    loader = getClass().getClassLoader();
+                }
 
-            listener = (ActionListener) loader.loadClass(
-                    displayElement.getComponentType()).newInstance();
+                listener = (ActionListener) loader.loadClass(
+                        displayElement.getComponentType()).newInstance();
 
-            loader = null;
+                loader = null;
+            }
         } catch (Exception e) {
             log.error(getMessages().getMessage("create.actionListener.error",
                     new Object[] { displayElement }), e);
-                    throw e;
+            throw e;
         }
+
         parent.addActionListener(listener);
         // reassign the child to the ActionListener for the
         // AssignPropertiesCommand

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateComponentCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateComponentCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateComponentCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateComponentCommand.java Mon Nov  6 14:44:56 2006
@@ -122,7 +122,6 @@
 
             if (id == null) {
                 id = facesContext.getViewRoot().createUniqueId();
-                //id = createUniqueId(facesContext, displayElement);
             } else {
                 id = replaceMnemonic(clayContext, id);
             }

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateConverterCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateConverterCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateConverterCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateConverterCommand.java Mon Nov  6 14:44:56 2006
@@ -24,10 +24,12 @@
 import javax.faces.component.ValueHolder;
 import javax.faces.context.FacesContext;
 import javax.faces.convert.Converter;
+import javax.faces.el.ValueBinding;
 
 import org.apache.commons.chain.Context;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
 
 /**
@@ -98,13 +100,23 @@
         }
         Converter converter = null;
         try {
-            converter = facesContext.getApplication().createConverter(
-                    displayElement.getComponentType());
+
+            AttributeBean attr = displayElement.getAttribute("binding");
+            if (attr != null && isValueReference(attr.getValue())) {
+                clayContext.setAttribute(attr);
+                String expr = replaceMnemonic(clayContext);
+                ValueBinding vb = facesContext.getApplication().createValueBinding(expr);
+                converter = (Converter) vb.getValue(facesContext);
+            } else {
+                converter = facesContext.getApplication().createConverter(
+                        displayElement.getComponentType());
+            }
         } catch (Exception e) {
             log.error(getMessages().getMessage("create.converter.error",
                     new Object[] { displayElement }), e);
-                    throw e;
+            throw e;
         }
+
         if (converter != null) {
             parent.setConverter(converter);
             // reassign the child to the converter for the

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValidatorCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValidatorCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValidatorCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValidatorCommand.java Mon Nov  6 14:44:56 2006
@@ -23,11 +23,13 @@
 import javax.faces.component.EditableValueHolder;
 import javax.faces.component.UIComponent;
 import javax.faces.context.FacesContext;
+import javax.faces.el.ValueBinding;
 import javax.faces.validator.Validator;
 
 import org.apache.commons.chain.Context;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
 
 /**
@@ -95,12 +97,22 @@
 
         Validator validator = null;
         try {
-            validator = facesContext.getApplication().createValidator(
-                    displayElement.getComponentType());
+            AttributeBean attr = displayElement.getAttribute("binding");
+            if (attr != null && isValueReference(attr.getValue())) {
+                clayContext.setAttribute(attr);
+                String expr = replaceMnemonic(clayContext);
+                ValueBinding vb = facesContext.getApplication()
+                        .createValueBinding(expr);
+                validator = (Validator) vb.getValue(facesContext);
+
+            } else {
+                validator = facesContext.getApplication().createValidator(
+                        displayElement.getComponentType());
+            }
         } catch (Exception e) {
             log.error(getMessages().getMessage("create.validator.error",
                     new Object[] { displayElement }), e);
-                    throw e;
+            throw e;
         }
         parent.addValidator(validator);
         // reassign the child to the validator for the

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValueChangeListenerCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValueChangeListenerCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValueChangeListenerCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/CreateValueChangeListenerCommand.java Mon Nov  6 14:44:56 2006
@@ -23,11 +23,13 @@
 import javax.faces.component.EditableValueHolder;
 import javax.faces.component.UIComponent;
 import javax.faces.context.FacesContext;
+import javax.faces.el.ValueBinding;
 import javax.faces.event.ValueChangeListener;
 
 import org.apache.commons.chain.Context;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
 
 /**
@@ -95,15 +97,25 @@
         ValueChangeListener listener = null;
         try {
 
-            ClassLoader loader = Thread.currentThread().getContextClassLoader();
-            if (loader == null) {
-                loader = getClass().getClassLoader();
-            }
+            AttributeBean attr = displayElement.getAttribute("binding");
+            if (attr != null && isValueReference(attr.getValue())) {
+                clayContext.setAttribute(attr);
+                String expr = replaceMnemonic(clayContext);
+                ValueBinding vb = facesContext.getApplication().createValueBinding(expr);
+                listener = (ValueChangeListener) vb.getValue(facesContext);
+
+            } else {
+
+                ClassLoader loader = Thread.currentThread().getContextClassLoader();
+                if (loader == null) {
+                    loader = getClass().getClassLoader();
+                }
 
-            listener = (ValueChangeListener) loader.loadClass(
-                    displayElement.getComponentType()).newInstance();
+                listener = (ValueChangeListener) loader.loadClass(
+                        displayElement.getComponentType()).newInstance();
 
-            loader = null;
+                loader = null;
+            }
         } catch (Exception e) {
             log.error(getMessages().getMessage("create.valueChangeListener"), e);
             throw e;

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionCommand.java Mon Nov  6 14:44:56 2006
@@ -30,7 +30,6 @@
 import org.apache.commons.logging.LogFactory;
 import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
-import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -53,13 +52,6 @@
     }
 
     /**
-     * <p>Shale tag helper class that contains utility methods for setting
-     * component binding and method properties.</p>
-     */
-    private Tags tagUtils = new Tags();
-
-
-    /**
      * <p>
      * Looks to see if the {@link AttributeBean} on the {@link ClayContext} is a
      * <code>action</code> attribute. If it is, create a
@@ -94,10 +86,6 @@
             throw new NullPointerException(getMessages().getMessage("clay.null.facesContext"));
         }
 
-        if (tagUtils == null) {
-            throw new NullPointerException(getMessages().getMessage("clay.null.tagUtils"));
-        }
-
         if (attributeBean.getName().equals("action") && attributeBean.getValue() != null) {
             isFinal = true;
 
@@ -109,7 +97,7 @@
             if (child instanceof ActionSource) {
                 String expr = null;
                 expr = replaceMnemonic(clayContext);
-                tagUtils.setAction(child, expr);
+                getTagUtils().setAction(child, expr);
             } else {
                 log.error(getMessages().getMessage("property.action.error", new Object[] {attributeBean}));
             }

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionListenerCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionListenerCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionListenerCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyActionListenerCommand.java Mon Nov  6 14:44:56 2006
@@ -30,7 +30,6 @@
 import org.apache.commons.logging.LogFactory;
 import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
-import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -53,12 +52,6 @@
     }
 
     /**
-     * <p>Shale tag helper class that contains utility methods for setting
-     * component binding and method properties.</p>
-     */
-    private Tags tagUtils = new Tags();
-
-    /**
      * <p>
      * Looks to see if the {@link AttributeBean} on the {@link ClayContext} is a
      * <code>actionListener</code> attribute. If it is, create a
@@ -104,7 +97,7 @@
             if (child instanceof ActionSource) {
 
                 String expr = replaceMnemonic(clayContext);
-                tagUtils.setActionListener(child, expr);
+                getTagUtils().setActionListener(child, expr);
 
             } else {
                 log.error(getMessages().getMessage("property.actionListener.error", new Object[] {attributeBean}));

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyConverterCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyConverterCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyConverterCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyConverterCommand.java Mon Nov  6 14:44:56 2006
@@ -24,7 +24,6 @@
 import javax.faces.component.ValueHolder;
 import javax.faces.context.FacesContext;
 import javax.faces.convert.Converter;
-import javax.faces.webapp.UIComponentTag;
 
 import org.apache.commons.chain.Command;
 import org.apache.commons.chain.Context;
@@ -32,7 +31,6 @@
 import org.apache.commons.logging.LogFactory;
 import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
-import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -55,12 +53,6 @@
     }
 
     /**
-     * <p>Shale tag helper class that contains utility methods for setting
-     * component binding and method properties.</p>
-     */
-    private Tags tagUtils = new Tags();
-
-    /**
      * <p>
      * Looks to see if the {@link AttributeBean} on the {@link ClayContext} is a
      * <code>converter</code> attribute. If it is, create a
@@ -106,11 +98,11 @@
             if (child instanceof ValueHolder) {
                 String expr = null;
 
-                boolean isEL = UIComponentTag.isValueReference(attributeBean.getValue());
+                boolean isEL = isValueReference(attributeBean.getValue());
                 expr = replaceMnemonic(clayContext);
 
                 if (isEL) {
-                   tagUtils.setValueBinding(child, "converter", expr);
+                   getTagUtils().setValueBinding(child, "converter", expr);
                 } else {
                     Converter converter = null;
                     try {

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValidatorCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValidatorCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValidatorCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValidatorCommand.java Mon Nov  6 14:44:56 2006
@@ -30,7 +30,6 @@
 import org.apache.commons.logging.LogFactory;
 import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
-import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -54,12 +53,6 @@
     }
 
     /**
-     * <p>Shale tag helper class that contains utility methods for setting
-     * component binding and method properties.</p>
-     */
-    private Tags tagUtils = new Tags();
-
-    /**
      * <p>
      * Looks to see if the {@link AttributeBean} on the {@link ClayContext} is a
      * <code>validator</code> attribute. If it is, create a
@@ -103,7 +96,7 @@
             if (child instanceof EditableValueHolder) {
 
                 String expr = replaceMnemonic(clayContext);
-                tagUtils.setValidator(child, expr);
+                getTagUtils().setValidator(child, expr);
 
             } else {
                 log.error(getMessages().getMessage("property.validator.error", new Object[] {attributeBean}));

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueChangeListenerCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueChangeListenerCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueChangeListenerCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueChangeListenerCommand.java Mon Nov  6 14:44:56 2006
@@ -30,7 +30,6 @@
 import org.apache.commons.logging.LogFactory;
 import org.apache.shale.clay.config.beans.AttributeBean;
 import org.apache.shale.clay.config.beans.ComponentBean;
-import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -54,12 +53,6 @@
     }
 
     /**
-     * <p>Shale tag helper class that contains utility methods for setting
-     * component binding and method properties.</p>
-     */
-    private Tags tagUtils = new Tags();
-
-    /**
      * <p>
      * Looks to see if the {@link AttributeBean} on the {@link ClayContext} is a
      * <code>valueChangeListener</code> attribute. If it is, create a
@@ -103,7 +96,7 @@
             if (child instanceof EditableValueHolder) {
 
                 String expr = replaceMnemonic(clayContext);
-                tagUtils.setValueChangeListener(child, expr);
+                getTagUtils().setValueChangeListener(child, expr);
 
             } else {
                 log.error(getMessages().getMessage("property.valueChangeListener.error", new Object[] {attributeBean}));

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueCommand.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueCommand.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueCommand.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/component/chain/PropertyValueCommand.java Mon Nov  6 14:44:56 2006
@@ -33,7 +33,6 @@
 import org.apache.shale.clay.config.beans.ComponentBean;
 import org.apache.shale.util.ConverterHelper;
 import org.apache.shale.util.PropertyHelper;
-import org.apache.shale.util.Tags;
 
 /**
  * <p>
@@ -56,13 +55,6 @@
      */
     private ConverterHelper converterHelper = new ConverterHelper();
 
-
-    /**
-     * <p>Shale tag helper class that contains utility methods for setting
-     * component binding and method properties.</p>
-     */
-    private Tags tagUtils = new Tags();
-
     /**
      * <p>Sets a property value on the target component.  If the data
      * type of the target bean property is not a String and the property
@@ -145,6 +137,12 @@
             throw new NullPointerException(getMessages().getMessage("clay.null.facesContext"));
         }
 
+        // don't try to set the binding attribute of anything but a component
+        if (attributeBean.getName().equals("binding")
+                && !(child instanceof UIComponentBase)) {
+            return isFinal;
+
+        }
         // replace all symbols returning the target attribute value
         String expr = replaceMnemonic(clayContext);
 
@@ -153,15 +151,6 @@
            return isFinal;
         }
 
-        //when using the html templating, javascript and css will have matching curly braces {}.
-        //and pound sign # too.
-        int pound = -1;
-        int leftCurly = -1;
-        int rightCurly = -1;
-
-        pound = expr.indexOf('#');
-        leftCurly = expr.indexOf('{');
-        rightCurly = expr.indexOf('}');
 
         String bindingType = attributeBean.getBindingType();
         if (bindingType == null) {
@@ -169,8 +158,7 @@
         }
 
         //contains expression language
-        boolean isEL = ((pound > -1 && leftCurly > -1 && rightCurly > -1)
-                && (rightCurly > leftCurly) && ((leftCurly - pound) == 1));
+        boolean isEL = isValueReference(expr);
         //use value binding
         boolean isVB = ((bindingType.equals(AttributeBean.BINDING_TYPE_VALUE))
                         && (child instanceof UIComponentBase));
@@ -178,7 +166,7 @@
         boolean isEarly = bindingType.equals(AttributeBean.BINDING_TYPE_EARLY);
 
         if (isEL && isVB) {
-           tagUtils.setValueBinding((UIComponentBase) child, attributeBean.getName(), expr);
+           getTagUtils().setValueBinding((UIComponentBase) child, attributeBean.getName(), expr);
         } else if (isEL && isEarly) {
             ValueBinding vb = facesContext.getApplication().createValueBinding(expr);
             Object value = vb.getValue(facesContext);

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/ElementBuilder.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/ElementBuilder.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/ElementBuilder.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/ElementBuilder.java Mon Nov  6 14:44:56 2006
@@ -421,7 +421,7 @@
 
 
     /**
-     * <p>Test the value of the node and returns <code>true</code> if 
+     * <p>Test the value of the node and returns <code>true</code> if
      * the value is only whitespace.</p>
      *
      * @param node markup node
@@ -433,7 +433,7 @@
              i < node.getToken().getEndOffset(); i++) {
            char c = document.charAt(i);
            if (!Character.isWhitespace(c)) {
-               return false;    
+               return false;
            }
         }
         return true;

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/JsfDefaultBuilder.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/JsfDefaultBuilder.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/JsfDefaultBuilder.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/JsfDefaultBuilder.java Mon Nov  6 14:44:56 2006
@@ -388,6 +388,7 @@
                     addConverter(child, target);
                     deleteList.add(child);
                 } else if (child.getName().startsWith("validate")
+                        || child.getName().startsWith("validator")
                         || child.getName().startsWith("commonsValidator")) {
                     addValidator(child, target);
                     deleteList.add(child);

Modified: shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/OutputLinkBuilder.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/OutputLinkBuilder.java?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/OutputLinkBuilder.java (original)
+++ shale/framework/trunk/shale-clay/src/main/java/org/apache/shale/clay/parser/builder/OutputLinkBuilder.java Mon Nov  6 14:44:56 2006
@@ -25,7 +25,6 @@
 import org.apache.shale.clay.config.beans.ElementBean;
 import org.apache.shale.clay.config.beans.SymbolBean;
 import org.apache.shale.clay.parser.Node;
-import org.apache.shale.clay.parser.builder.chain.AnchorBuilderRule;
 
 /**
  * <p>
@@ -87,7 +86,7 @@
      */
     protected void encodeBegin(Node node, ElementBean target, ComponentBean root) {
         super.encodeBegin(node, target, root);
-        
+
         AttributeBean attr = target.getAttribute("value");
         SymbolBean symbol = target.getSymbol("href");
         if ((symbol != null && attr != null)

Modified: shale/framework/trunk/shale-clay/src/main/resources/META-INF/clay-config.xml
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/resources/META-INF/clay-config.xml?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/resources/META-INF/clay-config.xml (original)
+++ shale/framework/trunk/shale-clay/src/main/resources/META-INF/clay-config.xml Mon Nov  6 14:44:56 2006
@@ -27,21 +27,33 @@
 
   <component jsfid="converter" componentType="override">
      <description>Abstract component definition.</description>
+     <attributes>
+         <set name="binding" bindingType="VB" />
+     </attributes>
   </component>
   <component jsfid="f:converter" extends="converter"/>
   
   <component jsfid="validator" componentType="override">
      <description>Abstract component definition.</description>
+     <attributes>
+         <set name="binding" bindingType="VB" />
+     </attributes>
   </component>
   <component jsfid="f:validator" extends="validator"/>
   
   <component jsfid="actionListener" componentType="override">
      <description>Abstract component definition.</description>
+     <attributes>
+         <set name="binding" bindingType="VB" />
+     </attributes>  
   </component>
   <component jsfid="f:actionListener" extends="actionListener"/>
   
   <component jsfid="valueChangeListener" componentType="override">
      <description>Abstract component definition.</description>
+     <attributes>
+         <set name="binding" bindingType="VB" />
+     </attributes>
   </component>
   <component jsfid="f:valueChangeListener" extends="valueChangeListener"/>
 
@@ -247,7 +259,7 @@
   </component>
   <component jsfid="s:token" extends="token"/> 
 
-  <component jsfid="commonsValidator" componentType="org.apache.shale.CommonsValidator" allowBody="false">
+  <component jsfid="commonsValidator" componentType="org.apache.shale.CommonsValidator" allowBody="false" extends="validator">
       <description>This is a JSF validator that uses Commons Validator to perform 
          validation, either client-side or server-side.
       </description>
@@ -1078,61 +1090,61 @@
   </component>
   <component jsfid="clay:space" extends="space"/>
 
-  <component jsfid="bigDecimalConverter" componentType="javax.faces.BigDecimal">
+  <component jsfid="bigDecimalConverter" componentType="javax.faces.BigDecimal" extends="converter">
      <description>Converts a String value into a java.util.BigDecimal type and back to a String.</description>
   </component>
   <component jsfid="convertBigDecimal" extends="bigDecimalConverter"/>
   <component jsfid="f:convertBigDecimal" extends="convertBigDecimal"/>
 
-  <component jsfid="bigIntegerConverter" componentType="javax.faces.BigInteger">
+  <component jsfid="bigIntegerConverter" componentType="javax.faces.BigInteger" extends="converter">
      <description>Converts a String value into a java.util.BigInteger type and back to a String.</description>
   </component>
   <component jsfid="convertBigInteger" extends="bigIntegerConverter"/>
   <component jsfid="f:convertBigInteger" extends="convertBigInteger"/>
 
-  <component jsfid="booleanConverter" componentType="javax.faces.Boolean">
+  <component jsfid="booleanConverter" componentType="javax.faces.Boolean" extends="converter">
      <description>Converts a String value into a java.lang.Boolean type and back to a String.</description>
   </component>
   <component jsfid="convertBoolean" extends="booleanConverter"/>
   <component jsfid="f:convertBoolean" extends="convertBoolean"/>
   
-  <component jsfid="byteConverter" componentType="javax.faces.Byte">
+  <component jsfid="byteConverter" componentType="javax.faces.Byte" extends="converter">
      <description>Converts a String value into a java.lang.Byte type and back to a String.</description>
   </component>
   <component jsfid="convertByte" extends="byteConverter"/>
   <component jsfid="f:convertByte" extends="convertByte"/>
 
-  <component jsfid="characterConverter" componentType="javax.faces.Character">
+  <component jsfid="characterConverter" componentType="javax.faces.Character" extends="converter">
      <description>Converts a String value into a java.lang.Character type and back to a String.</description>
   </component>
   <component jsfid="convertCharacter" extends="characterConverter"/>
   <component jsfid="f:convertCharacter" extends="convertCharacter"/>
   
-  <component jsfid="doubleConverter" componentType="javax.faces.Double">
+  <component jsfid="doubleConverter" componentType="javax.faces.Double" extends="converter">
      <description>Converts a String value into a java.lang.Double type and back to a String.</description>
   </component>
   <component jsfid="convertDouble" extends="doubleConverter"/>
   <component jsfid="f:convertDouble" extends="convertDouble"/>
 
-  <component jsfid="floatConverter" componentType="javax.faces.Float">
+  <component jsfid="floatConverter" componentType="javax.faces.Float" extends="converter">
     <description>Converts a String value into a java.lang.Float type and back to a String.</description>
   </component>
   <component jsfid="convertFloat" extends="floatConverter"/>
   <component jsfid="f:convertFloat" extends="convertFloat"/>
   
-  <component jsfid="integerConverter" componentType="javax.faces.Integer">
+  <component jsfid="integerConverter" componentType="javax.faces.Integer" extends="converter">
      <description>Converts a string value into an java.lang.Integer type and back to a string.</description>
   </component> 
   <component jsfid="convertInteger" extends="integerConverter"/>
   <component jsfid="f:convertInteger" extends="convertInteger"/>
 
-  <component jsfid="longConverter" componentType="javax.faces.Long">
+  <component jsfid="longConverter" componentType="javax.faces.Long" extends="converter">
     <description>Converts a String value into a java.lang.Long type and back to a String.</description>
   </component>
   <component jsfid="convertLong" extends="longConverter"/>
   <component jsfid="f:convertLong" extends="convertLong"/>
 
-  <component jsfid="numberConverter" componentType="javax.faces.Number">
+  <component jsfid="numberConverter" componentType="javax.faces.Number" extends="converter">
     <description>Converts a String into a number and back to a String.</description>
     <attributes>
        <set name="currencyCode" bindingType="Early">
@@ -1172,13 +1184,13 @@
   <component jsfid="convertNumber" extends="numberConverter"/>
   <component jsfid="f:convertNumber" extends="convertNumber"/>
 
-  <component jsfid="shortConverter" componentType="javax.faces.Short">
+  <component jsfid="shortConverter" componentType="javax.faces.Short" extends="converter">
     <description>Converts a String value into a java.lang.Short type and back to a String.</description>
   </component>
   <component jsfid="convertShort" extends="shortConverter"/>
   <component jsfid="f:convertShort" extends="convertShort"/>
 
-  <component jsfid="dateTimeConverter" componentType="javax.faces.DateTime" >
+  <component jsfid="dateTimeConverter" componentType="javax.faces.DateTime" extends="converter">
     <description>Converts a string value into a java.util.Date type and back to a string.</description>
     <attributes>
       <set name="dateStyle" bindingType="Early">
@@ -1339,7 +1351,7 @@
   </component>	
   <component jsfid="clay:clayForEach" extends="clayForEach"/>
 
-  <component jsfid="doubleRangeValidator" componentType="javax.faces.DoubleRange"> 
+  <component jsfid="doubleRangeValidator" componentType="javax.faces.DoubleRange" extends="validator"> 
      <description>Verifies the submitted value is a double within the specified minimum and maximum values.</description>
      <attributes>
        <set name="maximum" bindingType="Early">
@@ -1353,7 +1365,7 @@
   <component jsfid="validateDoubleRange" extends="doubleRangeValidator"/>
   <component jsfid="f:validateDoubleRange" extends="validateDoubleRange"/>
 
-  <component jsfid="lengthValidator" componentType="javax.faces.Length">
+  <component jsfid="lengthValidator" componentType="javax.faces.Length" extends="validator">
      <description>Verifies the submitted string value is greater than and not less than the specified minimum and maximum values.</description>
      <attributes>
        <set name="maximum" bindingType="Early">
@@ -1367,7 +1379,7 @@
   <component jsfid="validateLength" extends="lengthValidator"/>
   <component jsfid="f:validateLength" extends="validateLength"/>
 
-  <component jsfid="longRangeValidator" componentType="javax.faces.LongRange">
+  <component jsfid="longRangeValidator" componentType="javax.faces.LongRange" extends="validator">
      <description>Verifies the submitted value is a long within the specified minimum and maximum values.</description>
      <attributes>
        <set name="maximum" bindingType="Early">

Modified: shale/framework/trunk/shale-clay/src/main/resources/org/apache/shale/clay/component/chain/shale-clay-config.xml
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/main/resources/org/apache/shale/clay/component/chain/shale-clay-config.xml?view=diff&rev=471910&r1=471909&r2=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/main/resources/org/apache/shale/clay/component/chain/shale-clay-config.xml (original)
+++ shale/framework/trunk/shale-clay/src/main/resources/org/apache/shale/clay/component/chain/shale-clay-config.xml Mon Nov  6 14:44:56 2006
@@ -49,10 +49,10 @@
   <chain           name="createComponent">
 
     <command  className="org.apache.shale.clay.component.chain.CreateComponentCommand"/>
+    <command  className="org.apache.shale.clay.component.chain.AssignPropertiesCommand"/> 
     <command  className="org.apache.shale.clay.component.chain.AssignValidatorsCommand"/>
     <command  className="org.apache.shale.clay.component.chain.AssignValueChangeListenersCommand"/>
     <command  className="org.apache.shale.clay.component.chain.AssignActionListenersCommand"/>
-    <command  className="org.apache.shale.clay.component.chain.AssignPropertiesCommand"/> 
     <command  className="org.apache.shale.clay.component.chain.AssignConverterCommand"/>
 
   </chain>

Added: shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java?view=auto&rev=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java (added)
+++ shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java Mon Nov  6 14:44:56 2006
@@ -0,0 +1,215 @@
+/*
+ * 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.shale.clay.config;
+
+import java.io.StringWriter;
+import java.util.Iterator;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.html.HtmlCommandButton;
+import javax.faces.component.html.HtmlInputText;
+import javax.faces.context.ResponseWriter;
+import javax.faces.convert.Converter;
+import javax.faces.convert.IntegerConverter;
+import javax.faces.event.ActionEvent;
+import javax.faces.event.ActionListener;
+import javax.faces.event.ValueChangeEvent;
+import javax.faces.event.ValueChangeListener;
+import javax.faces.validator.LengthValidator;
+import javax.faces.validator.Validator;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.apache.shale.clay.component.Clay;
+
+public class BindingTestCase extends AbstractTestCaseConfig {
+
+    // Construct a new instance of this test case.
+    public BindingTestCase(String name) {
+        super(name);
+    }
+
+    // Return the tests included in this test case.
+    public static Test suite() {
+        return (new TestSuite(BindingTestCase.class));
+    }
+
+    private HtmlCommandButton command = null;
+    private HtmlInputText input = null;
+    private Converter converter = null;
+    private Validator validator = null;
+    private ActionListener actionListener = null;
+    private ValueChangeListener valueChangeListener = null;
+    
+    
+    
+    private Clay clay = null;
+    protected void setUp() throws Exception {
+        super.setUp();
+
+        // done by the startup context listener
+        loadConfigFiles(null, null);
+
+        clay = (Clay) application
+                .createComponent("org.apache.shale.clay.component.Clay");
+        clay.setId("test");
+        clay.setJsfid("/org/apache/shale/clay/config/binding.html");
+        clay.setManagedBeanName("test");
+        
+        facesContext.getExternalContext().getSessionMap().put("test", this);
+
+        // builds a buffer to write the page to
+        StringWriter writer = new StringWriter();
+        // create a buffered response writer
+        ResponseWriter buffResponsewriter = facesContext.getRenderKit()
+                .createResponseWriter(writer, null,
+                        response.getCharacterEncoding());
+        // push buffered writer to the faces context
+        facesContext.setResponseWriter(buffResponsewriter);
+        // start a document
+        buffResponsewriter.startDocument();
+
+        // build subtree
+        clay.encodeBegin(facesContext);
+    }
+
+    public void testInputBindings() {
+        HtmlInputText findInput = (HtmlInputText) findComponent(clay, "input");
+        assertNotNull(findInput);
+        assertTrue(getInput() == findInput);
+        
+        assertEquals(1, findInput.getValidators().length);
+        assertTrue(getValidator() == findInput.getValidators()[0]);
+
+        // test the property template override 
+        assertEquals(100, ((LengthValidator) getValidator()).getMaximum());
+        
+        assertNotNull(findInput.getConverter());
+        assertTrue(getConverter() == findInput.getConverter());
+        
+        assertEquals(1, findInput.getValueChangeListeners().length);
+        assertTrue(getValueChangeListener() == findInput.getValueChangeListeners()[0]);      
+    }
+    
+    public void testCommandBindings() {
+        HtmlCommandButton findCommand = (HtmlCommandButton) findComponent(clay, "command");
+        assertNotNull(findCommand);
+        
+        assertEquals(1, findCommand.getActionListeners().length);
+        assertTrue(getActionListener() == findCommand.getActionListeners()[0]);
+    }
+    
+    public ActionListener getActionListener() {
+        if (actionListener == null) {
+            actionListener = new ActionListener() {
+               public void processAction(ActionEvent event) {
+                   
+               };  
+            };
+        }
+        return actionListener;
+    }
+
+    public void setActionListener(ActionListener actionListener) {
+        this.actionListener = actionListener;
+    }
+
+    public HtmlCommandButton getCommand() {
+        if (command == null) {
+            command = new HtmlCommandButton();
+        }
+        return command;
+    }
+
+    public void setCommand(HtmlCommandButton command) {
+        this.command = command;
+    }
+
+    public Converter getConverter() {
+        if (converter == null) {
+            converter = new IntegerConverter();    
+        }
+        return converter;
+    }
+
+    public void setConverter(Converter converter) {
+        this.converter = converter;
+    }
+
+    public HtmlInputText getInput() {
+        if (input == null) {
+            input = new HtmlInputText();
+        }
+        return input;
+    }
+
+    public void setInput(HtmlInputText input) {
+        this.input = input;
+    }
+
+    public Validator getValidator() {
+        if (validator == null) {
+            validator = new LengthValidator(5, 1);    
+        }
+        return validator;
+    }
+
+    public void setValidator(Validator validator) {
+        this.validator = validator;
+    }
+
+    public ValueChangeListener getValueChangeListener() {
+        if (valueChangeListener == null) {
+            valueChangeListener = new ValueChangeListener() {
+                public void processValueChange(ValueChangeEvent event) {
+                    
+                };
+            };
+        }
+        return valueChangeListener;
+    }
+
+    public void setValueChangeListener(ValueChangeListener valueChangeListener) {
+        this.valueChangeListener = valueChangeListener;
+    }
+
+    
+    private UIComponent findComponent(UIComponent parent, String id) {
+        if (parent == null) {
+            return null;
+        }
+
+        if (parent.getId() != null && parent.getId().equals(id)) {
+            return parent;
+        } else {
+            Iterator ci = parent.getChildren().iterator();
+            while (ci.hasNext()) {
+                UIComponent child = (UIComponent) ci.next();
+                UIComponent target = findComponent(child, id);
+                if (target != null) {
+                    return target;
+                }
+            }
+        }
+
+        return null;
+    }
+
+
+}

Propchange: shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: shale/framework/trunk/shale-clay/src/test/java/org/apache/shale/clay/config/BindingTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Added: shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html
URL: http://svn.apache.org/viewvc/shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html?view=auto&rev=471910
==============================================================================
--- shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html (added)
+++ shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html Mon Nov  6 14:44:56 2006
@@ -0,0 +1,40 @@
+<!-- ### clay:page charset="UTF-8" /### -->
+<!-- ### clay:remove ### -->
+<!--
+ 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.
+-->
+<html>
+<head>
+  <title>Mock Logon Title</title>
+</head>
+<!-- ### /clay:remove ### -->
+<body jsfid="void" 
+         xmlns:f="http://java.sun.com/jsf/core" 
+         xmlns:h="http://java.sun.com/jsf/html">
+<form id="logonForm">
+    <h:inputText id="input" binding="#{@managed-bean-name.input}">
+        <f:converter binding="#{@managed-bean-name.converter}" />
+        <f:validateLength binding="#{@managed-bean-name.validator}" maximum="100"/>
+        <f:valueChangeListener binding="#{@managed-bean-name.valueChangeListener}"/>
+    </h:inputText>
+    <h:commandButton id="command" binding="#{@managed-bean-name.command}">
+       <f:actionListener binding="#{@managed-bean-name.actionListener}"/>
+    </h:commandButton>
+</form>
+</body>
+<!-- ### clay:remove ### -->
+</html>
+<!-- ### /clay:remove ### -->

Propchange: shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: shale/framework/trunk/shale-clay/src/test/resources/org/apache/shale/clay/config/binding.html
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL



Mime
View raw message