DATAJDBC-138 - Polishing.

Moved all types from mapping.model into model to align with the setup of other Spring Data modules.

Original pull request: #67.
This commit is contained in:
Oliver Gierke
2018-05-18 16:34:08 +02:00
parent bd7401b665
commit e4de5701d4
56 changed files with 112 additions and 105 deletions

View File

@@ -25,7 +25,7 @@ import java.util.Collections;
import org.junit.Test;
import org.springframework.data.jdbc.core.FunctionCollector.CombinedDataAccessException;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
/**
* Unit tests for {@link CascadingDataAccessStrategy}.

View File

@@ -26,8 +26,8 @@ import java.util.HashMap;
import org.junit.Test;
import org.mockito.ArgumentCaptor;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
import org.springframework.jdbc.core.namedparam.SqlParameterSource;
import org.springframework.jdbc.support.KeyHolder;

View File

@@ -27,10 +27,10 @@ import org.mockito.ArgumentCaptor;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.conversion.DbAction;
import org.springframework.data.jdbc.core.conversion.DbAction.Insert;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.jdbc.core.conversion.JdbcPropertyPath;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
/**

View File

@@ -41,10 +41,10 @@ import org.springframework.core.convert.support.DefaultConversionService;
import org.springframework.core.convert.support.GenericConversionService;
import org.springframework.data.annotation.Id;
import org.springframework.data.convert.Jsr310Converters;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
import org.springframework.util.Assert;

View File

@@ -31,7 +31,7 @@ import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.testing.TestConfiguration;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.rules.SpringClassRule;

View File

@@ -27,7 +27,7 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentCaptor;
import org.mockito.Mockito;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
import org.springframework.data.jdbc.mybatis.MyBatisContext;
import org.springframework.data.jdbc.mybatis.MyBatisDataAccessStrategy;
import org.springframework.data.mapping.PropertyPath;

View File

@@ -24,9 +24,9 @@ import java.util.function.Consumer;
import org.assertj.core.api.SoftAssertions;
import org.junit.Test;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.mapping.PropertyPath;
/**

View File

@@ -20,10 +20,10 @@ import static org.assertj.core.api.Assertions.*;
import org.assertj.core.api.SoftAssertions;
import org.junit.Test;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.mapping.PropertyPath;
/**

View File

@@ -24,10 +24,10 @@ import org.assertj.core.api.SoftAssertions;
import org.junit.Before;
import org.junit.Test;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.model.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.mapping.PropertyPath;
/**

View File

@@ -25,7 +25,7 @@ import org.mockito.junit.MockitoJUnitRunner;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.conversion.AggregateChange.Kind;
import org.springframework.data.jdbc.core.conversion.DbAction.Delete;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
/**
* Unit tests for the {@link JdbcEntityDeleteWriter}

View File

@@ -34,7 +34,7 @@ import org.springframework.data.jdbc.core.conversion.AggregateChange.Kind;
import org.springframework.data.jdbc.core.conversion.DbAction.Delete;
import org.springframework.data.jdbc.core.conversion.DbAction.Insert;
import org.springframework.data.jdbc.core.conversion.DbAction.Update;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
/**
* Unit tests for the {@link JdbcEntityWriter}

View File

@@ -13,13 +13,15 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.data.jdbc.core.mapping.model;
package org.springframework.data.jdbc.core.mapping;
import static org.assertj.core.api.Assertions.*;
import org.junit.Test;
import org.springframework.data.annotation.Id;
import org.springframework.data.domain.Persistable;
import org.springframework.data.jdbc.core.mapping.BasicJdbcPersistentEntityInformation;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.lang.Nullable;
/**

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.data.jdbc.core.mapping.model;
package org.springframework.data.jdbc.core.mapping;
import static org.assertj.core.api.Assertions.*;
@@ -24,6 +24,11 @@ import java.time.ZonedDateTime;
import java.util.Date;
import org.junit.Test;
import org.springframework.data.jdbc.core.mapping.BasicJdbcPersistentProperty;
import org.springframework.data.jdbc.core.mapping.Column;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentProperty;
import org.springframework.data.mapping.PropertyHandler;
/**

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.data.jdbc.core.mapping.model;
package org.springframework.data.jdbc.core.mapping;
import static org.assertj.core.api.Assertions.*;
@@ -24,6 +24,9 @@ import java.util.List;
import org.junit.Test;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.DelimiterNamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
/**
* Unit tests for the {@link DelimiterNamingStrategy}.

View File

@@ -13,13 +13,14 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.data.jdbc.core.mapping.model;
package org.springframework.data.jdbc.core.mapping;
import static org.assertj.core.api.Assertions.*;
import java.util.List;
import org.junit.Test;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.mapping.PropertyPath;
/**

View File

@@ -13,11 +13,15 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.data.jdbc.mapping.model;
package org.springframework.data.jdbc.core.mapping;
import static org.assertj.core.api.Assertions.*;
import org.junit.Test;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntityImpl;
import org.springframework.data.jdbc.core.mapping.Table;
/**
* Unit tests for {@link JdbcPersistentEntityImpl}.

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.data.jdbc.mapping.model;
package org.springframework.data.jdbc.core.mapping;
import static org.assertj.core.api.Assertions.*;
@@ -22,7 +22,10 @@ import java.util.List;
import org.junit.Test;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.mapping.model.JdbcPersistentEntityImplUnitTests.DummySubEntity;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntity;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.JdbcPersistentEntityImplUnitTests.DummySubEntity;
/**
* Unit tests for the {@link NamingStrategy}.

View File

@@ -31,7 +31,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Import;
import org.springframework.data.jdbc.core.DataAccessStrategy;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories;
import org.springframework.data.jdbc.testing.TestConfiguration;
import org.springframework.data.repository.CrudRepository;

View File

@@ -29,7 +29,7 @@ import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories;
import org.springframework.data.jdbc.repository.support.JdbcRepositoryFactory;
import org.springframework.data.jdbc.repository.support.SimpleJdbcRepository;

View File

@@ -36,6 +36,7 @@ import org.springframework.context.ApplicationEventPublisher;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.DefaultDataAccessStrategy;
import org.springframework.data.jdbc.core.SqlGeneratorSource;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.event.AfterDeleteEvent;
import org.springframework.data.jdbc.core.mapping.event.AfterLoadEvent;
import org.springframework.data.jdbc.core.mapping.event.AfterSaveEvent;
@@ -43,7 +44,6 @@ import org.springframework.data.jdbc.core.mapping.event.BeforeDeleteEvent;
import org.springframework.data.jdbc.core.mapping.event.BeforeSaveEvent;
import org.springframework.data.jdbc.core.mapping.event.Identifier;
import org.springframework.data.jdbc.core.mapping.event.JdbcEvent;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.repository.support.JdbcRepositoryFactory;
import org.springframework.data.jdbc.repository.support.SimpleJdbcRepository;
import org.springframework.data.repository.CrudRepository;

View File

@@ -39,7 +39,7 @@ import org.springframework.data.annotation.LastModifiedBy;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.data.auditing.DateTimeProvider;
import org.springframework.data.domain.AuditorAware;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.repository.CrudRepository;
/**

View File

@@ -24,7 +24,7 @@ import java.text.NumberFormat;
import org.junit.Before;
import org.junit.Test;
import org.springframework.data.jdbc.core.DataAccessStrategy;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.repository.RowMapperMap;
import org.springframework.data.jdbc.repository.config.ConfigurableRowMapperMap;
import org.springframework.data.jdbc.repository.query.Query;

View File

@@ -28,7 +28,7 @@ import org.springframework.context.ApplicationEventPublisher;
import org.springframework.data.annotation.Id;
import org.springframework.data.jdbc.core.DataAccessStrategy;
import org.springframework.data.jdbc.core.DefaultDataAccessStrategy;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.repository.RowMapperMap;
import org.springframework.data.repository.CrudRepository;
import org.springframework.test.util.ReflectionTestUtils;

View File

@@ -28,9 +28,9 @@ import org.springframework.context.annotation.Configuration;
import org.springframework.data.jdbc.core.DataAccessStrategy;
import org.springframework.data.jdbc.core.DefaultDataAccessStrategy;
import org.springframework.data.jdbc.core.SqlGeneratorSource;
import org.springframework.data.jdbc.core.mapping.model.ConversionCustomizer;
import org.springframework.data.jdbc.core.mapping.model.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.model.NamingStrategy;
import org.springframework.data.jdbc.core.mapping.ConversionCustomizer;
import org.springframework.data.jdbc.core.mapping.JdbcMappingContext;
import org.springframework.data.jdbc.core.mapping.NamingStrategy;
import org.springframework.data.jdbc.repository.support.JdbcRepositoryFactory;
import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
import org.springframework.jdbc.core.namedparam.NamedParameterJdbcTemplate;