Skip to content

Commit 7a8a9c7

Browse files
committed
Javadoc fixes
Issue: SPR-13763
1 parent 1585a82 commit 7a8a9c7

File tree

1 file changed

+25
-22
lines changed

1 file changed

+25
-22
lines changed

spring-context/src/main/java/org/springframework/context/event/EventListener.java

+25-22
Original file line numberDiff line numberDiff line change
@@ -30,31 +30,34 @@
3030
*
3131
* <p>If an annotated method supports a single event type, the method may
3232
* declare a single parameter that reflects the event type to listen to.
33-
* If an annotated method supports multiple event types, this annotation may
34-
* refer to one or more supported event types using the {@code classes}
35-
* attribute. See {@link #classes} for further details.
33+
* If an annotated method supports multiple event types, this annotation
34+
* may refer to one or more supported event types using the {@code classes}
35+
* attribute. See the {@link #classes} javadoc for further details.
3636
*
3737
* <p>Events can be {@link ApplicationEvent} instances as well as arbitrary
3838
* objects.
3939
*
40-
* <p>Processing of {@code @EventListener} annotations is performed via the
41-
* {@link EventListenerMethodProcessor} which is registered automatically
42-
* when using Java config or manually via the {@code <context:annotation-driven/>}
40+
* <p>Processing of {@code @EventListener} annotations is performed via
41+
* the internal {@link EventListenerMethodProcessor} bean which gets
42+
* registered automatically when using Java config or manually via the
43+
* {@code <context:annotation-config/>} or {@code <context:component-scan/>}
4344
* element when using XML config.
4445
*
45-
* <p>Annotated methods may have a non-{@code void} return type. When they do,
46-
* the result of the method invocation is sent as a new event. If the return type
47-
* is either an array or a collection, each element is sent as a new event.
46+
* <p>Annotated methods may have a non-{@code void} return type. When they
47+
* do, the result of the method invocation is sent as a new event. If the
48+
* return type is either an array or a collection, each element is sent
49+
* as a new individual event.
4850
*
49-
* <p>It is also possible to define the order in which listeners for a certain
50-
* event are invoked. To do so, add Spring's common
51+
* <p>It is also possible to define the order in which listeners for a
52+
* certain event are to be invoked. To do so, add Spring's common
5153
* {@link org.springframework.core.annotation.Order @Order} annotation
52-
* alongside this annotation.
54+
* alongside this event listener annotation.
5355
*
54-
* <p>While it is possible for an event listener to declare that it throws arbitrary
55-
* exception types, any checked exceptions thrown from an event listener will be
56-
* wrapped in an {@link java.lang.reflect.UndeclaredThrowableException} since
57-
* the caller can only handle runtime exceptions.
56+
* <p>While it is possible for an event listener to declare that it
57+
* throws arbitrary exception types, any checked exceptions thrown
58+
* from an event listener will be wrapped in an
59+
* {@link java.lang.reflect.UndeclaredThrowableException}
60+
* since the event publisher can only handle runtime exceptions.
5861
*
5962
* @author Stephane Nicoll
6063
* @since 4.2
@@ -73,17 +76,17 @@
7376

7477
/**
7578
* The event classes that this listener handles.
76-
* <p>If this attribute is specified with a single value, the annotated
77-
* method may optionally accept a single parameter. However, if this
78-
* attribute is specified with multiple values, the annotated method
79-
* must <em>not</em> declare any parameters.
79+
* <p>If this attribute is specified with a single value, the
80+
* annotated method may optionally accept a single parameter.
81+
* However, if this attribute is specified with multiple values,
82+
* the annotated method must <em>not</em> declare any parameters.
8083
*/
8184
@AliasFor("value")
8285
Class<?>[] classes() default {};
8386

8487
/**
85-
* Spring Expression Language (SpEL) attribute used for making the event
86-
* handling conditional.
88+
* Spring Expression Language (SpEL) attribute used for making the
89+
* event handling conditional.
8790
* <p>Default is "", meaning the event is always handled.
8891
*/
8992
String condition() default "";

0 commit comments

Comments
 (0)