xdoclet.modules.apache.struts

Class ActionFormTagsHandler


public class ActionFormTagsHandler
extends xdoclet.XDocletTagSupport

Version:
$Revision: 1.2 $
Author:
Matt Raible (matt@raibledesigns.com)
xdoclet.taghandler
namespace = "ActionForm"
created
April 26, 2004

Field Summary

Fields inherited from class xdoclet.XDocletTagSupport

FOR_CLASS, FOR_CONSTRUCTOR, FOR_FIELD, FOR_METHOD, PARAMETER_DELIMITER

Method Summary

String
actionFormClass()
Return the class name for the current class.
String
actionFormName()
void
forAllFormFields(String template)
Evaluates body for all fields included in form generation
static String
getActionFormClassFor(XClass clazz)
Gets the ActionFormClassFor attribute of the ActionFormTagsHandler class.
static String
getActionFormClassName(XClass clazz)
Gets the ActionFormClassName attribute of the ActionFormTagsHandler class
protected static String
getActionFormClassPattern()
Gets the ActionFormClassPattern attribute of the ActionFormTagsHandler class
static boolean
hasFormDefinition(XClass clazz)
Return true if at least one struts:form tag is defined.
void
ifUseMethodInForm(String template)
Evaluates the body if the method belongs in a given form.
protected boolean
useMethodInForm(XMethod method)
Check that method has struts:form-field tag with valid name, or is pk field (and pk fields are included) or include-all="true".

Methods inherited from class xdoclet.XDocletTagSupport

delimit, expandClassName, generate, getCurrentClass, getCurrentClassTag, getCurrentConstructor, getCurrentField, getCurrentFieldTag, getCurrentMethod, getCurrentMethodTag, getCurrentPackage, getDocletContext, getEngine, getExpandedDelimitedTagValue, getTagValue, getTagValue, getTagValue, hasHavingClassTag, hasTag, isTagValueEqual, mandatoryParamNotFound, mandatoryTemplateTagParamNotFound, modifiers, popCurrentClass, pushCurrentClass, setCurrentClass, setCurrentClassTag, setCurrentConstructor, setCurrentField, setCurrentFieldTag, setCurrentMethod, setCurrentMethodTag, setCurrentPackage

Methods inherited from class xdoclet.template.TemplateTagHandler

getXJavaDoc, setXJavaDoc

Method Details

actionFormClass

public String actionFormClass()
            throws xdoclet.XDocletException
Return the class name for the current class.
Returns:
Description of the Returned Value
Throws:
xdoclet.XDocletException - Description of Exception
doc.tag
type = "content"

actionFormName

public String actionFormName()
            throws xdoclet.XDocletException
Returns:
Description of the Returned Value
Throws:
xdoclet.XDocletException - Description of Exception
doc.tag
type = "content"

forAllFormFields

public void forAllFormFields(String template)
            throws xdoclet.XDocletException
Evaluates body for all fields included in form generation
Parameters:
template - The body of the block tag
Throws:
xdoclet.XDocletException - Description of Exception
doc.tag
type = "block"

getActionFormClassFor

public static String getActionFormClassFor(XClass clazz)
            throws xdoclet.XDocletException
Gets the ActionFormClassFor attribute of the ActionFormTagsHandler class.
Parameters:
clazz - Describe what the parameter does
Returns:
The ActionFormClassFor value
Throws:
xdoclet.XDocletException - Describe the exception

getActionFormClassName

public static String getActionFormClassName(XClass clazz)
            throws xdoclet.XDocletException
Gets the ActionFormClassName attribute of the ActionFormTagsHandler class
Parameters:
clazz - Describe what the parameter does
Returns:
The ActionFormClassName value
Throws:
xdoclet.XDocletException - Describe the exception

getActionFormClassPattern

protected static String getActionFormClassPattern()
Gets the ActionFormClassPattern attribute of the ActionFormTagsHandler class
Returns:
The ActionFormClassPattern value

hasFormDefinition

public static boolean hasFormDefinition(XClass clazz)
            throws xdoclet.XDocletException
Return true if at least one struts:form tag is defined.
Parameters:
clazz - Class to check
Returns:
whether class has struts:form tag defined
Throws:
xdoclet.XDocletException - Description of Exception

ifUseMethodInForm

public void ifUseMethodInForm(String template)
            throws xdoclet.XDocletException
Evaluates the body if the method belongs in a given form.
Parameters:
template - The body of the block tag
Throws:
xdoclet.XDocletException -
doc.tag
type = "block"

useMethodInForm

protected boolean useMethodInForm(XMethod method)
            throws xdoclet.XDocletException
Check that method has struts:form-field tag with valid name, or is pk field (and pk fields are included) or include-all="true".
Parameters:
method - Description of Parameter
Returns:
Description of the Returned Value
Throws:
xdoclet.XDocletException - Description of Exception