DATAJDBC-290 - Applied review feedback.

Added "since" information fro new and deprecated classes.

Original pull request: #104.
This commit is contained in:
Jens Schauder
2018-12-14 12:46:17 +01:00
parent 3b394e22d4
commit df8bedd033
4 changed files with 9 additions and 6 deletions

View File

@@ -1,20 +1,22 @@
package org.springframework.data.jdbc.repository;
import org.springframework.jdbc.core.ResultSetExtractor;
import org.springframework.jdbc.core.RowMapper;
import org.springframework.lang.Nullable;
/**
* Configures a {@link org.springframework.jdbc.core.RowMapper} or a {@link ResultSetExtractor} for each type to be used
* for extracting entities of that type from a {@link java.sql.ResultSet}.
* Configures a {@link org.springframework.jdbc.core.RowMapper} for each type to be used for extracting entities of that
* type from a {@link java.sql.ResultSet}.
*
* @author Jens Schauder
* @author Evgeni Dimitrov
* @since 1.1
*/
public interface QueryMappingConfiguration {
@Nullable
<T> RowMapper<? extends T> getRowMapper(Class<T> type);
default <T> RowMapper<? extends T> getRowMapper(Class<T> type) {
return null;
}
/**
* An immutable empty instance that will return {@literal null} for all arguments.

View File

@@ -22,7 +22,7 @@ import org.springframework.lang.Nullable;
* A map from a type to a {@link RowMapper} to be used for extracting that type from {@link java.sql.ResultSet}s.
*
* @author Jens Schauder
* @deprecated use {@link QueryMappingConfiguration}
* @deprecated since 1.1 use {@link QueryMappingConfiguration}
*/
@Deprecated
public interface RowMapperMap extends QueryMappingConfiguration {

View File

@@ -27,7 +27,7 @@ import org.springframework.util.Assert;
* A {@link RowMapperMap} that allows for registration of {@link RowMapper}s via a fluent Api.
*
* @author Jens Schauder
* @deprecated Use {@link DefaultQueryMappingConfiguration} instead.
* @deprecated Since 1.1 use {@link DefaultQueryMappingConfiguration} instead.
*/
@Deprecated
public class ConfigurableRowMapperMap implements RowMapperMap {

View File

@@ -15,6 +15,7 @@ import org.springframework.util.Assert;
*
* @author Jens Schauder
* @author Evgeni Dimitrov
* @since 1.1
*/
public class DefaultQueryMappingConfiguration implements QueryMappingConfiguration {