Polish formatting

Minor formatting polish across that codebase. Primarily fixing
whitespace issues.
This commit is contained in:
Phillip Webb
2013-02-01 10:14:01 -08:00
parent 0a6da1e42d
commit f464a45ba4
114 changed files with 124 additions and 127 deletions

View File

@@ -282,8 +282,8 @@ public class AspectJExpressionPointcut extends AbstractExpressionPointcut
return false;
}
else {
// the maybe case
return (beanHasIntroductions || matchesIgnoringSubtypes(shadowMatch) || matchesTarget(shadowMatch, targetClass));
// the maybe case
return (beanHasIntroductions || matchesIgnoringSubtypes(shadowMatch) || matchesTarget(shadowMatch, targetClass));
}
}

View File

@@ -64,8 +64,8 @@ public abstract class AspectJProxyUtils {
*/
private static boolean isAspectJAdvice(Advisor advisor) {
return (advisor instanceof InstantiationModelAwarePointcutAdvisor ||
advisor.getAdvice() instanceof AbstractAspectJAdvice ||
(advisor instanceof PointcutAdvisor &&
advisor.getAdvice() instanceof AbstractAspectJAdvice ||
(advisor instanceof PointcutAdvisor &&
((PointcutAdvisor) advisor).getPointcut() instanceof AspectJExpressionPointcut));
}

View File

@@ -63,8 +63,8 @@ class InstantiationModelAwarePointcutAdvisorImpl
private Boolean isAfterAdvice;
public InstantiationModelAwarePointcutAdvisorImpl(AspectJAdvisorFactory af, AspectJExpressionPointcut ajexp,
MetadataAwareAspectInstanceFactory aif, Method method, int declarationOrderInAspect, String aspectName) {
public InstantiationModelAwarePointcutAdvisorImpl(AspectJAdvisorFactory af, AspectJExpressionPointcut ajexp,
MetadataAwareAspectInstanceFactory aif, Method method, int declarationOrderInAspect, String aspectName) {
this.declaredPointcut = ajexp;
this.method = method;

View File

@@ -152,11 +152,11 @@ public abstract class AbstractAutoProxyCreator extends ProxyConfig
* @param order ordering value
*/
public final void setOrder(int order) {
this.order = order;
this.order = order;
}
public final int getOrder() {
return this.order;
return this.order;
}
/**

View File

@@ -95,7 +95,7 @@ public class DelegatingIntroductionInterceptor extends IntroductionInfoSupport
/**
* Subclasses may need to override this if they want to perform custom
* Subclasses may need to override this if they want to perform custom
* behaviour in around advice. However, subclasses should invoke this
* method, which handles introduced interfaces and forwarding to the target.
*/

View File

@@ -139,7 +139,7 @@ public final class MethodInvocationProceedingJoinPointTests {
@Override
public void before(Method method, Object[] args, Object target) throws Throwable {
SourceLocation sloc = AbstractAspectJAdvice.currentJoinPoint().getSourceLocation();
assertEquals("Same source location must be returned on subsequent requests", sloc, AbstractAspectJAdvice.currentJoinPoint().getSourceLocation());
assertEquals("Same source location must be returned on subsequent requests", sloc, AbstractAspectJAdvice.currentJoinPoint().getSourceLocation());
assertEquals(TestBean.class, sloc.getWithinType());
try {
sloc.getLine();
@@ -172,7 +172,7 @@ public final class MethodInvocationProceedingJoinPointTests {
@Override
public void before(Method method, Object[] args, Object target) throws Throwable {
StaticPart staticPart = AbstractAspectJAdvice.currentJoinPoint().getStaticPart();
assertEquals("Same static part must be returned on subsequent requests", staticPart, AbstractAspectJAdvice.currentJoinPoint().getStaticPart());
assertEquals("Same static part must be returned on subsequent requests", staticPart, AbstractAspectJAdvice.currentJoinPoint().getStaticPart());
assertEquals(ProceedingJoinPoint.METHOD_EXECUTION, staticPart.getKind());
assertSame(AbstractAspectJAdvice.currentJoinPoint().getSignature(), staticPart.getSignature());
assertEquals(AbstractAspectJAdvice.currentJoinPoint().getSourceLocation(), staticPart.getSourceLocation());

View File

@@ -940,7 +940,7 @@ abstract class AbstractMakeModifiable {
}
// Find the current raw value, by invoking the corresponding setter
Method correspondingGetter = getGetterFromSetter(((MethodSignature) jp.getSignature()).getMethod());
Method correspondingGetter = getGetterFromSetter(((MethodSignature) jp.getSignature()).getMethod());
boolean modified = true;
if (correspondingGetter != null) {
try {

View File

@@ -137,4 +137,4 @@ public final class AopProxyUtilsTests {
AopProxyUtils.proxiedUserInterfaces(proxy);
}
}
}

View File

@@ -63,7 +63,6 @@ public final class PrototypeTargetTests {
assertEquals(10, interceptor.invocationCount);
}
public static interface TestBean {
public void doSomething();
}

View File

@@ -44,7 +44,7 @@ public final class ExposeInvocationInterceptorTests {
DefaultListableBeanFactory bf = new DefaultListableBeanFactory();
new XmlBeanDefinitionReader(bf).loadBeanDefinitions(CONTEXT);
ITestBean tb = (ITestBean) bf.getBean("proxy");
String name= "tony";
String name = "tony";
tb.setName(name);
// Fires context checks
assertEquals(name, tb.getName());

View File

@@ -33,4 +33,4 @@ public class CountingAfterReturningAdvice extends MethodCounter implements After
count(m);
}
}
}

View File

@@ -24,4 +24,4 @@ public class MyThrowsHandler extends MethodCounter implements ThrowsAdvice {
public void afterThrowing(Method m, Exception ex) throws Throwable {
throw new UnsupportedOperationException("Shouldn't be called");
}
}
}

View File

@@ -25,4 +25,4 @@ import java.lang.annotation.Target;
@Target(ElementType.TYPE)
public @interface EmptySpringAnnotation {
}
}

View File

@@ -30,4 +30,4 @@ public interface Lockable {
void unlock();
boolean locked();
}
}

View File

@@ -33,4 +33,4 @@ public class PerTargetAspect implements Ordered {
public void setOrder(int order) {
this.order = order;
}
}
}

View File

@@ -34,4 +34,4 @@ public class TwoAdviceAspect {
public void countSet(int newAge) throws Exception {
++totalCalls;
}
}
}