From c2c3be4ee33e7d06a73f5241bc306cff965d3495 Mon Sep 17 00:00:00 2001 From: Sam Brannen Date: Sun, 18 Dec 2022 10:48:03 +0100 Subject: [PATCH] Polishing --- .../src/docs/asciidoc/core/core-aop-api.adoc | 14 +++++++------- .../src/docs/asciidoc/core/core-aop.adoc | 2 +- .../src/docs/asciidoc/core/core-appendix.adoc | 4 ++-- .../src/docs/asciidoc/core/core-beans.adoc | 8 ++++---- framework-docs/src/docs/asciidoc/data-access.adoc | 8 ++++---- .../src/docs/asciidoc/integration/cache.adoc | 6 +++--- .../testing/spring-mvc-test-framework.adoc | 2 +- .../src/docs/asciidoc/web/webflux-webclient.adoc | 2 +- .../src/docs/asciidoc/web/webmvc-view.adoc | 2 +- framework-docs/src/docs/asciidoc/web/webmvc.adoc | 2 +- .../src/docs/asciidoc/web/websocket-intro.adoc | 2 +- 11 files changed, 26 insertions(+), 26 deletions(-) diff --git a/framework-docs/src/docs/asciidoc/core/core-aop-api.adoc b/framework-docs/src/docs/asciidoc/core/core-aop-api.adoc index 1fa9a236eb6..e627c4a7d97 100644 --- a/framework-docs/src/docs/asciidoc/core/core-aop-api.adoc +++ b/framework-docs/src/docs/asciidoc/core/core-aop-api.adoc @@ -23,7 +23,7 @@ Spring's pointcut model enables pointcut reuse independent of advice types. You target different advice with the same pointcut. The `org.springframework.aop.Pointcut` interface is the central interface, used to -target advices to particular classes and methods. The complete interface follows: +target advice to particular classes and methods. The complete interface follows: [source,java,indent=0,subs="verbatim,quotes"] ---- @@ -843,7 +843,7 @@ created by the implementation of the `getObject()` method in the `ProxyFactoryBe method creates an AOP proxy that wraps a target object. One of the most important benefits of using a `ProxyFactoryBean` or another IoC-aware -class to create AOP proxies is that advices and pointcuts can also be +class to create AOP proxies is that advice and pointcuts can also be managed by IoC. This is a powerful feature, enabling certain approaches that are hard to achieve with other AOP frameworks. For example, an advice may itself reference application objects (besides the target, which should be available in any AOP @@ -901,7 +901,7 @@ to be applied. You can find an example of using this feature in <` element. Again, the following example specifies a `ReflectiveLoadTimeWeaver`: diff --git a/framework-docs/src/docs/asciidoc/core/core-appendix.adoc b/framework-docs/src/docs/asciidoc/core/core-appendix.adoc index 9ecc8477289..488765bd028 100644 --- a/framework-docs/src/docs/asciidoc/core/core-appendix.adoc +++ b/framework-docs/src/docs/asciidoc/core/core-appendix.adoc @@ -1069,7 +1069,7 @@ The following listing shows the `Component` class: private String name; private List components = new ArrayList (); - // mmm, there is no setter method for the 'components' + // there is no setter method for the 'components' public void addComponent(Component component) { this.components.add(component); } @@ -1099,7 +1099,7 @@ The following listing shows the `Component` class: var name: String? = null private val components = ArrayList() - // mmm, there is no setter method for the 'components' + // there is no setter method for the 'components' fun addComponent(component: Component) { this.components.add(component) } diff --git a/framework-docs/src/docs/asciidoc/core/core-beans.adoc b/framework-docs/src/docs/asciidoc/core/core-beans.adoc index d6eec1bd9ac..af3dab8a6c8 100644 --- a/framework-docs/src/docs/asciidoc/core/core-beans.adoc +++ b/framework-docs/src/docs/asciidoc/core/core-beans.adoc @@ -605,7 +605,7 @@ creating a namespace), yet they refer to the same bean. .Java-configuration **** -If you use Javaconfiguration, the `@Bean` annotation can be used to provide aliases. +If you use Java Configuration, the `@Bean` annotation can be used to provide aliases. See <> for details. **** @@ -3981,7 +3981,7 @@ dependency type. The following table summarizes the most important `Aware` inter | <> | `MessageSourceAware` -| Configured strategy for resolving messages (with support for parametrization and +| Configured strategy for resolving messages (with support for parameterization and internationalization). | <> @@ -5020,7 +5020,7 @@ through Java 8's `java.util.Optional`, as the following example shows: As of Spring Framework 5.0, you can also use a `@Nullable` annotation (of any kind in any package -- for example, `javax.annotation.Nullable` from JSR-305) or just leverage -Kotlin builtin null-safety support: +Kotlin built-in null-safety support: [source,java,indent=0,subs="verbatim,quotes",role="primary"] .Java @@ -6324,7 +6324,7 @@ the `@RestController` annotation from Spring MVC is composed of `@Controller` an In addition, composed annotations can optionally redeclare attributes from meta-annotations to allow customization. This can be particularly useful when you want to only expose a subset of the meta-annotation's attributes. For example, Spring's -`@SessionScope` annotation hardcodes the scope name to `session` but still allows +`@SessionScope` annotation hard codes the scope name to `session` but still allows customization of the `proxyMode`. The following listing shows the definition of the `SessionScope` annotation: diff --git a/framework-docs/src/docs/asciidoc/data-access.adoc b/framework-docs/src/docs/asciidoc/data-access.adoc index 4049083688e..49f0f2ce55e 100644 --- a/framework-docs/src/docs/asciidoc/data-access.adoc +++ b/framework-docs/src/docs/asciidoc/data-access.adoc @@ -4188,7 +4188,7 @@ To configure a `DriverManagerDataSource`: . Obtain a connection with `DriverManagerDataSource` as you typically obtain a JDBC connection. -. Specify the fully qualified classname of the JDBC driver so that the `DriverManager` +. Specify the fully qualified class name of the JDBC driver so that the `DriverManager` can load the driver class. . Provide a URL that varies between JDBC drivers. (See the documentation for your driver for the correct value.) @@ -4346,7 +4346,7 @@ javadoc for more details. ==== Using `DataSourceTransactionManager` The `DataSourceTransactionManager` class is a `PlatformTransactionManager` -implementation for single JDBC datasources. It binds a JDBC connection from the +implementation for single JDBC data sources. It binds a JDBC connection from the specified data source to the currently executing thread, potentially allowing for one thread connection per data source. @@ -6966,7 +6966,7 @@ Consider the following query: SELECT id, name, state FROM table WHERE (name, age) IN (('John', 35), ('Ann', 50)) ---- -The preceding query can be parametrized and run as follows: +The preceding query can be parameterized and run as follows: [source,java,indent=0,subs="verbatim,quotes",role="primary"] .Java @@ -7286,7 +7286,7 @@ javadoc for more details. ==== Using `R2dbcTransactionManager` The `R2dbcTransactionManager` class is a `ReactiveTransactionManager` implementation for -single R2DBC datasources. It binds an R2DBC connection from the specified connection factory +single R2DBC data sources. It binds an R2DBC connection from the specified connection factory to the subscriber `Context`, potentially allowing for one subscriber connection for each connection factory. diff --git a/framework-docs/src/docs/asciidoc/integration/cache.adoc b/framework-docs/src/docs/asciidoc/integration/cache.adoc index 765a1c65ad0..af0c885f80a 100644 --- a/framework-docs/src/docs/asciidoc/integration/cache.adoc +++ b/framework-docs/src/docs/asciidoc/integration/cache.adoc @@ -140,9 +140,9 @@ Since caches are essentially key-value stores, each invocation of a cached metho needs to be translated into a suitable key for cache access. The caching abstraction uses a simple `KeyGenerator` based on the following algorithm: -* If no params are given, return `SimpleKey.EMPTY`. -* If only one param is given, return that instance. -* If more than one param is given, return a `SimpleKey` that contains all parameters. +* If no parameters are given, return `SimpleKey.EMPTY`. +* If only one parameter is given, return that instance. +* If more than one parameter is given, return a `SimpleKey` that contains all parameters. This approach works well for most use-cases, as long as parameters have natural keys and implement valid `hashCode()` and `equals()` methods. If that is not the case, diff --git a/framework-docs/src/docs/asciidoc/testing/spring-mvc-test-framework.adoc b/framework-docs/src/docs/asciidoc/testing/spring-mvc-test-framework.adoc index 6d0648cd539..196212377fa 100644 --- a/framework-docs/src/docs/asciidoc/testing/spring-mvc-test-framework.adoc +++ b/framework-docs/src/docs/asciidoc/testing/spring-mvc-test-framework.adoc @@ -961,7 +961,7 @@ leads to a number of additional challenges: * Testing can become slow, since each test would need to ensure that the database is in the correct state. * Since our database needs to be in a specific state, we cannot run tests in parallel. -* Performing assertions on such items as auto-generated ids, timestamps, and others can +* Performing assertions on such items as auto-generated IDs, timestamps, and others can be difficult. These challenges do not mean that we should abandon end-to-end integration testing diff --git a/framework-docs/src/docs/asciidoc/web/webflux-webclient.adoc b/framework-docs/src/docs/asciidoc/web/webflux-webclient.adoc index c93e112b936..267a690d628 100644 --- a/framework-docs/src/docs/asciidoc/web/webflux-webclient.adoc +++ b/framework-docs/src/docs/asciidoc/web/webflux-webclient.adoc @@ -1196,7 +1196,7 @@ response individually, and instead wait for the combined result: The above is merely one example. There are lots of other patterns and operators for putting together a reactive pipeline that makes many remote calls, potentially some nested, -inter-dependent, without ever blocking until the end. +interdependent, without ever blocking until the end. [NOTE] ==== diff --git a/framework-docs/src/docs/asciidoc/web/webmvc-view.adoc b/framework-docs/src/docs/asciidoc/web/webmvc-view.adoc index 6e8ce837342..2b0b03c1399 100644 --- a/framework-docs/src/docs/asciidoc/web/webmvc-view.adoc +++ b/framework-docs/src/docs/asciidoc/web/webmvc-view.adoc @@ -288,7 +288,7 @@ as the value for the `fieldType` parameter. The parameters to any of the above macros have consistent meanings: -* `path`: The name of the field to bind to (ie "command.name") +* `path`: The name of the field to bind to (for example, "command.name") * `options`: A `Map` of all the available values that can be selected from in the input field. The keys to the map represent the values that are POSTed back from the form and bound to the command object. Map objects stored against the keys are the labels diff --git a/framework-docs/src/docs/asciidoc/web/webmvc.adoc b/framework-docs/src/docs/asciidoc/web/webmvc.adoc index 4bf1d8f69f0..fb8c2a12cca 100644 --- a/framework-docs/src/docs/asciidoc/web/webmvc.adoc +++ b/framework-docs/src/docs/asciidoc/web/webmvc.adoc @@ -978,7 +978,7 @@ The following table describes the properties `CookieLocaleResolver`: | Property | Default | Description | `cookieName` -| classname + LOCALE +| class name + LOCALE | The name of the cookie | `cookieMaxAge` diff --git a/framework-docs/src/docs/asciidoc/web/websocket-intro.adoc b/framework-docs/src/docs/asciidoc/web/websocket-intro.adoc index 9392a80a790..0c2b0968585 100644 --- a/framework-docs/src/docs/asciidoc/web/websocket-intro.adoc +++ b/framework-docs/src/docs/asciidoc/web/websocket-intro.adoc @@ -84,7 +84,7 @@ In the absence of that, they need to come up with their own conventions. == When to Use WebSockets WebSockets can make a web page be dynamic and interactive. However, in many cases, -a combination of Ajax and HTTP streaming or long polling can provide a simple and +a combination of AJAX and HTTP streaming or long polling can provide a simple and effective solution. For example, news, mail, and social feeds need to update dynamically, but it may be