Title: [waffle-scm] [547] trunk/waffle-core/src/main/java/org/codehaus/waffle/action: javadoc: *MethodDefinitionFinders

Diff

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AbstractMethodDefinitionFinder.java (546 => 547)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AbstractMethodDefinitionFinder.java	2008-01-11 15:20:10 UTC (rev 546)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AbstractMethodDefinitionFinder.java	2008-01-12 02:11:07 UTC (rev 547)
@@ -63,7 +63,10 @@
         this.methodNameResolver = methodNameResolver;
         this.actionMonitor = actionMonitor;
     }
-
+    
+    /**
+     * [EMAIL PROTECTED]
+     */
     public MethodDefinition find(Object controller,
                                  HttpServletRequest request,
                                  HttpServletResponse response) throws WaffleException {
@@ -176,8 +179,10 @@
         return methodDefinition;
     }
 
-    private MethodDefinition findPragmaticMethodDefinition(HttpServletRequest request, HttpServletResponse response,
-                                                           List<Method> methods, List<Object> arguments) {
+    private MethodDefinition findPragmaticMethodDefinition(HttpServletRequest request,
+                                                           HttpServletResponse response,
+                                                           List<Method> methods,
+                                                           List<Object> arguments) {
         List<MethodDefinition> methodDefinitions = new ArrayList<MethodDefinition>();
 
         for (Method method : methods) {
@@ -308,11 +313,11 @@
     // Abstract methods - implementable by subclasses 
 
     /**
-     * Returns the method arguments contained in the request
+     * Returns the resolved list of method arguments.
      *
-     * @param method  the Method
+     * @param method  the action method to be invoked
      * @param request the HttpServetRequest
-     * @return the list of arguments
+     * @return the resolved list of arguments needed to satisfy the action method invocation
      */
     protected abstract List<Object> getArguments(Method method, HttpServletRequest request);
 

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AbstractOgnlMethodDefinitionFinder.java (546 => 547)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AbstractOgnlMethodDefinitionFinder.java	2008-01-11 15:20:10 UTC (rev 546)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AbstractOgnlMethodDefinitionFinder.java	2008-01-12 02:11:07 UTC (rev 547)
@@ -33,6 +33,14 @@
         super(servletContext, argumentResolver, methodNameResolver, stringTransmuter, actionMonitor);
     }
 
+    /**
+     * Inspects the class (aka Type) and finds all methods with that name.  
+     *
+     * @param type       the Class in which to look for the method
+     * @param methodName the method name
+     * @return A List of methods
+     * @throws NoMatchingActionMethodException if no methods match
+     */
     @SuppressWarnings({"unchecked"})
     protected List<Method> findMethods(Class<?> type, String methodName) {
         List<Method> methods = getMethods(type, methodName, false);

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/ActionMethodException.java (546 => 547)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/ActionMethodException.java	2008-01-11 15:20:10 UTC (rev 546)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/ActionMethodException.java	2008-01-12 02:11:07 UTC (rev 547)
@@ -13,8 +13,8 @@
 import org.codehaus.waffle.WaffleException;
 
 /**
- * This is a specialized exception that will be thrown directly from an ActionMethod.  Exceptions of this type
- * will set the response statusCode code and response body.
+ * <p>This is a specialized exception that will be thrown directly from an ActionMethod.  Exceptions of this type
+ * will set the response statusCode code and response body.</p>
  */
 @SuppressWarnings("serial")
 public class ActionMethodException extends WaffleException {
@@ -32,6 +32,9 @@
         this.message = message;
     }
 
+    /**
+     * Returns the the [EMAIL PROTECTED] javax.servlet.http.HttpServletResponse} status should be set to.
+     */
     public int getStatusCode() {
         return statusCode;
     }

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AnnotatedMethodDefinitionFinder.java (546 => 547)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AnnotatedMethodDefinitionFinder.java	2008-01-11 15:20:10 UTC (rev 546)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/AnnotatedMethodDefinitionFinder.java	2008-01-12 02:11:07 UTC (rev 547)
@@ -22,10 +22,10 @@
 import java.util.List;
 
 /**
- * Annotation-based method definition finder.
- * This is the default default definition finder used by Waffle.
- * <p/>
- * <b>Note</b>: Pragmatic method calls will always take precedence.
+ * <p>Annotation-based method definition finder. This is the default default definition finder used by Waffle.
+ * <br/><br/>
+ * <b>Note</b>: Pragmatic method calls always take precedence over other types.
+ * </p>
  * 
  * @author Michael Ward
  */
@@ -39,6 +39,14 @@
         super(servletContext, argumentResolver, methodNameResolver, stringTransmuter, actionMonitor);
     }
 
+    /**
+     * Inspects the method's [EMAIL PROTECTED] ActionMethod} annotation to determine the parameter names to use to resolve the
+     * argument values.
+     *
+     * @param method the action method to be invoked
+     * @param request the HttpServetRequest
+     * @return the resolved list of arguments needed to satisfy the action method invocation
+     */
     protected List<Object> getArguments(Method method, HttpServletRequest request) {
         if (method.isAnnotationPresent(ActionMethod.class)) {
             ActionMethod actionMethod = method.getAnnotation(ActionMethod.class);

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/ParanamerMethodDefinitionFinder.java (546 => 547)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/ParanamerMethodDefinitionFinder.java	2008-01-11 15:20:10 UTC (rev 546)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/ParanamerMethodDefinitionFinder.java	2008-01-12 02:11:07 UTC (rev 547)
@@ -25,9 +25,9 @@
 import java.util.List;
 
 /**
- * Pananamer-based method definition finder, which can be used in alternative to
- * other definition finders, eg [EMAIL PROTECTED] AnnotatedMethodDefinitionFinder}.
- * <p/>
+ * <p>Pananamer-based method definition finder, which can be used in alternative to
+ * other definition finders, eg [EMAIL PROTECTED] AnnotatedMethodDefinitionFinder}.<p>
+ * <br/><br/>
  * <b>Note</b>: Pragmatic method calls will always take precedence.
  * 
  * @author Paul Hammant 
@@ -44,6 +44,14 @@
         super(servletContext, argumentResolver, methodNameResolver, stringTransmuter, actionMonitor);
     }
 
+    /**
+     * Uses [EMAIL PROTECTED] Paranamer} to determine the parameter names to use to resolve the
+     * argument values.
+     *
+     * @param method the action method to be invoked
+     * @param request the HttpServetRequest
+     * @return the resolved list of arguments needed to satisfy the action method invocation
+     */
     protected List<Object> getArguments(Method method, HttpServletRequest request) {
         Class<?>[] parameterTypes = method.getParameterTypes();
         String[] parameterNames = null;


To unsubscribe from this list please visit:

http://xircles.codehaus.org/manage_email

Reply via email to