Browse Source

Fix and improve Javadoc in spring-beans

See gh-28803
pull/28850/head
Marc Wrobel 4 years ago committed by Sam Brannen
parent
commit
c112bb0ae1
  1. 2
      spring-beans/src/main/java/org/springframework/beans/BeanWrapper.java
  2. 2
      spring-beans/src/main/java/org/springframework/beans/MutablePropertyValues.java
  3. 2
      spring-beans/src/main/java/org/springframework/beans/PropertyEditorRegistrar.java
  4. 4
      spring-beans/src/main/java/org/springframework/beans/factory/FactoryBean.java
  5. 4
      spring-beans/src/main/java/org/springframework/beans/factory/ListableBeanFactory.java
  6. 2
      spring-beans/src/main/java/org/springframework/beans/factory/ObjectFactory.java
  7. 4
      spring-beans/src/main/java/org/springframework/beans/factory/annotation/QualifierAnnotationAutowireCandidateResolver.java
  8. 2
      spring-beans/src/main/java/org/springframework/beans/factory/config/BeanFactoryPostProcessor.java
  9. 2
      spring-beans/src/main/java/org/springframework/beans/factory/config/ConstructorArgumentValues.java
  10. 2
      spring-beans/src/main/java/org/springframework/beans/factory/config/YamlProcessor.java
  11. 2
      spring-beans/src/main/java/org/springframework/beans/factory/parsing/BeanComponentDefinition.java
  12. 4
      spring-beans/src/main/java/org/springframework/beans/factory/parsing/ComponentDefinition.java
  13. 2
      spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.java
  14. 4
      spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractBeanDefinition.java
  15. 2
      spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractBeanFactory.java
  16. 2
      spring-beans/src/main/java/org/springframework/beans/factory/support/BeanDefinitionBuilder.java
  17. 2
      spring-beans/src/main/java/org/springframework/beans/factory/support/DefaultListableBeanFactory.java
  18. 2
      spring-beans/src/main/java/org/springframework/beans/factory/support/GenericTypeAwareAutowireCandidateResolver.java
  19. 2
      spring-beans/src/main/java/org/springframework/beans/factory/xml/AbstractBeanDefinitionParser.java
  20. 4
      spring-beans/src/main/java/org/springframework/beans/factory/xml/BeanDefinitionParserDelegate.java
  21. 2
      spring-beans/src/main/java/org/springframework/beans/factory/xml/DefaultNamespaceHandlerResolver.java
  22. 2
      spring-beans/src/main/java/org/springframework/beans/factory/xml/DelegatingEntityResolver.java
  23. 4
      spring-beans/src/main/java/org/springframework/beans/factory/xml/PluggableSchemaResolver.java
  24. 2
      spring-beans/src/main/java/org/springframework/beans/factory/xml/SimpleConstructorNamespaceHandler.java
  25. 4
      spring-beans/src/main/java/org/springframework/beans/factory/xml/XmlBeanDefinitionReader.java
  26. 6
      spring-beans/src/main/java/org/springframework/beans/propertyeditors/StringArrayPropertyEditor.java
  27. 2
      spring-beans/src/main/java/org/springframework/beans/propertyeditors/URIEditor.java
  28. 2
      spring-beans/src/test/java/org/springframework/beans/factory/config/MethodInvokingFactoryBeanTests.java
  29. 2
      spring-beans/src/testFixtures/java/org/springframework/beans/testfixture/beans/ITestBean.java

2
spring-beans/src/main/java/org/springframework/beans/BeanWrapper.java

@ -82,7 +82,7 @@ public interface BeanWrapper extends ConfigurablePropertyAccessor {
* Obtain the property descriptor for a specific property * Obtain the property descriptor for a specific property
* of the wrapped object. * of the wrapped object.
* @param propertyName the property to obtain the descriptor for * @param propertyName the property to obtain the descriptor for
* (may be a nested path, but no indexed/mapped property) * (may be a nested path, but not an indexed/mapped property)
* @return the property descriptor for the specified property * @return the property descriptor for the specified property
* @throws InvalidPropertyException if there is no such property * @throws InvalidPropertyException if there is no such property
*/ */

2
spring-beans/src/main/java/org/springframework/beans/MutablePropertyValues.java

@ -327,7 +327,7 @@ public class MutablePropertyValues implements PropertyValues, Serializable {
/** /**
* Register the specified property as "processed" in the sense * Register the specified property as "processed" in the sense
* of some processor calling the corresponding setter method * of some processor calling the corresponding setter method
* outside of the PropertyValue(s) mechanism. * outside the PropertyValue(s) mechanism.
* <p>This will lead to {@code true} being returned from * <p>This will lead to {@code true} being returned from
* a {@link #contains} call for the specified property. * a {@link #contains} call for the specified property.
* @param propertyName the name of the property. * @param propertyName the name of the property.

2
spring-beans/src/main/java/org/springframework/beans/PropertyEditorRegistrar.java

@ -22,7 +22,7 @@ package org.springframework.beans;
* {@link org.springframework.beans.PropertyEditorRegistry property editor registry}. * {@link org.springframework.beans.PropertyEditorRegistry property editor registry}.
* *
* <p>This is particularly useful when you need to use the same set of * <p>This is particularly useful when you need to use the same set of
* property editors in several different situations: write a corresponding * property editors in several situations: write a corresponding
* registrar and reuse that in each case. * registrar and reuse that in each case.
* *
* @author Juergen Hoeller * @author Juergen Hoeller

4
spring-beans/src/main/java/org/springframework/beans/factory/FactoryBean.java

@ -45,7 +45,7 @@ import org.springframework.lang.Nullable;
* *
* <p><b>The container is only responsible for managing the lifecycle of the FactoryBean * <p><b>The container is only responsible for managing the lifecycle of the FactoryBean
* instance, not the lifecycle of the objects created by the FactoryBean.</b> Therefore, * instance, not the lifecycle of the objects created by the FactoryBean.</b> Therefore,
* a destroy method on an exposed bean object (such as {@link java.io.Closeable#close()} * a destroy method on an exposed bean object (such as {@link java.io.Closeable#close()})
* will <i>not</i> be called automatically. Instead, a FactoryBean should implement * will <i>not</i> be called automatically. Instead, a FactoryBean should implement
* {@link DisposableBean} and delegate any such close call to the underlying object. * {@link DisposableBean} and delegate any such close call to the underlying object.
* *
@ -108,7 +108,7 @@ public interface FactoryBean<T> {
* been fully initialized. It must not rely on state created during * been fully initialized. It must not rely on state created during
* initialization; of course, it can still use such state if available. * initialization; of course, it can still use such state if available.
* <p><b>NOTE:</b> Autowiring will simply ignore FactoryBeans that return * <p><b>NOTE:</b> Autowiring will simply ignore FactoryBeans that return
* {@code null} here. Therefore it is highly recommended to implement * {@code null} here. Therefore, it is highly recommended to implement
* this method properly, using the current state of the FactoryBean. * this method properly, using the current state of the FactoryBean.
* @return the type of object that this FactoryBean creates, * @return the type of object that this FactoryBean creates,
* or {@code null} if not known at the time of the call * or {@code null} if not known at the time of the call

4
spring-beans/src/main/java/org/springframework/beans/factory/ListableBeanFactory.java

@ -343,7 +343,7 @@ public interface ListableBeanFactory extends BeanFactory {
/** /**
* Find an {@link Annotation} of {@code annotationType} on the specified bean, * Find an {@link Annotation} of {@code annotationType} on the specified bean,
* traversing its interfaces and super classes if no annotation can be found on * traversing its interfaces and superclasses if no annotation can be found on
* the given class itself, as well as checking the bean's factory method (if any). * the given class itself, as well as checking the bean's factory method (if any).
* @param beanName the name of the bean to look for annotations on * @param beanName the name of the bean to look for annotations on
* @param annotationType the type of annotation to look for * @param annotationType the type of annotation to look for
@ -361,7 +361,7 @@ public interface ListableBeanFactory extends BeanFactory {
/** /**
* Find an {@link Annotation} of {@code annotationType} on the specified bean, * Find an {@link Annotation} of {@code annotationType} on the specified bean,
* traversing its interfaces and super classes if no annotation can be found on * traversing its interfaces and superclasses if no annotation can be found on
* the given class itself, as well as checking the bean's factory method (if any). * the given class itself, as well as checking the bean's factory method (if any).
* @param beanName the name of the bean to look for annotations on * @param beanName the name of the bean to look for annotations on
* @param annotationType the type of annotation to look for * @param annotationType the type of annotation to look for

2
spring-beans/src/main/java/org/springframework/beans/factory/ObjectFactory.java

@ -23,7 +23,7 @@ import org.springframework.beans.BeansException;
* (possibly shared or independent) when invoked. * (possibly shared or independent) when invoked.
* *
* <p>This interface is typically used to encapsulate a generic factory which * <p>This interface is typically used to encapsulate a generic factory which
* returns a new instance (prototype) of some target object on each invocation. * returns a new instance (prototype) of some target objects on each invocation.
* *
* <p>This interface is similar to {@link FactoryBean}, but implementations * <p>This interface is similar to {@link FactoryBean}, but implementations
* of the latter are normally meant to be defined as SPI instances in a * of the latter are normally meant to be defined as SPI instances in a

4
spring-beans/src/main/java/org/springframework/beans/factory/annotation/QualifierAnnotationAutowireCandidateResolver.java

@ -137,7 +137,7 @@ public class QualifierAnnotationAutowireCandidateResolver extends GenericTypeAwa
* as a <em>qualifier</em>, the bean must 'match' against the annotation as * as a <em>qualifier</em>, the bean must 'match' against the annotation as
* well as any attributes it may contain. The bean definition must contain * well as any attributes it may contain. The bean definition must contain
* the same qualifier or match by meta attributes. A "value" attribute will * the same qualifier or match by meta attributes. A "value" attribute will
* fallback to match against the bean name or an alias if a qualifier or * fall back to match against the bean name or an alias if a qualifier or
* attribute does not match. * attribute does not match.
* @see Qualifier * @see Qualifier
*/ */
@ -186,7 +186,7 @@ public class QualifierAnnotationAutowireCandidateResolver extends GenericTypeAwa
if (isQualifier(metaType)) { if (isQualifier(metaType)) {
foundMeta = true; foundMeta = true;
// Only accept fallback match if @Qualifier annotation has a value... // Only accept fallback match if @Qualifier annotation has a value...
// Otherwise it is just a marker for a custom qualifier annotation. // Otherwise, it is just a marker for a custom qualifier annotation.
if ((fallbackToMeta && ObjectUtils.isEmpty(AnnotationUtils.getValue(metaAnn))) || if ((fallbackToMeta && ObjectUtils.isEmpty(AnnotationUtils.getValue(metaAnn))) ||
!checkQualifier(bdHolder, metaAnn, typeConverter)) { !checkQualifier(bdHolder, metaAnn, typeConverter)) {
return false; return false;

2
spring-beans/src/main/java/org/springframework/beans/factory/config/BeanFactoryPostProcessor.java

@ -30,7 +30,7 @@ import org.springframework.beans.BeansException;
* *
* <p>A {@code BeanFactoryPostProcessor} may interact with and modify bean * <p>A {@code BeanFactoryPostProcessor} may interact with and modify bean
* definitions, but never bean instances. Doing so may cause premature bean * definitions, but never bean instances. Doing so may cause premature bean
* instantiation, violating the container and causing unintended side-effects. * instantiation, violating the container and causing unintended side effects.
* If bean instance interaction is required, consider implementing * If bean instance interaction is required, consider implementing
* {@link BeanPostProcessor} instead. * {@link BeanPostProcessor} instead.
* *

2
spring-beans/src/main/java/org/springframework/beans/factory/config/ConstructorArgumentValues.java

@ -65,7 +65,7 @@ public class ConstructorArgumentValues {
/** /**
* Copy all given argument values into this object, using separate holder * Copy all given argument values into this object, using separate holder
* instances to keep the values independent from the original object. * instances to keep the values independent of the original object.
* <p>Note: Identical ValueHolder instances will only be registered once, * <p>Note: Identical ValueHolder instances will only be registered once,
* to allow for merging and re-merging of argument value definitions. Distinct * to allow for merging and re-merging of argument value definitions. Distinct
* ValueHolder instances carrying the same content are of course allowed. * ValueHolder instances carrying the same content are of course allowed.

2
spring-beans/src/main/java/org/springframework/beans/factory/config/YamlProcessor.java

@ -155,7 +155,7 @@ public abstract class YamlProcessor {
* resources. Each resource is parsed in turn and the documents inside checked against * resources. Each resource is parsed in turn and the documents inside checked against
* the {@link #setDocumentMatchers(DocumentMatcher...) matchers}. If a document * the {@link #setDocumentMatchers(DocumentMatcher...) matchers}. If a document
* matches it is passed into the callback, along with its representation as Properties. * matches it is passed into the callback, along with its representation as Properties.
* Depending on the {@link #setResolutionMethod(ResolutionMethod)} not all of the * Depending on the {@link #setResolutionMethod(ResolutionMethod)} not all the
* documents will be parsed. * documents will be parsed.
* @param callback a callback to delegate to once matching documents are found * @param callback a callback to delegate to once matching documents are found
* @see #createYaml() * @see #createYaml()

2
spring-beans/src/main/java/org/springframework/beans/factory/parsing/BeanComponentDefinition.java

@ -124,7 +124,7 @@ public class BeanComponentDefinition extends BeanDefinitionHolder implements Com
} }
/** /**
* This implementations expects the other object to be of type BeanComponentDefinition * This implementation expects the other object to be of type BeanComponentDefinition
* as well, in addition to the superclass's equality requirements. * as well, in addition to the superclass's equality requirements.
*/ */
@Override @Override

4
spring-beans/src/main/java/org/springframework/beans/factory/parsing/ComponentDefinition.java

@ -50,13 +50,13 @@ import org.springframework.beans.factory.config.BeanReference;
* {@link #getBeanReferences}, tools may wish to inspect all {@link BeanDefinition BeanDefinitions} to gather * {@link #getBeanReferences}, tools may wish to inspect all {@link BeanDefinition BeanDefinitions} to gather
* the full set of {@link BeanReference BeanReferences}. Implementations are required to provide * the full set of {@link BeanReference BeanReferences}. Implementations are required to provide
* all {@link BeanReference BeanReferences} that are required to validate the configuration of the * all {@link BeanReference BeanReferences} that are required to validate the configuration of the
* overall logical entity as well as those required to provide full user visualisation of the configuration. * overall logical entity as well as those required to provide full user visualization of the configuration.
* It is expected that certain {@link BeanReference BeanReferences} will not be important to * It is expected that certain {@link BeanReference BeanReferences} will not be important to
* validation or to the user view of the configuration and as such these may be omitted. A tool may wish to * validation or to the user view of the configuration and as such these may be omitted. A tool may wish to
* display any additional {@link BeanReference BeanReferences} sourced through the supplied * display any additional {@link BeanReference BeanReferences} sourced through the supplied
* {@link BeanDefinition BeanDefinitions} but this is not considered to be a typical case. * {@link BeanDefinition BeanDefinitions} but this is not considered to be a typical case.
* *
* <p>Tools can determine the important of contained {@link BeanDefinition BeanDefinitions} by checking the * <p>Tools can determine the importance of contained {@link BeanDefinition BeanDefinitions} by checking the
* {@link BeanDefinition#getRole role identifier}. The role is essentially a hint to the tool as to how * {@link BeanDefinition#getRole role identifier}. The role is essentially a hint to the tool as to how
* important the configuration provider believes a {@link BeanDefinition} is to the end user. It is expected * important the configuration provider believes a {@link BeanDefinition} is to the end user. It is expected
* that tools will <strong>not</strong> display all {@link BeanDefinition BeanDefinitions} for a given * that tools will <strong>not</strong> display all {@link BeanDefinition BeanDefinitions} for a given

2
spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.java

@ -1510,7 +1510,7 @@ public abstract class AbstractAutowireCapableBeanFactory extends AbstractBeanFac
try { try {
PropertyDescriptor pd = bw.getPropertyDescriptor(propertyName); PropertyDescriptor pd = bw.getPropertyDescriptor(propertyName);
// Don't try autowiring by type for type Object: never makes sense, // Don't try autowiring by type for type Object: never makes sense,
// even if it technically is a unsatisfied, non-simple property. // even if it technically is an unsatisfied, non-simple property.
if (Object.class != pd.getPropertyType()) { if (Object.class != pd.getPropertyType()) {
MethodParameter methodParam = BeanUtils.getWriteMethodParameter(pd); MethodParameter methodParam = BeanUtils.getWriteMethodParameter(pd);
// Do not allow eager init for type matching in case of a prioritized post-processor. // Do not allow eager init for type matching in case of a prioritized post-processor.

4
spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractBeanDefinition.java

@ -945,7 +945,7 @@ public abstract class AbstractBeanDefinition extends BeanMetadataAttributeAccess
} }
/** /**
* Specify whether or not the configured initializer method is the default. * Specify whether the configured initializer method is the default.
* <p>The default value is {@code true} for a locally specified init method * <p>The default value is {@code true} for a locally specified init method
* but switched to {@code false} for a shared setting in a defaults section * but switched to {@code false} for a shared setting in a defaults section
* (e.g. {@code bean init-method} versus {@code beans default-init-method} * (e.g. {@code bean init-method} versus {@code beans default-init-method}
@ -984,7 +984,7 @@ public abstract class AbstractBeanDefinition extends BeanMetadataAttributeAccess
} }
/** /**
* Specify whether or not the configured destroy method is the default. * Specify whether the configured destroy method is the default.
* <p>The default value is {@code true} for a locally specified destroy method * <p>The default value is {@code true} for a locally specified destroy method
* but switched to {@code false} for a shared setting in a defaults section * but switched to {@code false} for a shared setting in a defaults section
* (e.g. {@code bean destroy-method} versus {@code beans default-destroy-method} * (e.g. {@code bean destroy-method} versus {@code beans default-destroy-method}

2
spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractBeanFactory.java

@ -593,7 +593,7 @@ public abstract class AbstractBeanFactory extends FactoryBeanRegistrySupport imp
RootBeanDefinition mbd = getMergedLocalBeanDefinition(beanName); RootBeanDefinition mbd = getMergedLocalBeanDefinition(beanName);
BeanDefinitionHolder dbd = mbd.getDecoratedDefinition(); BeanDefinitionHolder dbd = mbd.getDecoratedDefinition();
// Setup the types that we want to match against // Set up the types that we want to match against
Class<?> classToMatch = typeToMatch.resolve(); Class<?> classToMatch = typeToMatch.resolve();
if (classToMatch == null) { if (classToMatch == null) {
classToMatch = FactoryBean.class; classToMatch = FactoryBean.class;

2
spring-beans/src/main/java/org/springframework/beans/factory/support/BeanDefinitionBuilder.java

@ -293,7 +293,7 @@ public final class BeanDefinitionBuilder {
} }
/** /**
* Set whether or not this definition is abstract. * Set whether this definition is abstract.
*/ */
public BeanDefinitionBuilder setAbstract(boolean flag) { public BeanDefinitionBuilder setAbstract(boolean flag) {
this.beanDefinition.setAbstract(flag); this.beanDefinition.setAbstract(flag);

2
spring-beans/src/main/java/org/springframework/beans/factory/support/DefaultListableBeanFactory.java

@ -280,7 +280,7 @@ public class DefaultListableBeanFactory extends AbstractAutowireCapableBeanFacto
} }
/** /**
* Return the dependency comparator for this BeanFactory (may be {@code null}. * Return the dependency comparator for this BeanFactory (may be {@code null}).
* @since 4.0 * @since 4.0
*/ */
@Nullable @Nullable

2
spring-beans/src/main/java/org/springframework/beans/factory/support/GenericTypeAwareAutowireCandidateResolver.java

@ -33,7 +33,7 @@ import org.springframework.util.ClassUtils;
/** /**
* Basic {@link AutowireCandidateResolver} that performs a full generic type * Basic {@link AutowireCandidateResolver} that performs a full generic type
* match with the candidate's type if the dependency is declared as a generic type * match with the candidate's type if the dependency is declared as a generic type
* (e.g. Repository&lt;Customer&gt;). * (e.g. {@code Repository<Customer>}).
* *
* <p>This is the base class for * <p>This is the base class for
* {@link org.springframework.beans.factory.annotation.QualifierAnnotationAutowireCandidateResolver}, * {@link org.springframework.beans.factory.annotation.QualifierAnnotationAutowireCandidateResolver},

2
spring-beans/src/main/java/org/springframework/beans/factory/xml/AbstractBeanDefinitionParser.java

@ -124,7 +124,7 @@ public abstract class AbstractBeanDefinitionParser implements BeanDefinitionPars
/** /**
* Register the supplied {@link BeanDefinitionHolder bean} with the supplied * Register the supplied {@link BeanDefinitionHolder bean} with the supplied
* {@link BeanDefinitionRegistry registry}. * {@link BeanDefinitionRegistry registry}.
* <p>Subclasses can override this method to control whether or not the supplied * <p>Subclasses can override this method to control whether the supplied
* {@link BeanDefinitionHolder bean} is actually even registered, or to * {@link BeanDefinitionHolder bean} is actually even registered, or to
* register even more beans. * register even more beans.
* <p>The default implementation registers the supplied {@link BeanDefinitionHolder bean} * <p>The default implementation registers the supplied {@link BeanDefinitionHolder bean}

4
spring-beans/src/main/java/org/springframework/beans/factory/xml/BeanDefinitionParserDelegate.java

@ -1362,7 +1362,7 @@ public class BeanDefinitionParserDelegate {
} }
/** /**
* Parse a custom element (outside of the default namespace). * Parse a custom element (outside the default namespace).
* @param ele the element to parse * @param ele the element to parse
* @return the resulting bean definition * @return the resulting bean definition
*/ */
@ -1372,7 +1372,7 @@ public class BeanDefinitionParserDelegate {
} }
/** /**
* Parse a custom element (outside of the default namespace). * Parse a custom element (outside the default namespace).
* @param ele the element to parse * @param ele the element to parse
* @param containingBd the containing bean definition (if any) * @param containingBd the containing bean definition (if any)
* @return the resulting bean definition * @return the resulting bean definition

2
spring-beans/src/main/java/org/springframework/beans/factory/xml/DefaultNamespaceHandlerResolver.java

@ -96,7 +96,7 @@ public class DefaultNamespaceHandlerResolver implements NamespaceHandlerResolver
* Create a new {@code DefaultNamespaceHandlerResolver} using the * Create a new {@code DefaultNamespaceHandlerResolver} using the
* supplied mapping file location. * supplied mapping file location.
* @param classLoader the {@link ClassLoader} instance used to load mapping resources * @param classLoader the {@link ClassLoader} instance used to load mapping resources
* may be {@code null}, in which case the thread context ClassLoader will be used) * may be {@code null}, in which case the thread context ClassLoader will be used
* @param handlerMappingsLocation the mapping file location * @param handlerMappingsLocation the mapping file location
*/ */
public DefaultNamespaceHandlerResolver(@Nullable ClassLoader classLoader, String handlerMappingsLocation) { public DefaultNamespaceHandlerResolver(@Nullable ClassLoader classLoader, String handlerMappingsLocation) {

2
spring-beans/src/main/java/org/springframework/beans/factory/xml/DelegatingEntityResolver.java

@ -56,7 +56,7 @@ public class DelegatingEntityResolver implements EntityResolver {
* <p>Configures the {@link PluggableSchemaResolver} with the supplied * <p>Configures the {@link PluggableSchemaResolver} with the supplied
* {@link ClassLoader}. * {@link ClassLoader}.
* @param classLoader the ClassLoader to use for loading * @param classLoader the ClassLoader to use for loading
* (can be {@code null}) to use the default ClassLoader) * (can be {@code null} to use the default ClassLoader)
*/ */
public DelegatingEntityResolver(@Nullable ClassLoader classLoader) { public DelegatingEntityResolver(@Nullable ClassLoader classLoader) {
this.dtdResolver = new BeansDtdResolver(); this.dtdResolver = new BeansDtdResolver();

4
spring-beans/src/main/java/org/springframework/beans/factory/xml/PluggableSchemaResolver.java

@ -80,7 +80,7 @@ public class PluggableSchemaResolver implements EntityResolver {
* Loads the schema URL &rarr; schema file location mappings using the default * Loads the schema URL &rarr; schema file location mappings using the default
* mapping file pattern "META-INF/spring.schemas". * mapping file pattern "META-INF/spring.schemas".
* @param classLoader the ClassLoader to use for loading * @param classLoader the ClassLoader to use for loading
* (can be {@code null}) to use the default ClassLoader) * (can be {@code null} to use the default ClassLoader)
* @see PropertiesLoaderUtils#loadAllProperties(String, ClassLoader) * @see PropertiesLoaderUtils#loadAllProperties(String, ClassLoader)
*/ */
public PluggableSchemaResolver(@Nullable ClassLoader classLoader) { public PluggableSchemaResolver(@Nullable ClassLoader classLoader) {
@ -92,7 +92,7 @@ public class PluggableSchemaResolver implements EntityResolver {
* Loads the schema URL &rarr; schema file location mappings using the given * Loads the schema URL &rarr; schema file location mappings using the given
* mapping file pattern. * mapping file pattern.
* @param classLoader the ClassLoader to use for loading * @param classLoader the ClassLoader to use for loading
* (can be {@code null}) to use the default ClassLoader) * (can be {@code null} to use the default ClassLoader)
* @param schemaMappingsLocation the location of the file that defines schema mappings * @param schemaMappingsLocation the location of the file that defines schema mappings
* (must not be empty) * (must not be empty)
* @see PropertiesLoaderUtils#loadAllProperties(String, ClassLoader) * @see PropertiesLoaderUtils#loadAllProperties(String, ClassLoader)

2
spring-beans/src/main/java/org/springframework/beans/factory/xml/SimpleConstructorNamespaceHandler.java

@ -50,7 +50,7 @@ import org.springframework.util.StringUtils;
* the bean that will be considered as a parameter. * the bean that will be considered as a parameter.
* *
* <b>Note</b>: This implementation supports only named parameters - there is no * <b>Note</b>: This implementation supports only named parameters - there is no
* support for indexes or types. Further more, the names are used as hints by * support for indexes or types. Furthermore, the names are used as hints by
* the container which, by default, does type introspection. * the container which, by default, does type introspection.
* *
* @author Costin Leau * @author Costin Leau

4
spring-beans/src/main/java/org/springframework/beans/factory/xml/XmlBeanDefinitionReader.java

@ -184,7 +184,7 @@ public class XmlBeanDefinitionReader extends AbstractBeanDefinitionReader {
} }
/** /**
* Set whether or not the XML parser should be XML namespace aware. * Set whether the XML parser should be XML namespace aware.
* Default is "false". * Default is "false".
* <p>This is typically not needed when schema validation is active. * <p>This is typically not needed when schema validation is active.
* However, without validation, this has to be switched to "true" * However, without validation, this has to be switched to "true"
@ -195,7 +195,7 @@ public class XmlBeanDefinitionReader extends AbstractBeanDefinitionReader {
} }
/** /**
* Return whether or not the XML parser should be XML namespace aware. * Return whether the XML parser should be XML namespace aware.
*/ */
public boolean isNamespaceAware() { public boolean isNamespaceAware() {
return this.namespaceAware; return this.namespaceAware;

6
spring-beans/src/main/java/org/springframework/beans/propertyeditors/StringArrayPropertyEditor.java

@ -26,7 +26,7 @@ import org.springframework.util.StringUtils;
* Custom {@link java.beans.PropertyEditor} for String arrays. * Custom {@link java.beans.PropertyEditor} for String arrays.
* *
* <p>Strings must be in CSV format, with a customizable separator. * <p>Strings must be in CSV format, with a customizable separator.
* By default values in the result are trimmed of whitespace. * By default, values in the result are trimmed of whitespace.
* *
* @author Rod Johnson * @author Rod Johnson
* @author Juergen Hoeller * @author Juergen Hoeller
@ -86,7 +86,7 @@ public class StringArrayPropertyEditor extends PropertyEditorSupport {
* @param emptyArrayAsNull {@code true} if an empty String array * @param emptyArrayAsNull {@code true} if an empty String array
* is to be transformed into {@code null} * is to be transformed into {@code null}
* @param trimValues {@code true} if the values in the parsed arrays * @param trimValues {@code true} if the values in the parsed arrays
* are to be trimmed of whitespace (default is true) * are to be trimmed of whitespace (default is {@code true})
*/ */
public StringArrayPropertyEditor(String separator, boolean emptyArrayAsNull, boolean trimValues) { public StringArrayPropertyEditor(String separator, boolean emptyArrayAsNull, boolean trimValues) {
this(separator, null, emptyArrayAsNull, trimValues); this(separator, null, emptyArrayAsNull, trimValues);
@ -114,7 +114,7 @@ public class StringArrayPropertyEditor extends PropertyEditorSupport {
* @param emptyArrayAsNull {@code true} if an empty String array * @param emptyArrayAsNull {@code true} if an empty String array
* is to be transformed into {@code null} * is to be transformed into {@code null}
* @param trimValues {@code true} if the values in the parsed arrays * @param trimValues {@code true} if the values in the parsed arrays
* are to be trimmed of whitespace (default is true) * are to be trimmed of whitespace (default is {@code true})
*/ */
public StringArrayPropertyEditor( public StringArrayPropertyEditor(
String separator, @Nullable String charsToDelete, boolean emptyArrayAsNull, boolean trimValues) { String separator, @Nullable String charsToDelete, boolean emptyArrayAsNull, boolean trimValues) {

2
spring-beans/src/main/java/org/springframework/beans/propertyeditors/URIEditor.java

@ -130,7 +130,7 @@ public class URIEditor extends PropertyEditorSupport {
/** /**
* Create a URI instance for the given user-specified String value. * Create a URI instance for the given user-specified String value.
* <p>The default implementation encodes the value into a RFC-2396 compliant URI. * <p>The default implementation encodes the value into an RFC-2396 compliant URI.
* @param value the value to convert into a URI instance * @param value the value to convert into a URI instance
* @return the URI instance * @return the URI instance
* @throws java.net.URISyntaxException if URI conversion failed * @throws java.net.URISyntaxException if URI conversion failed

2
spring-beans/src/test/java/org/springframework/beans/factory/config/MethodInvokingFactoryBeanTests.java

@ -43,7 +43,7 @@ public class MethodInvokingFactoryBeanTests {
@Test @Test
public void testParameterValidation() throws Exception { public void testParameterValidation() throws Exception {
// assert that only static OR non static are set, but not both or none // assert that only static OR non-static are set, but not both or none
MethodInvokingFactoryBean mcfb = new MethodInvokingFactoryBean(); MethodInvokingFactoryBean mcfb = new MethodInvokingFactoryBean();
assertThatIllegalArgumentException().isThrownBy(mcfb::afterPropertiesSet); assertThatIllegalArgumentException().isThrownBy(mcfb::afterPropertiesSet);

2
spring-beans/src/testFixtures/java/org/springframework/beans/testfixture/beans/ITestBean.java

@ -22,7 +22,7 @@ import java.io.IOException;
* Interface used for {@link org.springframework.beans.testfixture.beans.TestBean}. * Interface used for {@link org.springframework.beans.testfixture.beans.TestBean}.
* *
* <p>Two methods are the same as on Person, but if this * <p>Two methods are the same as on Person, but if this
* extends person it breaks quite a few tests.. * extends person it breaks quite a few tests.
* *
* @author Rod Johnson * @author Rod Johnson
* @author Juergen Hoeller * @author Juergen Hoeller

Loading…
Cancel
Save