User: pathoss
Date: 02/05/15 12:10:39
Modified: modules/apache/src/xdoclet/modules/apache/struts Tag:
MODULE_REFACTORING_BRANCH
StrutsFormTagsHandler.java
Log:
Cleanup.
Revision Changes Path
No revision
No revision
1.1.2.6 +8 -21
xdoclet/modules/apache/src/xdoclet/modules/apache/struts/Attic/StrutsFormTagsHandler.java
Index: StrutsFormTagsHandler.java
===================================================================
RCS file:
/cvsroot/xdoclet/xdoclet/modules/apache/src/xdoclet/modules/apache/struts/Attic/StrutsFormTagsHandler.java,v
retrieving revision 1.1.2.5
retrieving revision 1.1.2.6
diff -u -w -r1.1.2.5 -r1.1.2.6
--- StrutsFormTagsHandler.java 12 May 2002 15:21:14 -0000 1.1.2.5
+++ StrutsFormTagsHandler.java 15 May 2002 19:10:39 -0000 1.1.2.6
@@ -29,15 +29,13 @@
import xdoclet.modules.ejb.entity.PersistentTagsHandler;
/**
- *
* @xdoclet:taghandler namespace="StrutsForm"
*
* @author Dmitri Colebatch ([EMAIL PROTECTED])
* @created Oct 19, 2001
- * @version $Revision: 1.1.2.5 $
+ * @version $Revision: 1.1.2.6 $
*/
public class StrutsFormTagsHandler extends EjbTagsHandler {
-
/**
* Return the class name for the current class.
*
@@ -48,7 +46,6 @@
return getStrutsFormClassFor(getCurrentClass());
}
-
/**
* @return Description of the Returned Value
* @exception XDocletException Description of Exception
@@ -65,7 +62,6 @@
}
}
-
/**
* Evaluates body for all fields included in form generation
*
@@ -73,14 +69,13 @@
* @exception XDocletException Description of Exception
* @doc:tag type="block"
*/
-
public void forAllFormFields(String template) throws XDocletException {
// all fields carrying @struts:form-field form-name="<bla>" where
<bla> is current
// form name, or all persistent fields if include-all="true" is set
// pk fields are included implicitly, unless include-pk="false" is
specified.
Log log = LogUtil.getLog(StrutsFormTagsHandler.class,
"forAllFormFields");
- XClass cur_class = getCurrentClass();
+ XClass currentClass = getCurrentClass();
Map foundFields = new HashMap();
if (log.isDebugEnabled()) {
@@ -88,7 +83,7 @@
}
do {
- pushCurrentClass(cur_class);
+ pushCurrentClass(currentClass);
if (log.isDebugEnabled()) {
log.debug("-----CLASS=" + getCurrentClass().name() +
"----------------");
@@ -100,19 +95,16 @@
setCurrentMethod(methods[j]);
// we are interested in persistent methods only
if
(MethodTagsHandler.isGetter(getCurrentMethod().name()) &&
!foundFields.containsKey(getCurrentMethod().name())) {
- //
if (useMethodInForm(getCurrentMethod())) {
if (log.isDebugEnabled()) {
log.debug("METHOD(I=" +
getCurrentMethod().name());
}
-
// Store that we found this field so
we don't add it twice
foundFields.put(getCurrentMethod().name(), getCurrentMethod().name());
generate(template);
}
}
-
}
// Add super class info
@@ -122,7 +114,7 @@
}
popCurrentClass();
- cur_class = cur_class.superclass();
+ currentClass = currentClass.superclass();
} while (true);
if (log.isDebugEnabled()) {
@@ -130,10 +122,9 @@
}
}
-
/**
- * check that method has struts:form-field tag with valid name, or is pk field
- * (and pk fields are included) or include-all="true"
+ * Check that method has struts:form-field tag with valid name, or is pk field
+ * (and pk fields are included) or include-all="true".
*
* @param method Description of Parameter
* @return Description of the Returned Value
@@ -176,9 +167,8 @@
return false;
}
-
/**
- * Gets the StrutsFormClassFor attribute of the StrutsFormTagsHandler class
+ * Gets the StrutsFormClassFor attribute of the StrutsFormTagsHandler class.
*
* @param clazz Describe what the parameter does
* @return The StrutsFormClassFor value
@@ -193,7 +183,6 @@
return packageName + '.' + getStrutsFormClassName(clazz);
}
-
/**
* Gets the StrutsFormClassName attribute of the StrutsFormTagsHandler class
*
@@ -217,9 +206,8 @@
}
}
-
/**
- * return true if at least one struts:form tag is defined
+ * Return true if at least one struts:form tag is defined.
*
* @param clazz Class to check
* @return whether class has struts:form tag defined
@@ -228,7 +216,6 @@
public static boolean hasFormDefinition(XClass clazz) throws XDocletException {
return clazz.doc().hasTag("struts:form", false);
}
-
/**
* Gets the StrutsFormClassPattern attribute of the StrutsFormTagsHandler class
_______________________________________________________________
Have big pipes? SourceForge.net is looking for download mirrors. We supply
the hardware. You get the recognition. Email Us: [EMAIL PROTECTED]
_______________________________________________
Xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel