Title: [waffle-scm] [478] trunk/waffle-core/src/main/java/org/codehaus/waffle/action/intercept: Removed remaining uses of @DefaultActionMethod.
Revision
478
Author
mauro
Date
2007-12-14 12:48:41 -0600 (Fri, 14 Dec 2007)

Log Message

Removed remaining uses of @DefaultActionMethod.  Made clear in deprecation message that annotation will be ignored.

Modified Paths

Diff

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/annotation/DefaultActionMethod.java (477 => 478)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/annotation/DefaultActionMethod.java	2007-12-14 18:31:18 UTC (rev 477)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/annotation/DefaultActionMethod.java	2007-12-14 18:48:41 UTC (rev 478)
@@ -16,7 +16,7 @@
 import java.lang.annotation.RetentionPolicy;
 
 /**
- * @deprecated Use @ActionMethod(asDefault=true)
+ * @deprecated Use @ActionMethod(asDefault=true).  @DefaultActionMethod is not supported anymore and will be ignored.
  */
 @Target(ElementType.METHOD)
 @Retention(RetentionPolicy.RUNTIME)

Modified: trunk/waffle-core/src/main/java/org/codehaus/waffle/action/intercept/SecurityMethodInterceptor.java (477 => 478)

--- trunk/waffle-core/src/main/java/org/codehaus/waffle/action/intercept/SecurityMethodInterceptor.java	2007-12-14 18:31:18 UTC (rev 477)
+++ trunk/waffle-core/src/main/java/org/codehaus/waffle/action/intercept/SecurityMethodInterceptor.java	2007-12-14 18:48:41 UTC (rev 478)
@@ -10,14 +10,13 @@
  *****************************************************************************/
 package org.codehaus.waffle.action.intercept;
 
-import org.codehaus.waffle.controller.ControllerDefinition;
-import org.codehaus.waffle.action.ActionMethodInvocationException;
-import org.codehaus.waffle.action.annotation.ActionMethod;
-import org.codehaus.waffle.action.annotation.DefaultActionMethod;
-
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
 
+import org.codehaus.waffle.action.ActionMethodInvocationException;
+import org.codehaus.waffle.action.annotation.ActionMethod;
+import org.codehaus.waffle.controller.ControllerDefinition;
+
 /**
  * This interceptor ensure that only annotated methods are invokable as <i>Actions</i>.  
  * Usage of this will help protect your application against malicious attacks.
@@ -32,10 +31,8 @@
                             Method method,
                             InterceptorChain chain,
                             Object... arguments) throws IllegalAccessException, InvocationTargetException {
-        if (method.isAnnotationPresent(DefaultActionMethod.class)) {
+        if (method.isAnnotationPresent(ActionMethod.class)) {
             return chain.proceed(controllerDefinition, method, arguments);
-        } else if (method.isAnnotationPresent(ActionMethod.class)) {
-            return chain.proceed(controllerDefinition, method, arguments);
         }
 
         // Only notify that the requested action could not invoked do NOT give any detailed information (Security Risk)


To unsubscribe from this list please visit:

http://xircles.codehaus.org/manage_email

Reply via email to