View Javadoc
1   package com.atlassian.plugin.spring.scanner.runtime.impl;
2   
3   import org.hamcrest.BaseMatcher;
4   import org.hamcrest.Description;
5   import org.hamcrest.Matcher;
6   import org.springframework.aop.support.AopUtils;
7   
8   class IsAopProxy extends BaseMatcher<Object> {
9       @Override
10      public void describeTo(Description description) {
11          description.appendText("is AOP proxy");
12      }
13  
14      @Override
15      public boolean matches(Object item) {
16          return AopUtils.isAopProxy(item);
17      }
18  
19      public static Matcher<Object> aopProxy() {
20          return new IsAopProxy();
21      }
22  }