Polishing
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2014 the original author or authors.
|
||||
* Copyright 2002-2020 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -67,6 +67,7 @@ import java.io.Serializable;
|
||||
* @since 2.5.2
|
||||
*/
|
||||
public abstract aspect AbstractInterfaceDrivenDependencyInjectionAspect extends AbstractDependencyInjectionAspect {
|
||||
|
||||
/**
|
||||
* Select initialization join point as object construction
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2014 the original author or authors.
|
||||
* Copyright 2002-2020 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -32,8 +32,8 @@ import org.springframework.beans.factory.wiring.BeanConfigurerSupport;
|
||||
* Concrete aspect that uses the {@link Configurable} annotation to identify
|
||||
* which classes need autowiring.
|
||||
*
|
||||
* <p>The bean name to look up will be taken from the {@code @Configurable}
|
||||
* annotation if specified, otherwise the default bean name to look up will be
|
||||
* <p>The bean name to look up will be taken from the {@code @Configurable}
|
||||
* annotation if specified; otherwise, the default bean name to look up will be
|
||||
* the fully qualified name of the class being configured.
|
||||
*
|
||||
* @author Rod Johnson
|
||||
@@ -47,22 +47,26 @@ import org.springframework.beans.factory.wiring.BeanConfigurerSupport;
|
||||
public aspect AnnotationBeanConfigurerAspect extends AbstractInterfaceDrivenDependencyInjectionAspect
|
||||
implements BeanFactoryAware, InitializingBean, DisposableBean {
|
||||
|
||||
private BeanConfigurerSupport beanConfigurerSupport = new BeanConfigurerSupport();
|
||||
private final BeanConfigurerSupport beanConfigurerSupport = new BeanConfigurerSupport();
|
||||
|
||||
|
||||
@Override
|
||||
public void setBeanFactory(BeanFactory beanFactory) {
|
||||
this.beanConfigurerSupport.setBeanWiringInfoResolver(new AnnotationBeanWiringInfoResolver());
|
||||
this.beanConfigurerSupport.setBeanFactory(beanFactory);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterPropertiesSet() {
|
||||
this.beanConfigurerSupport.afterPropertiesSet();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void configureBean(Object bean) {
|
||||
this.beanConfigurerSupport.configureBean(bean);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void destroy() {
|
||||
this.beanConfigurerSupport.destroy();
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2016 the original author or authors.
|
||||
* Copyright 2002-2020 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -74,8 +74,8 @@ public interface WebRequest extends RequestAttributes {
|
||||
|
||||
/**
|
||||
* Return a Iterator over request parameter names.
|
||||
* @see javax.servlet.http.HttpServletRequest#getParameterNames()
|
||||
* @since 3.0
|
||||
* @see javax.servlet.http.HttpServletRequest#getParameterNames()
|
||||
*/
|
||||
Iterator<String> getParameterNames();
|
||||
|
||||
@@ -132,7 +132,7 @@ public interface WebRequest extends RequestAttributes {
|
||||
* and HTTP status when applicable.
|
||||
* <p>Typical usage:
|
||||
* <pre class="code">
|
||||
* public String myHandleMethod(WebRequest webRequest, Model model) {
|
||||
* public String myHandleMethod(WebRequest request, Model model) {
|
||||
* long lastModified = // application-specific calculation
|
||||
* if (request.checkNotModified(lastModified)) {
|
||||
* // shortcut exit - no further processing necessary
|
||||
@@ -169,7 +169,7 @@ public interface WebRequest extends RequestAttributes {
|
||||
* and HTTP status when applicable.
|
||||
* <p>Typical usage:
|
||||
* <pre class="code">
|
||||
* public String myHandleMethod(WebRequest webRequest, Model model) {
|
||||
* public String myHandleMethod(WebRequest request, Model model) {
|
||||
* String eTag = // application-specific calculation
|
||||
* if (request.checkNotModified(eTag)) {
|
||||
* // shortcut exit - no further processing necessary
|
||||
@@ -200,7 +200,7 @@ public interface WebRequest extends RequestAttributes {
|
||||
* response headers, and HTTP status when applicable.
|
||||
* <p>Typical usage:
|
||||
* <pre class="code">
|
||||
* public String myHandleMethod(WebRequest webRequest, Model model) {
|
||||
* public String myHandleMethod(WebRequest request, Model model) {
|
||||
* String eTag = // application-specific calculation
|
||||
* long lastModified = // application-specific calculation
|
||||
* if (request.checkNotModified(eTag, lastModified)) {
|
||||
|
||||
@@ -4588,7 +4588,7 @@ This can be achieved as follows:
|
||||
[subs="verbatim,quotes"]
|
||||
----
|
||||
@RequestMapping
|
||||
public String myHandleMethod(WebRequest webRequest, Model model) {
|
||||
public String myHandleMethod(WebRequest request, Model model) {
|
||||
|
||||
long lastModified = // 1. application-specific calculation
|
||||
|
||||
|
||||
Reference in New Issue
Block a user