Update of 
/cvsroot/xdoclet-plugins/xdoclet-plugins/plugin-tapestry/src/main/java/org/xdoclet/plugin/tapestry/qtags
In directory 
sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1611/xdoclet-plugins/plugin-tapestry/src/main/java/org/xdoclet/plugin/tapestry/qtags

Modified Files:
        TapestryForeachTag.java 
Added Files:
        TapestryForTag.java 
Log Message:
Added @tapestry.for tag

--- NEW FILE: TapestryForTag.java ---
/*
 * Copyright (c) 2003-2005
 * XDoclet Team
 * All rights reserved.
 */
package org.xdoclet.plugin.tapestry.qtags;

/**
 * Loops over a collection of source values.  
 * May also emulate an element (like an Any component). 
 * If this component is placed in a Form, it will automatically store
 * the collection in Hidden fields so that the structure of the page is 
preserved
 * during a rewind even if the values in the source change.
 *
 * @qtags.location class
 * @author Paolo Dona
 */
public interface TapestryForTag extends com.thoughtworks.qdox.model.DocletTag {
    /**
     * The id of the component
     * @qtags.required
     */
    String getId();
    
    /**
     * The source of values, a Java collection or array.
     * @qtags.required
     */
    String getSource();
    
    /**
     * If provided, the parameter is updated with the current value on each 
iteration.
     */
    String getValue_();
    
    /**
     * If provided, the parameter is updated with the index of the loop on each 
iteration.
     */
    String getIndex();
    
    /**
     * If provided, the component wraps its content with the requested element.
     * Informal parameters become attributes of that element.
     */
    String getElement();
    
    /**
     * Only active in a form. 
     * An OGNL expression that returns the primary key of the iterated value. 
     * The primary keys are stored in hidden fields during rendering and 
     * are loaded from the form during a rewind to ensure that the iterations 
     * remain the same. This is a simpler, but a less efficient alternative 
     * of the 'converter' parameter. 
     * If needed, please use in conjuction with 'fullSource' to reference 
objects 
     * not currently present in 'source'.
     * Also, use the 'defaultValue' parameter to define the object to be 
returned 
     * if a value corresponding to a particular primary key cannot be found.
     */
    String getKeyExpression();
    
    /**
     * Only active in a form and in combination with the 'keyExpression' 
parameter. 
     * If an object corresponding to a primary key stored in the form cannot be
     * found in the 'source' parameter, then the objects provided by this 
parameter 
     * are searched for a match next. 
     */
    String getFullSource();
    
    /**
     * Only active in a form. 
     * The value to be used when no match for a given primary key is found. 
     */
    String getDefaultValue();
    
    /**
     * Only active in a form. 
     * Defines how the items iterated upon will be stored in the form as 
     * hidden values and how the stored information will be converted back to 
objects. 
     * This interface allows only the primary key of the items to be stored, 
     * rather than the whole item.
     */
    String getConverter();
    
    /**
     * Only active in a form. 
     * If provided, the parameter is automatically updated 
     * before a rewind with the list of primary keys stored in the form. 
     * The parameter is updated right before the iterations begin in a rewind 
and 
     * could be used to preload the relevant objects in the provided 
'converter'.
     */
    String getPrimaryKeys();
    
    /**
     * Only active in a form. This parameter allows the matching of the string
     * representation of the values stored in the hidden fields with that 
     * of the values in 'source'. It guarantees that the values iterated upon 
are 
     * physically identical to the ones provided. 
     * The method is sometimes slower than simple unsqueezing, but it 
eliminates a number 
     * of potential pitfalls. Please disable with caution.
     */
    String getMatch();
    
    /**
     * Only active in a form. 
     * Determines whether to avoid creating hidden fields within a form.
     * Using this parameter may make the form structure different during render 
and rewind, 
     * and cause exceptions as a result. 
     * Please use with caution.
     */
    String getVolatile();
}
Index: TapestryForeachTag.java
===================================================================
RCS file: 
/cvsroot/xdoclet-plugins/xdoclet-plugins/plugin-tapestry/src/main/java/org/xdoclet/plugin/tapestry/qtags/TapestryForeachTag.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** TapestryForeachTag.java     18 Oct 2005 08:18:42 -0000      1.2
--- TapestryForeachTag.java     19 Oct 2005 08:08:40 -0000      1.3
***************
*** 9,12 ****
--- 9,13 ----
   * Loops over a collection of source values.
   * May also emulate an element (like an Any component).
+  * It's deprecated please use the <b>tapestry.for<b/> tag.
   *
   * @qtags.location class



-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
xdoclet-plugins-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xdoclet-plugins-commits

Reply via email to