xdoclet.modules.apache.struts
Class StrutsFormTagsHandler

java.lang.Object
  extended by xdoclet.template.TemplateTagHandler
      extended by xdoclet.XDocletTagSupport
          extended by xdoclet.modules.ejb.EjbTagsHandler
              extended by xdoclet.modules.apache.struts.StrutsFormTagsHandler

public class StrutsFormTagsHandler
extends EjbTagsHandler

Version:
$Revision: 1.13 $
Author:
Dmitri Colebatch (dim@bigpond.net.au)
xdoclet.taghandler
namespace = "StrutsForm"
created
Oct 19, 2001

Field Summary
 
Fields inherited from class xdoclet.modules.ejb.EjbTagsHandler
ALL, LOCAL_SUFFIX, SERVICE_ENDPOINT, SERVICE_ENDPOINT_SUFFIX
 
Fields inherited from class xdoclet.XDocletTagSupport
FOR_CLASS, FOR_CONSTRUCTOR, FOR_FIELD, FOR_METHOD, PARAMETER_DELIMITER
 
Constructor Summary
StrutsFormTagsHandler()
           
 
Method Summary
 void forAllFormFields(java.lang.String template)
          Evaluates body for all fields included in form generation
static java.lang.String getStrutsFormClassFor(xjavadoc.XClass clazz)
          Gets the StrutsFormClassFor attribute of the StrutsFormTagsHandler class.
static java.lang.String getStrutsFormClassName(xjavadoc.XClass clazz)
          Gets the StrutsFormClassName attribute of the StrutsFormTagsHandler class
protected static java.lang.String getStrutsFormClassPattern()
          Gets the StrutsFormClassPattern attribute of the StrutsFormTagsHandler class
static boolean hasFormDefinition(xjavadoc.XClass clazz)
          Return true if at least one struts:form tag is defined.
 void ifUseMethodInForm(java.lang.String template)
          Evaluates the body if the method belongs in a given form.
 java.lang.String strutsFormClass()
          Return the class name for the current class.
 java.lang.String strutsFormName()
           
protected  boolean useMethodInForm(xjavadoc.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.modules.ejb.EjbTagsHandler
beanType, choosePackage, concreteFullClassName, ejbExternalRefName, ejbName, ejbRefName, ejbRefName, extendsFromFor, forAllBeans, getDependentClassFor, getDependentClassTagName, getEjb, getEjbIdFor, getEjbNameFor, getEjbSpec, getShortEjbNameFor, hasTransaction, id, ifIsAConcreteEJBean, ifLocalEjb, ifNotLocalEjb, ifNotRemoteEjb, ifNotServiceEndpointEjb, ifRemoteEjb, ifServiceEndpointEjb, isAConcreteEJBean, isEjb, isLocalEjb, isOnlyLocalEjb, isOnlyRemoteEjb, isOnlyServiceEndpointEjb, isRemoteEjb, isServiceEndpointEjb, prefixWithEjbSlash, shortEjbName, shouldTraverseSuperclassForDependentClass, symbolicClassName
 
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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StrutsFormTagsHandler

public StrutsFormTagsHandler()
Method Detail

getStrutsFormClassFor

public static java.lang.String getStrutsFormClassFor(xjavadoc.XClass clazz)
                                              throws XDocletException
Gets the StrutsFormClassFor attribute of the StrutsFormTagsHandler class.

Parameters:
clazz - Describe what the parameter does
Returns:
The StrutsFormClassFor value
Throws:
XDocletException - Describe the exception

getStrutsFormClassName

public static java.lang.String getStrutsFormClassName(xjavadoc.XClass clazz)
                                               throws XDocletException
Gets the StrutsFormClassName attribute of the StrutsFormTagsHandler class

Parameters:
clazz - Describe what the parameter does
Returns:
The StrutsFormClassName value
Throws:
XDocletException - Describe the exception

hasFormDefinition

public static boolean hasFormDefinition(xjavadoc.XClass clazz)
                                 throws 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:
XDocletException - Description of Exception

getStrutsFormClassPattern

protected static java.lang.String getStrutsFormClassPattern()
Gets the StrutsFormClassPattern attribute of the StrutsFormTagsHandler class

Returns:
The StrutsFormClassPattern value

strutsFormClass

public java.lang.String strutsFormClass()
                                 throws XDocletException
Return the class name for the current class.

Returns:
Description of the Returned Value
Throws:
XDocletException - Description of Exception
doc.tag
type = "content"

strutsFormName

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

forAllFormFields

public void forAllFormFields(java.lang.String template)
                      throws XDocletException
Evaluates body for all fields included in form generation

Parameters:
template - The body of the block tag
Throws:
XDocletException - Description of Exception
doc.tag
type = "block"

ifUseMethodInForm

public void ifUseMethodInForm(java.lang.String template)
                       throws XDocletException
Evaluates the body if the method belongs in a given form.

Parameters:
template - The body of the block tag
Throws:
XDocletException
doc.tag
type = "block"

useMethodInForm

protected boolean useMethodInForm(xjavadoc.XMethod method)
                           throws 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:
XDocletException - Description of Exception

http://xdoclet.sourceforge.net/