Skip to content

Commit cbff8b0

Browse files
committed
Javadoc fixes
1 parent dc50001 commit cbff8b0

File tree

2 files changed

+26
-3
lines changed

2 files changed

+26
-3
lines changed

spring-context/src/main/java/org/springframework/context/annotation/ConfigurationClassUtils.java

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2013 the original author or authors.
2+
* Copyright 2002-2014 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -93,22 +93,45 @@ else if (isLiteConfigurationCandidate(metadata)) {
9393
return false;
9494
}
9595

96+
/**
97+
* Check the given metadata for a configuration class candidate
98+
* (or nested component class declared within a configuration/component class).
99+
* @param metadata the metadata of the annotated class
100+
* @return {@code true} if the given class is to be registered as a
101+
* reflection-detected bean definition; {@code false} otherwise
102+
*/
96103
public static boolean isConfigurationCandidate(AnnotationMetadata metadata) {
97104
return (isFullConfigurationCandidate(metadata) || isLiteConfigurationCandidate(metadata));
98105
}
99106

107+
/**
108+
* Check the given metadata for a full configuration class candidate
109+
* (i.e. a class annotated with {@code @Configuration}).
110+
* @param metadata the metadata of the annotated class
111+
* @return {@code true} if the given class is to be processed as a full
112+
* configuration class, including cross-method call interception
113+
*/
100114
public static boolean isFullConfigurationCandidate(AnnotationMetadata metadata) {
101115
return metadata.isAnnotated(Configuration.class.getName());
102116
}
103117

118+
/**
119+
* Check the given metadata for a lite configuration class candidate
120+
* (e.g. a class annotated with {@code @Component} or just having
121+
* {@code @Bean methods}).
122+
* @param metadata the metadata of the annotated class
123+
* @return {@code true} if the given class is to be processed as a lite
124+
* configuration class, just registering it and scanning it for {@code @Bean} methods
125+
*/
104126
public static boolean isLiteConfigurationCandidate(AnnotationMetadata metadata) {
105127
// Do not consider an interface or an annotation...
106128
return (!metadata.isInterface() && (
107129
metadata.isAnnotated(Component.class.getName()) || metadata.hasAnnotatedMethods(Bean.class.getName())));
108130
}
109131

110132
/**
111-
* Determine whether the given bean definition indicates a full @Configuration class.
133+
* Determine whether the given bean definition indicates a full
134+
* {@code @Configuration} class.
112135
*/
113136
public static boolean isFullConfigurationClass(BeanDefinition beanDef) {
114137
return CONFIGURATION_CLASS_FULL.equals(beanDef.getAttribute(CONFIGURATION_CLASS_ATTRIBUTE));

spring-web/src/main/java/org/springframework/web/context/request/ServletWebRequest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public ServletWebRequest(HttpServletRequest request, HttpServletResponse respons
7676

7777

7878
/**
79-
* Exposes the native {@link HttpServletRequest} that we're wrapping (if any).
79+
* Exposes the native {@link HttpServletResponse} that we're wrapping (if any).
8080
*/
8181
public final HttpServletResponse getResponse() {
8282
return this.response;

0 commit comments

Comments
 (0)