Polishing

This commit is contained in:
Juergen Hoeller 2018-07-26 23:40:32 +02:00
parent 7c9ba80f85
commit 025fd2962e
2 changed files with 6 additions and 6 deletions

View File

@ -17,8 +17,8 @@
package org.springframework.context.annotation;
/**
* Enumeration used to determine whether JDK proxy-based or AspectJ weaving-based advice
* should be applied.
* Enumeration used to determine whether JDK proxy-based or
* AspectJ weaving-based advice should be applied.
*
* @author Chris Beams
* @since 3.1

View File

@ -70,14 +70,14 @@ public abstract class AdviceModeImportSelector<A extends Annotation> implements
AnnotationAttributes attributes = AnnotationConfigUtils.attributesFor(importingClassMetadata, annType);
if (attributes == null) {
throw new IllegalArgumentException(String.format(
"@%s is not present on importing class '%s' as expected",
annType.getSimpleName(), importingClassMetadata.getClassName()));
"@%s is not present on importing class '%s' as expected",
annType.getSimpleName(), importingClassMetadata.getClassName()));
}
AdviceMode adviceMode = attributes.getEnum(this.getAdviceModeAttributeName());
AdviceMode adviceMode = attributes.getEnum(getAdviceModeAttributeName());
String[] imports = selectImports(adviceMode);
if (imports == null) {
throw new IllegalArgumentException(String.format("Unknown AdviceMode: '%s'", adviceMode));
throw new IllegalArgumentException("Unknown AdviceMode: " + adviceMode);
}
return imports;
}