org.springframework.aop.support

## 类 MethodMatchers

- java.lang.Object
- - org.springframework.aop.support.MethodMatchers

-     public abstract class MethodMatchers
      extends Object

  Static utility methods for composing `MethodMatchers`.

  A MethodMatcher may be evaluated statically (based on method and target class) or need further evaluation dynamically (based on arguments at the time of method invocation).

  从以下版本开始:
    11.11.2003
  作者:
    Rod Johnson, Rob Harrop, Juergen Hoeller
  另请参阅:
    `ClassFilters`, `Pointcuts`

- - ### 构造器概要

    构造器
    构造器和说明
    `MethodMatchers()`

  - ### 方法概要

    所有方法 静态方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `static MethodMatcher` | `intersection(MethodMatcher mm1, MethodMatcher mm2)` Match all methods that both of the given MethodMatchers match.
    `static boolean` | `matches(MethodMatcher mm, Method method, Class<?> targetClass, boolean hasIntroductions)` Apply the given MethodMatcher to the given Method, supporting an `IntroductionAwareMethodMatcher` (if applicable).
    `static MethodMatcher` | `union(MethodMatcher mm1, MethodMatcher mm2)` Match all methods that either (or both) of the given MethodMatchers matches.

    - ### 从类继承的方法 java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### 构造器详细资料

    - #### MethodMatchers

          public MethodMatchers()

  - ### 方法详细资料

    - #### union

          public static MethodMatcher union(MethodMatcher mm1,
                                            MethodMatcher mm2)

      Match all methods that either (or both) of the given MethodMatchers matches.
      参数:
        `mm1` - the first MethodMatcher
        `mm2` - the second MethodMatcher
      返回:
        a distinct MethodMatcher that matches all methods that either of the given MethodMatchers matches

    - #### intersection

          public static MethodMatcher intersection(MethodMatcher mm1,
                                                   MethodMatcher mm2)

      Match all methods that both of the given MethodMatchers match.
      参数:
        `mm1` - the first MethodMatcher
        `mm2` - the second MethodMatcher
      返回:
        a distinct MethodMatcher that matches all methods that both of the given MethodMatchers match

    - #### matches

          public static boolean matches(MethodMatcher mm,
                                        Method method,
                                        @Nullable
                                        Class<?> targetClass,
                                        boolean hasIntroductions)

      Apply the given MethodMatcher to the given Method, supporting an `IntroductionAwareMethodMatcher` (if applicable).
      参数:
        `mm` - the MethodMatcher to apply (may be an IntroductionAwareMethodMatcher)
        `method` - the candidate method
        `targetClass` - the target class (may be `null`, in which case the candidate class must be taken to be the method's declaring class)
        `hasIntroductions` - `true` if the object on whose behalf we are asking is the subject on one or more introductions; `false` otherwise
      返回:
        whether or not this method matches statically