Skip to content

Commit bc866e3

Browse files
committed
Polishing.
Add missing deprecation annotation. Fix since tags. See #1053 Original pull request: #1060.
1 parent 3cd25ee commit bc866e3

File tree

4 files changed

+10
-8
lines changed

4 files changed

+10
-8
lines changed

spring-data-relational/src/main/java/org/springframework/data/relational/core/mapping/event/AbstractRelationalEventListener.java

+2
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ protected void onAfterSave(AfterSaveEvent<E> event) {
114114
* @param event will never be {@literal null}.
115115
* @deprecated use {@link #onAfterConvert(AfterConvertEvent)} instead.
116116
*/
117+
@Deprecated
117118
protected void onAfterLoad(AfterLoadEvent<E> event) {
118119

119120
if (LOG.isDebugEnabled()) {
@@ -125,6 +126,7 @@ protected void onAfterLoad(AfterLoadEvent<E> event) {
125126
* Captures {@link AfterConvertEvent}.
126127
*
127128
* @param event will never be {@literal null}.
129+
* @since 2.3
128130
*/
129131
protected void onAfterConvert(AfterConvertEvent<E> event) {
130132

spring-data-relational/src/main/java/org/springframework/data/relational/core/mapping/event/AfterConvertCallback.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2019-2021 the original author or authors.
2+
* Copyright 2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -21,7 +21,7 @@
2121
* An {@link EntityCallback} that gets invoked after an aggregate was converted from the database into an entity.
2222
*
2323
* @author Jens Schauder
24-
* @since 2.6
24+
* @since 2.3
2525
*/
2626
@FunctionalInterface
2727
public interface AfterConvertCallback<T> extends EntityCallback<T> {

spring-data-relational/src/main/java/org/springframework/data/relational/core/mapping/event/AfterConvertEvent.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2017-2021 the original author or authors.
2+
* Copyright 2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -16,11 +16,11 @@
1616
package org.springframework.data.relational.core.mapping.event;
1717

1818
/**
19-
* Gets published after instantiation and setting of all the properties of an entity. This allows to do some
20-
* postprocessing of entities if the entities are mutable. For immutable entities use {@link AfterConvertCallback}.
19+
* Gets published after instantiation and setting of all the properties of an entity. If you want to mutate an entity
20+
* after loading, use {@link AfterConvertCallback}.
2121
*
2222
* @author Jens Schauder
23-
* @since 2.6
23+
* @since 2.3
2424
*/
2525
public class AfterConvertEvent<E> extends RelationalEventWithEntity<E> {
2626

spring-data-relational/src/main/java/org/springframework/data/relational/core/mapping/event/AfterLoadEvent.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
package org.springframework.data.relational.core.mapping.event;
1717

1818
/**
19-
* Gets published after instantiation and setting of all the properties of an entity. This allows to do some
20-
* postprocessing of entities if the entities are mutable. For immutable entities use {@link AfterLoadCallback}.
19+
* Gets published after instantiation and setting of all the properties of an entity. If you want to mutate an entity
20+
* after loading, use {@link AfterConvertCallback}.
2121
*
2222
* @author Jens Schauder
2323
* @deprecated Use {@link AfterConvertEvent} instead.

0 commit comments

Comments
 (0)