use the annotation meta data in problem reporting

This commit is contained in:
Christian Dupuis 2009-05-27 15:53:35 +00:00
parent 1c5e1e04e0
commit 1a7ec7daf2
1 changed files with 2 additions and 2 deletions

View File

@ -144,7 +144,7 @@ final class ConfigurationClass {
public FinalConfigurationProblem() {
super(String.format("@Configuration class '%s' may not be final. Remove the final modifier to continue.",
getSimpleName()), new Location(getResource(), ConfigurationClass.this));
getSimpleName()), new Location(getResource(), getMetadata()));
}
}
@ -155,7 +155,7 @@ final class ConfigurationClass {
public OverloadedMethodProblem(String methodName, int count) {
super(String.format("@Configuration class '%s' has %s overloaded factory methods of name '%s'. " +
"Only one factory method of the same name allowed.",
getSimpleName(), count, methodName), new Location(getResource(), ConfigurationClass.this));
getSimpleName(), count, methodName), new Location(getResource(), getMetadata()));
}
}