From 92025ef7997aff22efb331a15373bda50cc81a3e Mon Sep 17 00:00:00 2001 From: Jan Ouwens Date: Fri, 6 Dec 2024 08:51:37 +0100 Subject: [PATCH] Re-organizes vintage packages --- .../RecordInstanceCreatorTest.java | 2 +- .../factories}/RecordFallbackFactoryTest.java | 9 +++-- .../RecordObjectAccessorCopyingTest.java | 2 +- .../RecordObjectAccessorScramblingTest.java | 10 +++--- .../reflection}/RecordObjectAccessorTest.java | 6 ++-- .../SealedTypesFallbackFactoryTest.java | 9 +++-- .../ConfiguredEqualsVerifier.java | 4 +-- .../api/SingleTypeEqualsVerifierApi.java | 3 +- .../checkers/AbstractDelegationChecker.java | 9 ++--- .../internal/checkers/ExamplesChecker.java | 2 +- .../internal/checkers/FieldsChecker.java | 2 +- .../internal/checkers/HierarchyChecker.java | 2 +- .../MapEntryHashCodeRequirementChecker.java | 2 +- .../internal/checkers/RecordChecker.java | 2 +- .../checkers/fieldchecks/ArrayFieldCheck.java | 2 +- .../fieldchecks/BigDecimalFieldCheck.java | 2 +- .../fieldchecks/FloatAndDoubleFieldCheck.java | 2 +- .../fieldchecks/JpaLazyGetterFieldCheck.java | 4 +-- .../fieldchecks/MutableStateFieldCheck.java | 2 +- .../NullPointerExceptionFieldCheck.java | 2 +- .../fieldchecks/ReflexivityFieldCheck.java | 4 +-- .../fieldchecks/SignificantFieldCheck.java | 2 +- .../fieldchecks/StringFieldCheck.java | 4 +-- .../fieldchecks/SymmetryFieldCheck.java | 2 +- .../fieldchecks/TransientFieldsCheck.java | 2 +- .../fieldchecks/TransitivityFieldCheck.java | 2 +- .../instantiation/InstanceCreator.java | 2 +- .../JavaApiPrefabValues.java | 12 ++++--- .../instantiation/SubjectCreator.java | 2 +- .../instantiation/ValueProvider.java | 2 +- .../vintage}/FactoryCache.java | 5 ++- .../vintage}/PrefabValuesApi.java | 12 +++---- .../vintage}/VintageValueProvider.java | 8 ++--- .../factories/AbstractGenericFactory.java | 4 +-- .../prefabvalues/factories/CopyFactory.java | 4 +-- .../factories/EnumMapFactory.java | 4 +-- .../factories/EnumSetFactory.java | 4 +-- .../factories/ExternalFactory.java | 10 +++--- .../prefabvalues/factories/Factories.java | 2 +- .../factories/FallbackFactory.java | 6 ++-- .../prefabvalues/factories/MapFactory.java | 4 +-- .../factories/PrefabValueFactory.java | 4 +-- .../prefabvalues/factories/SimpleFactory.java | 4 +-- .../factories/SimpleGenericFactory.java | 4 +-- .../factoryproviders/AwtFactoryProvider.java | 10 +++--- .../factoryproviders/FactoryProvider.java | 7 ++++ .../GuavaFactoryProvider.java | 13 +++----- .../JavaFxFactoryProvider.java | 15 +++++---- .../JavaxFactoryProvider.java | 6 ++-- .../factoryproviders/JodaFactoryProvider.java | 6 ++-- .../factoryproviders/RmiFactoryProvider.java | 6 ++-- .../vintage/reflection}/ClassAccessor.java | 4 +-- .../vintage/reflection}/FieldModifier.java | 4 +-- .../reflection}/InPlaceObjectAccessor.java | 4 +-- .../vintage/reflection}/ObjectAccessor.java | 4 +-- .../reflection}/RecordObjectAccessor.java | 4 +-- .../internal/reflection/FieldCache.java | 2 +- .../factoryproviders/FactoryProvider.java | 7 ---- .../equalsverifier/internal/util/Context.java | 11 ++++--- .../internal/util/Validations.java | 7 ++-- .../architecture/ArchitectureTest.java | 33 +++++++------------ .../instantiation/InstanceCreatorTest.java | 2 +- .../instantiation/SubjectCreatorTest.java | 2 +- .../vintage}/FactoryCacheTest.java | 6 ++-- .../vintage}/PrefabValuesApiTest.java | 2 +- .../VintageValueProviderCreatorTest.java | 5 ++- .../vintage}/VintageValueProviderTest.java | 7 ++-- .../factories/AbstractGenericFactoryTest.java | 4 +-- .../prefabvalues/factories/FactoriesTest.java | 2 +- .../factories/FallbackFactoryTest.java | 8 ++--- .../factories/MapFactoryTest.java | 6 ++-- .../factories/SimpleFactoryTest.java | 2 +- .../factories/SimpleGenericFactoryTest.java | 6 ++-- .../JavaFxFactoryProviderTest.java | 10 +++--- .../reflection}/ClassAccessorTest.java | 10 +++--- .../reflection}/FieldModifierTest.java | 2 +- .../InPlaceObjectAccessorCopyingTest.java | 2 +- .../InPlaceObjectAccessorScramblingTest.java | 10 +++--- .../InPlaceObjectAccessorTest.java | 2 +- .../testhelpers/FactoryCacheFactory.java | 4 +-- .../jar/helper/JarAsserter.java | 2 +- 81 files changed, 207 insertions(+), 217 deletions(-) rename equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/{reflection => }/instantiation/RecordInstanceCreatorTest.java (93%) rename equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/prefabvalues/factories}/RecordFallbackFactoryTest.java (78%) rename equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/RecordObjectAccessorCopyingTest.java (96%) rename equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/RecordObjectAccessorScramblingTest.java (84%) rename equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/RecordObjectAccessorTest.java (94%) rename equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/prefabvalues/factories}/SealedTypesFallbackFactoryTest.java (85%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => }/instantiation/InstanceCreator.java (97%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/JavaApiPrefabValues.java (98%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => }/instantiation/SubjectCreator.java (99%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => }/instantiation/ValueProvider.java (96%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation/vintage}/FactoryCache.java (93%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{util => instantiation/vintage}/PrefabValuesApi.java (84%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection/instantiation => instantiation/vintage}/VintageValueProvider.java (95%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/AbstractGenericFactory.java (94%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/CopyFactory.java (86%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/EnumMapFactory.java (89%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/EnumSetFactory.java (88%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/ExternalFactory.java (73%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/Factories.java (94%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/FallbackFactory.java (92%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/MapFactory.java (91%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/PrefabValueFactory.java (83%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/SimpleFactory.java (80%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/SimpleGenericFactory.java (91%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java (83%) create mode 100644 equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/FactoryProvider.java rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java (92%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java (86%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java (70%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java (81%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java (61%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/ClassAccessor.java (96%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/FieldModifier.java (95%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/InPlaceObjectAccessor.java (90%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/ObjectAccessor.java (95%) rename equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/RecordObjectAccessor.java (93%) delete mode 100644 equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/FactoryProvider.java rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => }/instantiation/InstanceCreatorTest.java (96%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => }/instantiation/SubjectCreatorTest.java (99%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation/vintage}/FactoryCacheTest.java (89%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{util => instantiation/vintage}/PrefabValuesApiTest.java (81%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/instantiation => instantiation/vintage}/VintageValueProviderCreatorTest.java (96%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/instantiation => instantiation/vintage}/VintageValueProviderTest.java (96%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java (90%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/FactoriesTest.java (75%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/FallbackFactoryTest.java (93%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/MapFactoryTest.java (93%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/SimpleFactoryTest.java (89%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java (93%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection => instantiation}/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java (86%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/ClassAccessorTest.java (92%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/FieldModifierTest.java (95%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/InPlaceObjectAccessorCopyingTest.java (97%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/InPlaceObjectAccessorScramblingTest.java (93%) rename equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/{reflection/vintage => instantiation/vintage/reflection}/InPlaceObjectAccessorTest.java (91%) diff --git a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/RecordInstanceCreatorTest.java b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/RecordInstanceCreatorTest.java similarity index 93% rename from equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/RecordInstanceCreatorTest.java rename to equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/RecordInstanceCreatorTest.java index 8bced9fd4..69a0ea94a 100644 --- a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/RecordInstanceCreatorTest.java +++ b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/RecordInstanceCreatorTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordFallbackFactoryTest.java b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/RecordFallbackFactoryTest.java similarity index 78% rename from equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordFallbackFactoryTest.java rename to equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/RecordFallbackFactoryTest.java index e1f4ed91e..4b003c695 100644 --- a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordFallbackFactoryTest.java +++ b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/RecordFallbackFactoryTest.java @@ -1,15 +1,14 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotSame; import java.util.LinkedHashSet; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.FallbackFactory; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.objenesis.Objenesis; diff --git a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorCopyingTest.java b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorCopyingTest.java similarity index 96% rename from equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorCopyingTest.java rename to equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorCopyingTest.java index 25c904414..09720656a 100644 --- a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorCopyingTest.java +++ b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorCopyingTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotSame; diff --git a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorScramblingTest.java b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorScramblingTest.java similarity index 84% rename from equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorScramblingTest.java rename to equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorScramblingTest.java index 830186672..171b5dcc9 100644 --- a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorScramblingTest.java +++ b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorScramblingTest.java @@ -1,15 +1,15 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertNotSame; import java.lang.reflect.Constructor; import java.util.LinkedHashSet; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.objenesis.ObjenesisStd; diff --git a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorTest.java b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorTest.java similarity index 94% rename from equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorTest.java rename to equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorTest.java index dbcbb904f..6934991b4 100644 --- a/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessorTest.java +++ b/equalsverifier-16/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessorTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import static org.junit.jupiter.api.Assertions.assertSame; import static org.junit.jupiter.api.Assertions.assertTrue; @@ -7,10 +7,10 @@ import java.util.LinkedHashSet; import java.util.Objects; import nl.jqno.equalsverifier.internal.exceptions.ReflectionException; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Instantiator; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import nl.jqno.equalsverifier.internal.testhelpers.ExpectedException; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/SealedTypesFallbackFactoryTest.java b/equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SealedTypesFallbackFactoryTest.java similarity index 85% rename from equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/SealedTypesFallbackFactoryTest.java rename to equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SealedTypesFallbackFactoryTest.java index 0babdd4c1..88b60c153 100644 --- a/equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/SealedTypesFallbackFactoryTest.java +++ b/equalsverifier-17/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SealedTypesFallbackFactoryTest.java @@ -1,16 +1,15 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotSame; import java.util.LinkedHashSet; import java.util.Objects; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.FallbackFactory; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.objenesis.Objenesis; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/ConfiguredEqualsVerifier.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/ConfiguredEqualsVerifier.java index 018445a66..6d3ee7001 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/ConfiguredEqualsVerifier.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/ConfiguredEqualsVerifier.java @@ -9,10 +9,10 @@ import nl.jqno.equalsverifier.api.EqualsVerifierApi; import nl.jqno.equalsverifier.api.MultipleTypeEqualsVerifierApi; import nl.jqno.equalsverifier.api.SingleTypeEqualsVerifierApi; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.PrefabValuesApi; import nl.jqno.equalsverifier.internal.reflection.PackageScanner; import nl.jqno.equalsverifier.internal.util.ListBuilders; -import nl.jqno.equalsverifier.internal.util.PrefabValuesApi; import nl.jqno.equalsverifier.internal.util.Validations; import org.objenesis.Objenesis; import org.objenesis.ObjenesisStd; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/api/SingleTypeEqualsVerifierApi.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/api/SingleTypeEqualsVerifierApi.java index c09b94d68..e87acdac8 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/api/SingleTypeEqualsVerifierApi.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/api/SingleTypeEqualsVerifierApi.java @@ -9,7 +9,8 @@ import nl.jqno.equalsverifier.Warning; import nl.jqno.equalsverifier.internal.checkers.*; import nl.jqno.equalsverifier.internal.exceptions.MessagingException; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.PrefabValuesApi; import nl.jqno.equalsverifier.internal.reflection.FieldCache; import nl.jqno.equalsverifier.internal.util.*; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/AbstractDelegationChecker.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/AbstractDelegationChecker.java index 41eb3ef35..63b3cb93c 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/AbstractDelegationChecker.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/AbstractDelegationChecker.java @@ -4,12 +4,9 @@ import java.lang.reflect.Field; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; -import nl.jqno.equalsverifier.internal.reflection.ClassProbe; -import nl.jqno.equalsverifier.internal.reflection.FieldIterable; -import nl.jqno.equalsverifier.internal.reflection.Tuple; -import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; -import nl.jqno.equalsverifier.internal.reflection.instantiation.ValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; +import nl.jqno.equalsverifier.internal.reflection.*; import nl.jqno.equalsverifier.internal.util.*; public class AbstractDelegationChecker implements Checker { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/ExamplesChecker.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/ExamplesChecker.java index 3195e1be8..ba1e91f9f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/ExamplesChecker.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/ExamplesChecker.java @@ -9,8 +9,8 @@ import java.util.Objects; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; import nl.jqno.equalsverifier.internal.exceptions.AssertionException; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldIterable; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.*; public class ExamplesChecker implements Checker { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/FieldsChecker.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/FieldsChecker.java index 263519800..2aab34ba8 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/FieldsChecker.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/FieldsChecker.java @@ -3,11 +3,11 @@ import java.util.function.Predicate; import nl.jqno.equalsverifier.Warning; import nl.jqno.equalsverifier.internal.checkers.fieldchecks.*; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; import nl.jqno.equalsverifier.internal.reflection.TypeTag; import nl.jqno.equalsverifier.internal.reflection.annotations.AnnotationCache; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Configuration; import nl.jqno.equalsverifier.internal.util.Context; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/HierarchyChecker.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/HierarchyChecker.java index fc7de55b4..1367ef57f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/HierarchyChecker.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/HierarchyChecker.java @@ -7,10 +7,10 @@ import java.lang.reflect.Modifier; import nl.jqno.equalsverifier.Warning; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.ClassProbe; import nl.jqno.equalsverifier.internal.reflection.Instantiator; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.*; public class HierarchyChecker implements Checker { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/MapEntryHashCodeRequirementChecker.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/MapEntryHashCodeRequirementChecker.java index 3caf7f991..7e219f02f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/MapEntryHashCodeRequirementChecker.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/MapEntryHashCodeRequirementChecker.java @@ -4,7 +4,7 @@ import java.util.Map; import java.util.Objects; -import nl.jqno.equalsverifier.internal.reflection.instantiation.ValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.util.Configuration; import nl.jqno.equalsverifier.internal.util.Context; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/RecordChecker.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/RecordChecker.java index 30cd67409..1ac829845 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/RecordChecker.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/RecordChecker.java @@ -9,9 +9,9 @@ import java.util.ArrayList; import java.util.List; import java.util.stream.Collectors; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.ClassProbe; import nl.jqno.equalsverifier.internal.reflection.FieldIterable; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Context; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ArrayFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ArrayFieldCheck.java index 506c37a19..c269b96d8 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ArrayFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ArrayFieldCheck.java @@ -3,8 +3,8 @@ import static nl.jqno.equalsverifier.internal.util.Assert.assertEquals; import java.lang.reflect.Array; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.CachedHashCodeInitializer; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/BigDecimalFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/BigDecimalFieldCheck.java index d766321d8..9ec15ae89 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/BigDecimalFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/BigDecimalFieldCheck.java @@ -6,8 +6,8 @@ import java.math.BigDecimal; import java.math.RoundingMode; import nl.jqno.equalsverifier.Warning; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.CachedHashCodeInitializer; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/FloatAndDoubleFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/FloatAndDoubleFieldCheck.java index 64841b5f5..a970b2e3f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/FloatAndDoubleFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/FloatAndDoubleFieldCheck.java @@ -2,8 +2,8 @@ import static nl.jqno.equalsverifier.internal.util.Assert.assertEquals; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Formatter; public class FloatAndDoubleFieldCheck implements FieldCheck { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/JpaLazyGetterFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/JpaLazyGetterFieldCheck.java index 2632bc342..1ed068764 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/JpaLazyGetterFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/JpaLazyGetterFieldCheck.java @@ -9,11 +9,11 @@ import java.util.function.Function; import nl.jqno.equalsverifier.Warning; import nl.jqno.equalsverifier.internal.exceptions.EqualsVerifierInternalBugException; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.reflection.*; import nl.jqno.equalsverifier.internal.reflection.annotations.AnnotationCache; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; -import nl.jqno.equalsverifier.internal.reflection.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.util.Configuration; import nl.jqno.equalsverifier.internal.util.Context; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/MutableStateFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/MutableStateFieldCheck.java index 13b0b576e..9d71e65ee 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/MutableStateFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/MutableStateFieldCheck.java @@ -3,8 +3,8 @@ import static nl.jqno.equalsverifier.internal.util.Assert.fail; import java.util.function.Predicate; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Formatter; public class MutableStateFieldCheck implements FieldCheck { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/NullPointerExceptionFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/NullPointerExceptionFieldCheck.java index ce83a8c38..7219616f7 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/NullPointerExceptionFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/NullPointerExceptionFieldCheck.java @@ -4,9 +4,9 @@ import java.lang.reflect.Field; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldMutator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.*; @SuppressFBWarnings( diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ReflexivityFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ReflexivityFieldCheck.java index c8705a78c..9e28dea88 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ReflexivityFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/ReflexivityFieldCheck.java @@ -7,11 +7,11 @@ import java.util.EnumSet; import java.util.Set; import nl.jqno.equalsverifier.Warning; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.reflection.*; import nl.jqno.equalsverifier.internal.reflection.annotations.AnnotationCache; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; -import nl.jqno.equalsverifier.internal.reflection.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.util.Configuration; import nl.jqno.equalsverifier.internal.util.Context; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SignificantFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SignificantFieldCheck.java index c459965c7..19d530ea8 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SignificantFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SignificantFieldCheck.java @@ -7,10 +7,10 @@ import java.util.Set; import java.util.function.Predicate; import nl.jqno.equalsverifier.Warning; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; import nl.jqno.equalsverifier.internal.reflection.annotations.AnnotationCache; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.*; public class SignificantFieldCheck implements FieldCheck { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/StringFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/StringFieldCheck.java index ee5614ac8..0000feb2f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/StringFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/StringFieldCheck.java @@ -4,10 +4,10 @@ import nl.jqno.equalsverifier.internal.SuppressFBWarnings; import nl.jqno.equalsverifier.internal.exceptions.ReflectionException; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; -import nl.jqno.equalsverifier.internal.reflection.instantiation.ValueProvider; import nl.jqno.equalsverifier.internal.util.CachedHashCodeInitializer; import nl.jqno.equalsverifier.internal.util.Formatter; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SymmetryFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SymmetryFieldCheck.java index cad26b78b..1bc2d67ad 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SymmetryFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/SymmetryFieldCheck.java @@ -3,8 +3,8 @@ import static nl.jqno.equalsverifier.internal.util.Assert.assertTrue; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Formatter; public class SymmetryFieldCheck implements FieldCheck { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransientFieldsCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransientFieldsCheck.java index c149c2ccc..a0f2c9c3b 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransientFieldsCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransientFieldsCheck.java @@ -3,11 +3,11 @@ import static nl.jqno.equalsverifier.internal.util.Assert.fail; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; import nl.jqno.equalsverifier.internal.reflection.TypeTag; import nl.jqno.equalsverifier.internal.reflection.annotations.AnnotationCache; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Formatter; public class TransientFieldsCheck implements FieldCheck { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransitivityFieldCheck.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransitivityFieldCheck.java index 243c7b91f..c4b540a96 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransitivityFieldCheck.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/checkers/fieldchecks/TransitivityFieldCheck.java @@ -3,8 +3,8 @@ import static nl.jqno.equalsverifier.internal.util.Assert.fail; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; import nl.jqno.equalsverifier.internal.util.Formatter; public class TransitivityFieldCheck implements FieldCheck { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/InstanceCreator.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/InstanceCreator.java similarity index 97% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/InstanceCreator.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/InstanceCreator.java index 51b93e953..eb79f3b79 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/InstanceCreator.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/InstanceCreator.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation; import java.lang.reflect.Field; import java.util.*; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/JavaApiPrefabValues.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/JavaApiPrefabValues.java similarity index 98% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/JavaApiPrefabValues.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/JavaApiPrefabValues.java index c52ba7ed1..65e710c2e 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/JavaApiPrefabValues.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/JavaApiPrefabValues.java @@ -1,8 +1,8 @@ -package nl.jqno.equalsverifier.internal.reflection; +package nl.jqno.equalsverifier.internal.instantiation; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.*; import static nl.jqno.equalsverifier.internal.reflection.Util.classes; import static nl.jqno.equalsverifier.internal.reflection.Util.objects; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.*; import static nl.jqno.equalsverifier.internal.util.Rethrow.rethrow; import java.beans.PropertyChangeSupport; @@ -29,8 +29,12 @@ import java.util.function.Supplier; import java.util.regex.Pattern; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.*; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.*; +import nl.jqno.equalsverifier.internal.reflection.ConditionalInstantiator; +import nl.jqno.equalsverifier.internal.reflection.Tuple; +import nl.jqno.equalsverifier.internal.reflection.TypeTag; /** * Creates instances of classes for use in a {@link VintageValueProvider} object. diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/SubjectCreator.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/SubjectCreator.java similarity index 99% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/SubjectCreator.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/SubjectCreator.java index d4f23867f..3e5e59b6c 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/SubjectCreator.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/SubjectCreator.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation; import java.lang.reflect.Field; import java.util.HashMap; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/ValueProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/ValueProvider.java similarity index 96% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/ValueProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/ValueProvider.java index 268a43e24..e2482c139 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/ValueProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/ValueProvider.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation; import java.util.Optional; import nl.jqno.equalsverifier.internal.exceptions.NoValueException; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FactoryCache.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/FactoryCache.java similarity index 93% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FactoryCache.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/FactoryCache.java index 5db5d3903..a07a000cc 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FactoryCache.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/FactoryCache.java @@ -1,9 +1,8 @@ -package nl.jqno.equalsverifier.internal.reflection; +package nl.jqno.equalsverifier.internal.instantiation.vintage; import java.util.HashMap; import java.util.Map; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; /** Contains a cache of factories, for {@link VintageValueProvider}. */ public class FactoryCache { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/PrefabValuesApi.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/PrefabValuesApi.java similarity index 84% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/PrefabValuesApi.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/PrefabValuesApi.java index 8bc5c9c0c..7d153fe08 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/PrefabValuesApi.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/PrefabValuesApi.java @@ -1,15 +1,15 @@ -package nl.jqno.equalsverifier.internal.util; +package nl.jqno.equalsverifier.internal.instantiation.vintage; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.simple; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.simple; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import nl.jqno.equalsverifier.Func.Func1; import nl.jqno.equalsverifier.Func.Func2; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.reflection.ObjectAccessor; import nl.jqno.equalsverifier.internal.reflection.FieldCache; import nl.jqno.equalsverifier.internal.reflection.Tuple; -import nl.jqno.equalsverifier.internal.reflection.vintage.ObjectAccessor; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.util.Validations; import org.objenesis.Objenesis; public final class PrefabValuesApi { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProvider.java similarity index 95% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProvider.java index c4937e21e..333b2ef6c 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProvider.java @@ -1,14 +1,14 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation.vintage; import java.util.*; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; import nl.jqno.equalsverifier.internal.exceptions.RecursionException; import nl.jqno.equalsverifier.internal.exceptions.ReflectionException; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.FallbackFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.FallbackFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; import nl.jqno.equalsverifier.internal.util.PrimitiveMappers; import nl.jqno.equalsverifier.internal.util.Rethrow; import org.objenesis.Objenesis; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/AbstractGenericFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/AbstractGenericFactory.java similarity index 94% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/AbstractGenericFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/AbstractGenericFactory.java index ef35f58c3..1534761a2 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/AbstractGenericFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/AbstractGenericFactory.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; @@ -7,8 +7,8 @@ import java.util.List; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; import nl.jqno.equalsverifier.internal.exceptions.ReflectionException; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; /** * Abstract implementation of {@link PrefabValueFactory} that provides helper functions for dealing diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/CopyFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/CopyFactory.java similarity index 86% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/CopyFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/CopyFactory.java index 1b1222861..332c159c2 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/CopyFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/CopyFactory.java @@ -1,10 +1,10 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.LinkedHashSet; import java.util.function.Function; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; public class CopyFactory extends AbstractGenericFactory { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/EnumMapFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/EnumMapFactory.java similarity index 89% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/EnumMapFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/EnumMapFactory.java index 5b1424694..8ca507f7f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/EnumMapFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/EnumMapFactory.java @@ -1,12 +1,12 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.HashMap; import java.util.LinkedHashSet; import java.util.Map; import java.util.function.Function; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; @SuppressWarnings({ "unchecked", "rawtypes" }) public final class EnumMapFactory extends AbstractGenericFactory { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/EnumSetFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/EnumSetFactory.java similarity index 88% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/EnumSetFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/EnumSetFactory.java index 61a59e447..ad0c9a806 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/EnumSetFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/EnumSetFactory.java @@ -1,12 +1,12 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.Collection; import java.util.HashSet; import java.util.LinkedHashSet; import java.util.function.Function; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; /** * Implementation of {@link PrefabValueFactory} that instantiates EnumSets using reflection, while diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/ExternalFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/ExternalFactory.java similarity index 73% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/ExternalFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/ExternalFactory.java index 0bea3340b..7ed1166df 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/ExternalFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/ExternalFactory.java @@ -1,20 +1,20 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import static nl.jqno.equalsverifier.internal.reflection.Util.classes; import static nl.jqno.equalsverifier.internal.reflection.Util.objects; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders.FactoryProvider; import nl.jqno.equalsverifier.internal.reflection.ConditionalInstantiator; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders.FactoryProvider; public class ExternalFactory implements PrefabValueFactory { private static final String EXTERNAL_FACTORIES_PACKAGE = - "nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders."; + "nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders."; private final String factoryName; private FactoryCache factoryCache; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/Factories.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/Factories.java similarity index 94% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/Factories.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/Factories.java index 42cf962cd..f2240b56f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/Factories.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/Factories.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.Collection; import java.util.Map; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FallbackFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FallbackFactory.java similarity index 92% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FallbackFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FallbackFactory.java index e74a21580..73f459a67 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FallbackFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FallbackFactory.java @@ -1,11 +1,11 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.lang.reflect.Array; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.reflection.ClassAccessor; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.ClassAccessor; import org.objenesis.Objenesis; /** diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/MapFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/MapFactory.java similarity index 91% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/MapFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/MapFactory.java index 5673808f7..b50ca8a05 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/MapFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/MapFactory.java @@ -1,11 +1,11 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.LinkedHashSet; import java.util.Map; import java.util.function.Supplier; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; /** * Implementation of {@link PrefabValueFactory} that specializes in creating implementations of diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/PrefabValueFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/PrefabValueFactory.java similarity index 83% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/PrefabValueFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/PrefabValueFactory.java index 4616c2660..c7f03252a 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/PrefabValueFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/PrefabValueFactory.java @@ -1,9 +1,9 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; /** * Creates instances of generic types for use as prefab value. diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleFactory.java similarity index 80% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleFactory.java index 44a7ae041..77375f3d6 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleFactory.java @@ -1,9 +1,9 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; /** * Implementation of {@link PrefabValueFactory} that holds on to two instances that have already diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleGenericFactory.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleGenericFactory.java similarity index 91% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleGenericFactory.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleGenericFactory.java index 748f64f7f..70a8b683d 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleGenericFactory.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleGenericFactory.java @@ -1,13 +1,13 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import java.util.ArrayList; import java.util.LinkedHashSet; import java.util.List; import java.util.function.Supplier; import nl.jqno.equalsverifier.Func; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; public class SimpleGenericFactory extends AbstractGenericFactory { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java similarity index 83% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java index 2312d3b5a..ccee73a6b 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/AwtFactoryProvider.java @@ -1,13 +1,15 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; -import java.awt.*; +import java.awt.Color; +import java.awt.Font; +import java.awt.Image; import java.awt.color.ColorSpace; import java.awt.color.ICC_ColorSpace; import java.awt.color.ICC_Profile; import java.awt.image.BufferedImage; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; public final class AwtFactoryProvider implements FactoryProvider { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/FactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/FactoryProvider.java new file mode 100644 index 000000000..685937c3b --- /dev/null +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/FactoryProvider.java @@ -0,0 +1,7 @@ +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; + +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; + +public interface FactoryProvider { + FactoryCache getFactoryCache(); +} diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java similarity index 92% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java index 4416de38c..ebba614d2 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/GuavaFactoryProvider.java @@ -1,19 +1,16 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.*; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.*; import com.google.common.collect.*; import com.google.common.reflect.TypeToken; import java.util.*; import java.util.function.Supplier; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.*; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.AbstractGenericFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.EnumMapFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.EnumSetFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories; public final class GuavaFactoryProvider implements FactoryProvider { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java similarity index 86% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java index aa2b6a3ca..b47636262 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaFxFactoryProvider.java @@ -1,16 +1,19 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.*; import static nl.jqno.equalsverifier.internal.reflection.Util.classForName; import static nl.jqno.equalsverifier.internal.reflection.Util.classes; import static nl.jqno.equalsverifier.internal.reflection.Util.objects; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.copy; import java.util.*; import java.util.function.Function; -import nl.jqno.equalsverifier.internal.reflection.*; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.AbstractGenericFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.AbstractGenericFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.reflection.ConditionalInstantiator; +import nl.jqno.equalsverifier.internal.reflection.Tuple; +import nl.jqno.equalsverifier.internal.reflection.TypeTag; public final class JavaFxFactoryProvider implements FactoryProvider { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java similarity index 70% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java index 386bb67ae..a223b962f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaxFactoryProvider.java @@ -1,10 +1,10 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import javax.naming.Reference; import javax.swing.tree.DefaultMutableTreeNode; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; public final class JavaxFactoryProvider implements FactoryProvider { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java similarity index 81% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java index da40b542d..255320318 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JodaFactoryProvider.java @@ -1,8 +1,8 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; import org.joda.time.*; import org.joda.time.chrono.GregorianChronology; import org.joda.time.chrono.ISOChronology; diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java similarity index 61% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java index edb25d411..5f55cac20 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/RmiFactoryProvider.java @@ -1,10 +1,10 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import java.rmi.dgc.VMID; import java.rmi.server.UID; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; public final class RmiFactoryProvider implements FactoryProvider { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/ClassAccessor.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ClassAccessor.java similarity index 96% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/ClassAccessor.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ClassAccessor.java index e19fde95d..905184334 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/ClassAccessor.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ClassAccessor.java @@ -1,9 +1,9 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Instantiator; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import org.objenesis.Objenesis; /** diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/FieldModifier.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/FieldModifier.java similarity index 95% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/FieldModifier.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/FieldModifier.java index 0b91e5f87..546236fd3 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/FieldModifier.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/FieldModifier.java @@ -1,13 +1,13 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import static nl.jqno.equalsverifier.internal.util.Rethrow.rethrow; import java.lang.reflect.Field; import java.util.LinkedHashSet; import nl.jqno.equalsverifier.internal.exceptions.ReflectionException; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; public final class FieldModifier { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessor.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessor.java similarity index 90% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessor.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessor.java index c9cf1c573..68089fdf8 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessor.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessor.java @@ -1,11 +1,11 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import java.lang.reflect.Field; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.FieldIterable; import nl.jqno.equalsverifier.internal.reflection.Instantiator; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import org.objenesis.Objenesis; /** diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/ObjectAccessor.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ObjectAccessor.java similarity index 95% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/ObjectAccessor.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ObjectAccessor.java index 480e30224..9fe79aa2c 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/ObjectAccessor.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ObjectAccessor.java @@ -1,9 +1,9 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import java.util.LinkedHashSet; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.RecordsHelper; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import org.objenesis.Objenesis; /** diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessor.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessor.java similarity index 93% rename from equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessor.java rename to equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessor.java index c1f63ea44..425d46da6 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/RecordObjectAccessor.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/RecordObjectAccessor.java @@ -1,14 +1,14 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import java.lang.reflect.Field; import java.util.LinkedHashSet; import java.util.List; import java.util.function.Function; import java.util.stream.Collectors; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.FieldProbe; import nl.jqno.equalsverifier.internal.reflection.RecordProbe; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import org.objenesis.Objenesis; /** diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FieldCache.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FieldCache.java index 455a786e5..28856ac6f 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FieldCache.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/FieldCache.java @@ -1,7 +1,7 @@ package nl.jqno.equalsverifier.internal.reflection; import java.util.*; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; /** Contains a cache for values connected to specific fields, for {@link SubjectCreator}. */ public class FieldCache { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/FactoryProvider.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/FactoryProvider.java deleted file mode 100644 index c81cda452..000000000 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/FactoryProvider.java +++ /dev/null @@ -1,7 +0,0 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; - -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; - -public interface FactoryProvider { - FactoryCache getFactoryCache(); -} diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Context.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Context.java index d7d7a5591..6081356d3 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Context.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Context.java @@ -1,10 +1,13 @@ package nl.jqno.equalsverifier.internal.util; import nl.jqno.equalsverifier.internal.SuppressFBWarnings; -import nl.jqno.equalsverifier.internal.reflection.*; -import nl.jqno.equalsverifier.internal.reflection.instantiation.SubjectCreator; -import nl.jqno.equalsverifier.internal.reflection.instantiation.ValueProvider; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.SubjectCreator; +import nl.jqno.equalsverifier.internal.instantiation.ValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.reflection.ClassProbe; +import nl.jqno.equalsverifier.internal.reflection.FieldCache; import org.objenesis.Objenesis; public final class Context { diff --git a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Validations.java b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Validations.java index 5bc2dcdf1..ece4b6740 100644 --- a/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Validations.java +++ b/equalsverifier-core/src/main/java/nl/jqno/equalsverifier/internal/util/Validations.java @@ -3,16 +3,13 @@ import static nl.jqno.equalsverifier.internal.util.ListBuilders.listContainsDuplicates; import java.lang.reflect.Field; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import java.util.Set; +import java.util.*; import java.util.stream.Collectors; import nl.jqno.equalsverifier.Warning; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; import nl.jqno.equalsverifier.internal.reflection.FieldIterable; import nl.jqno.equalsverifier.internal.reflection.annotations.AnnotationCache; import nl.jqno.equalsverifier.internal.reflection.annotations.SupportedAnnotations; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; public final class Validations { diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/architecture/ArchitectureTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/architecture/ArchitectureTest.java index b7461f4e9..014186834 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/architecture/ArchitectureTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/architecture/ArchitectureTest.java @@ -5,16 +5,10 @@ import com.tngtech.archunit.junit.AnalyzeClasses; import com.tngtech.archunit.junit.ArchTest; import com.tngtech.archunit.lang.ArchRule; -import nl.jqno.equalsverifier.internal.reflection.FactoryCacheTest; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProviderCreatorTest; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProviderTest; -import nl.jqno.equalsverifier.internal.reflection.vintage.ClassAccessor; -import nl.jqno.equalsverifier.internal.reflection.vintage.FieldModifier; -import nl.jqno.equalsverifier.internal.reflection.vintage.ObjectAccessor; -import nl.jqno.equalsverifier.internal.util.Context; -import nl.jqno.equalsverifier.internal.util.PrefabValuesApi; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.reflection.ClassAccessor; +import nl.jqno.equalsverifier.internal.instantiation.vintage.reflection.FieldModifier; +import nl.jqno.equalsverifier.internal.instantiation.vintage.reflection.ObjectAccessor; import nl.jqno.equalsverifier.testhelpers.FactoryCacheFactory; @AnalyzeClasses(packages = "nl.jqno.equalsverifier") @@ -23,22 +17,19 @@ public final class ArchitectureTest { @ArchTest public static final ArchRule ONLY_VINTAGE_INSTANTIATORS_CAN_USE_VINTAGE_REFLECTION = noClasses() .that() + .resideOutsideOfPackage("nl.jqno.equalsverifier.internal.instantiation.vintage..") + .and() .doNotBelongToAnyOf( - VintageValueProvider.class, - Context.class, - PrefabValuesApi.class, JavaApiPrefabValues.class, // 👇 Test classes - FactoryCacheFactory.class, - FactoryCacheTest.class, - VintageValueProviderTest.class, - VintageValueProviderCreatorTest.class + FactoryCacheFactory.class ) - .and() - .resideOutsideOfPackage("nl.jqno.equalsverifier.internal.reflection.vintage..") .should() .accessClassesThat() - .resideInAPackage("nl.jqno.equalsverifier.internal.reflection.vintage.."); + .resideInAPackage("nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues..") + .orShould() + .accessClassesThat() + .resideInAPackage("nl.jqno.equalsverifier.internal.instantiation.vintage.reflection.."); @ArchTest public static final ArchRule DONT_USE_VINTAGE_REFLECTION_DIRECTLY = noClasses() @@ -83,7 +74,7 @@ public final class ArchitectureTest { ); private static final String FACTORYPROVIDER_PATTERN = - "nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders.."; + "nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders.."; private static final String TEST_CLASS_PATTERN = ".*Test(\\$.*)?$"; private ArchitectureTest() { diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/InstanceCreatorTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/InstanceCreatorTest.java similarity index 96% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/InstanceCreatorTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/InstanceCreatorTest.java index 4cd563b6f..0ca65bbe0 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/InstanceCreatorTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/InstanceCreatorTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/SubjectCreatorTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/SubjectCreatorTest.java similarity index 99% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/SubjectCreatorTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/SubjectCreatorTest.java index e62ebfd13..46a603f0c 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/SubjectCreatorTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/SubjectCreatorTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotSame; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/FactoryCacheTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/FactoryCacheTest.java similarity index 89% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/FactoryCacheTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/FactoryCacheTest.java index 90801ea0a..a91e73794 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/FactoryCacheTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/FactoryCacheTest.java @@ -1,9 +1,9 @@ -package nl.jqno.equalsverifier.internal.reflection; +package nl.jqno.equalsverifier.internal.instantiation.vintage; import static org.junit.jupiter.api.Assertions.*; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.SimpleFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.SimpleFactory; import org.junit.jupiter.api.Test; public class FactoryCacheTest { diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/util/PrefabValuesApiTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/PrefabValuesApiTest.java similarity index 81% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/util/PrefabValuesApiTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/PrefabValuesApiTest.java index cae0f474d..33d789da6 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/util/PrefabValuesApiTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/PrefabValuesApiTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.util; +package nl.jqno.equalsverifier.internal.instantiation.vintage; import static nl.jqno.equalsverifier.internal.testhelpers.Util.coverThePrivateConstructor; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProviderCreatorTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProviderCreatorTest.java similarity index 96% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProviderCreatorTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProviderCreatorTest.java index 45bba76bc..934543a92 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProviderCreatorTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProviderCreatorTest.java @@ -1,10 +1,9 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation.vintage; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static org.junit.jupiter.api.Assertions.*; import nl.jqno.equalsverifier.internal.exceptions.RecursionException; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; import nl.jqno.equalsverifier.internal.reflection.TypeTag; import nl.jqno.equalsverifier.internal.testhelpers.ExpectedException; import nl.jqno.equalsverifier.testhelpers.FactoryCacheFactory; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProviderTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProviderTest.java similarity index 96% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProviderTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProviderTest.java index 03cde5c19..b51060445 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/instantiation/VintageValueProviderTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/VintageValueProviderTest.java @@ -1,6 +1,6 @@ -package nl.jqno.equalsverifier.internal.reflection.instantiation; +package nl.jqno.equalsverifier.internal.instantiation.vintage; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static nl.jqno.equalsverifier.internal.testhelpers.Util.defaultEquals; import static nl.jqno.equalsverifier.internal.testhelpers.Util.defaultHashCode; import static org.junit.jupiter.api.Assertions.assertEquals; @@ -8,10 +8,9 @@ import static org.junit.jupiter.api.Assertions.fail; import java.util.*; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; import nl.jqno.equalsverifier.testhelpers.types.Point; import nl.jqno.equalsverifier.testhelpers.types.ThrowingInitializer; import org.junit.jupiter.api.BeforeEach; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java similarity index 90% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java index e0a2263fd..84d0d7e92 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/AbstractGenericFactoryTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import static nl.jqno.equalsverifier.internal.reflection.Util.classes; import static nl.jqno.equalsverifier.internal.reflection.Util.objects; @@ -6,9 +6,9 @@ import java.util.LinkedHashSet; import nl.jqno.equalsverifier.internal.exceptions.ReflectionException; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FactoriesTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FactoriesTest.java similarity index 75% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FactoriesTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FactoriesTest.java index 98337dd5a..17a113e7d 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FactoriesTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FactoriesTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import static nl.jqno.equalsverifier.internal.testhelpers.Util.coverThePrivateConstructor; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FallbackFactoryTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FallbackFactoryTest.java similarity index 93% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FallbackFactoryTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FallbackFactoryTest.java index af6902890..bb5d11a95 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/FallbackFactoryTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/FallbackFactoryTest.java @@ -1,6 +1,6 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static nl.jqno.equalsverifier.internal.testhelpers.Util.defaultEquals; import static nl.jqno.equalsverifier.internal.testhelpers.Util.defaultHashCode; import static org.junit.jupiter.api.Assertions.assertArrayEquals; @@ -9,10 +9,10 @@ import java.util.LinkedHashSet; import nl.jqno.equalsverifier.internal.exceptions.RecursionException; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import nl.jqno.equalsverifier.internal.testhelpers.ExpectedException; import nl.jqno.equalsverifier.testhelpers.types.RecursiveTypeHelper.Node; import nl.jqno.equalsverifier.testhelpers.types.RecursiveTypeHelper.NodeArray; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/MapFactoryTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/MapFactoryTest.java similarity index 93% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/MapFactoryTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/MapFactoryTest.java index afd23e9d7..da1f220e7 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/MapFactoryTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/MapFactoryTest.java @@ -1,14 +1,14 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import static org.junit.jupiter.api.Assertions.assertEquals; import java.util.HashMap; import java.util.LinkedHashSet; import java.util.Map; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import nl.jqno.equalsverifier.testhelpers.types.TypeHelper.OneElementEnum; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleFactoryTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleFactoryTest.java similarity index 89% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleFactoryTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleFactoryTest.java index 3adabc58f..7eec1bf30 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleFactoryTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleFactoryTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotSame; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java similarity index 93% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java index ff5f32d6e..7f7ba2b29 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factories/SimpleGenericFactoryTest.java @@ -1,13 +1,13 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories; import static org.junit.jupiter.api.Assertions.assertEquals; import java.util.LinkedHashSet; import java.util.Optional; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import nl.jqno.equalsverifier.testhelpers.types.Pair; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java similarity index 86% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java index 06681caeb..ec5218593 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/prefabvalues/factoryproviders/JavaFxFactoryProviderTest.java @@ -1,16 +1,16 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders; +package nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; import java.util.List; import java.util.Map; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.PrefabValueFactory; +import nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factoryproviders.JavaFxFactoryProvider.PropertyFactory; import nl.jqno.equalsverifier.internal.reflection.Tuple; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.PrefabValueFactory; -import nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factoryproviders.JavaFxFactoryProvider.PropertyFactory; import nl.jqno.equalsverifier.testhelpers.types.Point; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/ClassAccessorTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ClassAccessorTest.java similarity index 92% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/ClassAccessorTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ClassAccessorTest.java index 3fbfcb6cb..912287180 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/ClassAccessorTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/ClassAccessorTest.java @@ -1,15 +1,15 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertNotNull; import java.util.LinkedHashSet; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import nl.jqno.equalsverifier.testhelpers.types.PointContainer; import nl.jqno.equalsverifier.testhelpers.types.RecursiveTypeHelper.TwoStepNodeA; import nl.jqno.equalsverifier.testhelpers.types.RecursiveTypeHelper.TwoStepNodeB; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/FieldModifierTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/FieldModifierTest.java similarity index 95% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/FieldModifierTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/FieldModifierTest.java index e0b2562b2..7746c1702 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/FieldModifierTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/FieldModifierTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertSame; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorCopyingTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorCopyingTest.java similarity index 97% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorCopyingTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorCopyingTest.java index a224280df..5ec8b577a 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorCopyingTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorCopyingTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotSame; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorScramblingTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorScramblingTest.java similarity index 93% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorScramblingTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorScramblingTest.java index a6775ab59..8a826a5d5 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorScramblingTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorScramblingTest.java @@ -1,6 +1,6 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; import static org.junit.jupiter.api.Assertions.*; import java.text.AttributedString; @@ -8,10 +8,10 @@ import java.util.LinkedHashSet; import java.util.List; import nl.jqno.equalsverifier.internal.exceptions.ModuleException; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; -import nl.jqno.equalsverifier.internal.reflection.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.JavaApiPrefabValues; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.VintageValueProvider; import nl.jqno.equalsverifier.internal.reflection.TypeTag; -import nl.jqno.equalsverifier.internal.reflection.instantiation.VintageValueProvider; import nl.jqno.equalsverifier.internal.testhelpers.ExpectedException; import nl.jqno.equalsverifier.testhelpers.types.Point; import nl.jqno.equalsverifier.testhelpers.types.Point3D; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorTest.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorTest.java similarity index 91% rename from equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorTest.java rename to equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorTest.java index 85152215a..77a4a7c52 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/reflection/vintage/InPlaceObjectAccessorTest.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/internal/instantiation/vintage/reflection/InPlaceObjectAccessorTest.java @@ -1,4 +1,4 @@ -package nl.jqno.equalsverifier.internal.reflection.vintage; +package nl.jqno.equalsverifier.internal.instantiation.vintage.reflection; import static org.junit.jupiter.api.Assertions.assertSame; import static org.junit.jupiter.api.Assertions.assertTrue; diff --git a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/testhelpers/FactoryCacheFactory.java b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/testhelpers/FactoryCacheFactory.java index 9f9871c6e..b8f31e641 100644 --- a/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/testhelpers/FactoryCacheFactory.java +++ b/equalsverifier-core/src/test/java/nl/jqno/equalsverifier/testhelpers/FactoryCacheFactory.java @@ -1,8 +1,8 @@ package nl.jqno.equalsverifier.testhelpers; -import static nl.jqno.equalsverifier.internal.reflection.vintage.prefabvalues.factories.Factories.values; +import static nl.jqno.equalsverifier.internal.instantiation.vintage.prefabvalues.factories.Factories.values; -import nl.jqno.equalsverifier.internal.reflection.FactoryCache; +import nl.jqno.equalsverifier.internal.instantiation.vintage.FactoryCache; public final class FactoryCacheFactory { diff --git a/equalsverifier-release-verify/src/test/java/nl/jqno/equalsverifier/verify_release/jar/helper/JarAsserter.java b/equalsverifier-release-verify/src/test/java/nl/jqno/equalsverifier/verify_release/jar/helper/JarAsserter.java index 2da2a26f3..3c21c6a96 100644 --- a/equalsverifier-release-verify/src/test/java/nl/jqno/equalsverifier/verify_release/jar/helper/JarAsserter.java +++ b/equalsverifier-release-verify/src/test/java/nl/jqno/equalsverifier/verify_release/jar/helper/JarAsserter.java @@ -23,7 +23,7 @@ public JarAsserter(JarReader reader) { public void assertPresenceOfCoreClasses() { assertPresenceOf( EV + "/EqualsVerifier.class", - EV + "/internal/reflection/vintage/ClassAccessor.class", + EV + "/internal/reflection/ClassProbe.class", EV + "/internal/checkers/HierarchyChecker.class" ); }