From 62d73696070d17f714ee0f4b31f5c61f3360755c Mon Sep 17 00:00:00 2001 From: Sam Brannen Date: Wed, 14 Oct 2009 22:06:51 +0000 Subject: [PATCH] JavaDoc polishing --- .../context/annotation/Bean.java | 23 ++++++++++--------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/org.springframework.context/src/main/java/org/springframework/context/annotation/Bean.java b/org.springframework.context/src/main/java/org/springframework/context/annotation/Bean.java index 96f1b778f0e..ad45ce9ed89 100644 --- a/org.springframework.context/src/main/java/org/springframework/context/annotation/Bean.java +++ b/org.springframework.context/src/main/java/org/springframework/context/annotation/Bean.java @@ -31,22 +31,23 @@ import org.springframework.beans.factory.annotation.Autowire; * as follows: * *

The Bean annotation does not provide attributes for scope, primary or lazy. Rather, - * it should be used in conjunction with {@link Scope}, {@link Primary} and {@link Lazy} - * annotations to acheive the same semantics. + * it should be used in conjunction with {@link Scope @Scope}, + * {@link Primary @Primary}, and {@link Lazy @Lazy} annotations to achieve the + * same semantics. * *

While a {@link #name()} attribute is available, the default strategy for determining * the name of a bean is to use the name of the Bean method. This is convenient and * intuitive, but if explicit naming is desired, the {@link #name()} attribute may be used. * Also note that {@link #name()} accepts an array of strings. This is in order to allow - * for specifying multiple names (aka aliases) for a single bean. + * for specifying multiple names (i.e., aliases) for a single bean. * *

Constraints

* * *

Usage

@@ -65,7 +66,7 @@ import org.springframework.beans.factory.annotation.Autowire; * @see Scope * @see Value */ -@Target({ElementType.METHOD, ElementType.ANNOTATION_TYPE}) +@Target( { ElementType.METHOD, ElementType.ANNOTATION_TYPE }) @Retention(RetentionPolicy.RUNTIME) @Documented public @interface Bean { @@ -90,13 +91,13 @@ public @interface Bean { String initMethod() default ""; /** - * The optional name of a method to call on the bean instance during upon closing the + * The optional name of a method to call on the bean instance upon closing the * application context, for example a {@literal close()} method on a {@literal DataSource}. - * The method must have no arguments, but may throw any exception. + * The method must have no arguments but may throw any exception. *

Note: Only invoked on beans whose lifecycle is under the full control of the - * factory which is always the case for singletons, but not guaranteed - * for any other scope. - * see {@link org.springframework.context.ConfigurableApplicationContext#close()} + * factory, which is always the case for singletons but not guaranteed + * for any other scope. + * @see {@link org.springframework.context.ConfigurableApplicationContext#close()} */ String destroyMethod() default "";