WcMethodMatcher.java 558 B

1234567891011121314151617181920212223242526
  1. package com.sf.aop.advisor;
  2. import org.springframework.aop.MethodMatcher;
  3. import java.lang.reflect.Method;
  4. public class WcMethodMatcher implements MethodMatcher {
  5. @Override
  6. public boolean matches(Method method, Class<?> targetClass) {
  7. if (method.getName().equals("wc")) {
  8. return true;
  9. }
  10. return false;
  11. }
  12. @Override
  13. public boolean isRuntime() {
  14. return false;
  15. }
  16. @Override
  17. public boolean matches(Method method, Class<?> targetClass, Object... args) {
  18. return false;
  19. }
  20. }