jodd.servlet.tags.form
Class FormTag

java.lang.Object
  extended byjavax.servlet.jsp.tagext.TagSupport
      extended byjavax.servlet.jsp.tagext.BodyTagSupport
          extended byjodd.servlet.tags.form.FormTag
All Implemented Interfaces:
javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag

public class FormTag
extends javax.servlet.jsp.tagext.BodyTagSupport

Form tag populates a included form with values from the one or more beans. Beans are stored in various scopes. This tag is smart so everything happens automatically. However, there are several easy-to-work-with limits that must be fulfilled to make this tag working properly:

*note: not all, just: name, value and type attributes, however, it is recommended to use the above style everywhere.

Availiable scopes are:

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
FormTag()
           
 
Method Summary
 int doAfterBody()
          Performs smart form population.
 int doEndTag()
          End of tag.
 int doStartTag()
          Copies properties of all specified bean into one map.
 java.lang.String getBeans()
          Gets bean names.
 java.lang.String getScopes()
          Return value of the "scope" attribute
 void setBeans(java.lang.String v)
          Sets bean names with value of the "bean" attribute.
 void setScopes(java.lang.String v)
          Sets the value of "scope" attribute, that represent beans scope.
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doInitBody, getBodyContent, getPreviousOut, release, setBodyContent
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext, setParent
 

Constructor Detail

FormTag

public FormTag()
Method Detail

setBeans

public void setBeans(java.lang.String v)
Sets bean names with value of the "bean" attribute.

Parameters:
v - bean names

getBeans

public java.lang.String getBeans()
Gets bean names.

Returns:
bean names

setScopes

public void setScopes(java.lang.String v)
Sets the value of "scope" attribute, that represent beans scope.

Parameters:
v -

getScopes

public java.lang.String getScopes()
Return value of the "scope" attribute

Returns:
bean scopes

doStartTag

public int doStartTag()
Copies properties of all specified bean into one map.

Returns:
EVAL_BODY_AGAIN

doAfterBody

public int doAfterBody()
Performs smart form population.

Returns:
SKIP_BODY

doEndTag

public int doEndTag()
End of tag.

Returns:
EVAL_PAGE


Jodd v0.24.5 Javadoc