From 22037d725d7069c1dd2ffbaf7f1573511e1dec63 Mon Sep 17 00:00:00 2001 From: Alex Zaytsev Date: Tue, 26 Mar 2024 16:11:56 +1000 Subject: [PATCH] Remove redundant private modifiers --- .editorconfig | 9 ++- .../Program.cs | 8 +-- src/Examples.FirstProject/Program.cs | 8 +-- .../Automapping/AutoPersistenceModelSpecs.cs | 2 +- .../AutomappingSpecs.NestedClasses.cs | 3 +- .../Automapping/Fixtures/StubTypeSource.cs | 2 +- .../Automapping/OverrideSpecs.cs | 4 +- .../Conventions/ComponentConventionSpecs.cs | 6 +- .../ClassMapSpecs/ClassMapSpecs.Component.cs | 4 +- .../FluentInterface/ComponentMapSpecs.cs | 60 +++++++++---------- .../ExternalComponentOutputSpecs.cs | 16 ++--- .../Fixtures/EntityWithProperties.cs | 2 +- .../Utilities/Fixtures/Target.cs | 6 +- .../Utilities/Fixtures/TargetParent.cs | 2 +- ...irectionalManyToManyPairingVisitorSpecs.cs | 22 +++---- .../Apm/AlterationCollectionTests.cs | 2 +- .../AutoMapping/Apm/AlterationTests.cs | 2 +- .../Apm/AutoPersistenceModelTests.cs | 12 ++-- .../Apm/Conventions/HasManyConventionTests.cs | 8 +-- .../Conventions/IdentityConventionTests.cs | 4 +- .../Conventions/ReferencesConventionTests.cs | 2 +- .../Apm/Conventions/VersionConventionTests.cs | 4 +- .../IgnoreBaseAutoPersistenceModelTests.cs | 4 +- .../AutoMapping/BaseAutoMapFixture.cs | 4 +- .../AutoMappingOverrideAlterationTests.cs | 2 +- .../Overrides/CompositeIdOverrides.cs | 8 +-- .../AutoMapping/Steps/HasManyStepTests.cs | 2 +- .../AutoMapping/Steps/ReferenceStepTests.cs | 2 +- .../AutoMapping/Steps/VersionStepTests.cs | 12 ++-- .../AutoMapping/VersionTests.cs | 2 +- .../Cfg/Db/CacheSettingsBuilderTester.cs | 6 +- .../Cfg/Db/ConnectionStringBuilderTester.cs | 4 +- .../Cfg/Db/FirebirdConfigurationTester.cs | 4 +- .../Cfg/Db/PersistenceConfigurationTester.cs | 5 +- .../Cfg/FluentConfigurationTests.cs | 10 ++-- .../Cfg/MappingConfigurationTests.cs | 4 +- .../ConventionFinderTests/AddingTypeTests.cs | 2 +- .../ConventionFinderTests/FindTests.cs | 2 +- .../PropertyAcceptanceCriteriaAnyTests.cs | 2 +- ...opertyAcceptanceCriteriaCollectionTests.cs | 2 +- ...AcceptanceCriteriaEqualComplexTypeTests.cs | 2 +- ...eptanceCriteriaEqualSimpleTypeEvalTests.cs | 2 +- ...yAcceptanceCriteriaEqualSimpleTypeTests.cs | 2 +- ...AcceptanceCriteriaEqualSubPropertyTests.cs | 2 +- ...pertyAcceptanceCriteriaInheritanceTests.cs | 4 +- .../PropertyAcceptanceCriteriaIsAnyTests.cs | 2 +- .../PropertyAcceptanceCriteriaIsSetTests.cs | 2 +- .../PropertyAcceptanceCriteriaTests.cs | 2 +- .../ConventionsTests/AccessConventionTests.cs | 14 ++--- .../ApplyingToModel/ArrayConventionTests.cs | 6 +- .../ApplyingToModel/ClassConventionTests.cs | 8 +-- .../ComponentConventionTests.cs | 6 +- .../CompositeIdConventionTests.cs | 6 +- .../DynamicComponentConventionTests.cs | 6 +- .../HasManyCollectionConventionTests.cs | 6 +- .../ApplyingToModel/HasManyConventionTests.cs | 6 +- .../HasManyToManyCollectionConventionTests.cs | 6 +- .../HasManyToManyConventionTests.cs | 6 +- .../ApplyingToModel/HasOneConventionTests.cs | 6 +- .../HibernateMappingConventionTests.cs | 6 +- .../ApplyingToModel/IdConventionTests.cs | 8 +-- .../ApplyingToModel/JoinConventionTests.cs | 6 +- .../JoinedSubclassConventionTests.cs | 6 +- .../KeyManyToOneConventionTests.cs | 6 +- .../KeyPropertyConventionTests.cs | 6 +- .../ManyToOneConventionTests.cs | 6 +- .../NaturalIdManyToOneConventionTests.cs | 6 +- .../NaturalIdPropertyConventionTests.cs | 6 +- .../PropertyConventionTests.cs | 6 +- .../SubclassConventionTests.cs | 6 +- .../ApplyingToModel/VersionConventionTests.cs | 6 +- .../ConventionsTests/AutoImportHelperTests.cs | 4 +- .../ConventionsCollectionTests.cs | 2 +- .../DefaultAccessHelperTests.cs | 4 +- .../DefaultCascadeHelperTests.cs | 4 +- .../DefaultLazyHelperTests.cs | 4 +- .../ForeignKeyConventionTests.cs | 4 +- .../MixedConventionInstanceTester.cs | 2 +- .../MultipleHelperConventions.cs | 4 +- .../ConventionsTests/OptionalAcceptTests.cs | 10 ++-- .../ArrayConventionTests.cs | 12 ++-- .../ClassConventionTests.cs | 14 ++--- .../ComponentConventionTests.cs | 12 ++-- .../CompositeIdConventionTests.cs | 12 ++-- .../DynamicComponentConventionTests.cs | 12 ++-- .../HasManyCollectionConventionTests.cs | 12 ++-- .../HasManyConventionTests.cs | 12 ++-- .../HasManyToManyCollectionConventionTests.cs | 12 ++-- .../HasManyToManyConventionTests.cs | 12 ++-- .../HasOneConventionTests.cs | 12 ++-- .../HibernateMappingConventionTests.cs | 12 ++-- .../IdConventionTests.cs | 12 ++-- .../JoinConventionTests.cs | 12 ++-- .../JoinedSubclassConventionTests.cs | 12 ++-- .../KeyManyToOneConventionTests.cs | 10 ++-- .../KeyPropertyConventionTests.cs | 10 ++-- .../ManyToOneConventionTests.cs | 12 ++-- .../PropertyConventionTests.cs | 12 ++-- .../SubclassConventionTests.cs | 12 ++-- .../VersionConventionTests.cs | 12 ++-- .../ConventionsTests/ProxyConventionTester.cs | 6 +- .../RunnableConventionsTests.cs | 30 +++++----- .../DomainModel/ConnectedTester.cs | 2 +- .../DomainModel/Employees.cs | 2 +- .../DomainModel/InverseOneToManyTester.cs | 2 +- .../Mapping/CascadeExpressionTester.cs | 2 +- .../DomainModel/Mapping/ClassCacheTests.cs | 2 +- .../CollectionCascadeExpressionTester.cs | 2 +- .../Mapping/ComponentElementPartTester.cs | 4 +- .../Mapping/ComponentPropertyMapTester.cs | 2 +- .../Mapping/FetchTypeExpressionTester.cs | 4 +- .../DomainModel/Mapping/FilterTester.cs | 2 +- .../DomainModel/Mapping/IdentityPartTester.cs | 2 +- .../DomainModel/Mapping/JoinPartTester.cs | 4 +- .../Mapping/JoinedSubClassTester.cs | 6 +- .../Mapping/ManyToManyIntegrationTester.cs | 6 +- ...ySelfReferencedInverseIntegrationTester.cs | 2 +- .../DomainModel/Mapping/ManyToManyTester.cs | 2 +- .../DomainModel/Mapping/MappingTester.cs | 4 +- .../Mapping/OneToManyIntegrationTester.cs | 6 +- .../DomainModel/Mapping/OneToManyTester.cs | 6 +- .../DomainModel/Mapping/OneToOneTester.cs | 10 ++-- .../DomainModel/Mapping/PropertyPartTester.cs | 2 +- .../DomainModel/Mapping/SubClassTester.cs | 2 +- .../DomainModel/Mapping/VersionTester.cs | 2 +- .../DomainModel/RevealTests.cs | 12 ++-- src/FluentNHibernate.Testing/EmptySource.cs | 2 +- .../ExpressionToSqlTests.cs | 6 +- .../ClassMapFilterPartModelGenerationTests.cs | 4 +- .../FluentInterfaceTests/ColumnPartTests.cs | 4 +- .../FluentInterfaceTests/CustomPersister.cs | 4 +- .../FluentInterfaceTests/CustomProxy.cs | 4 +- .../FluentInterfaceTests/IdGeneratorTests.cs | 6 +- ...lassMutablePropertyModelGenerationTests.cs | 2 +- .../KeyManyToOnePartTests.cs | 5 +- .../KeyPropertyPartTests.cs | 4 +- .../ManyToManyTableNameTests.cs | 2 +- .../FluentInterfaceTests/ModelTester.cs | 2 +- .../PropertyEnumerablesTests.cs | 4 +- ...lassMapForJoinedSubclassConventionTests.cs | 6 +- ...lassMutablePropertyModelGenerationTests.cs | 2 +- ...lassMutablePropertyModelGenerationTests.cs | 2 +- ...pForSubclassSubPartModelGenerationTests.cs | 6 +- .../SubclassMapWithUserTypeTests.cs | 2 +- ...lassMutablePropertyModelGenerationTests.cs | 2 +- .../TablePerHierarchyTests.cs | 4 +- .../FluentInterfaceTests/WhereTests.cs | 16 ++--- .../Infrastructure/ContainerTester.cs | 6 +- .../MappingModel/AttributeStoreTester.cs | 2 +- .../MappingModel/ClassMappingTester.cs | 2 +- .../Defaults/PropertyColumnDefaultsTester.cs | 2 +- .../MappingModel/Output/XmlAnyWriterTester.cs | 2 +- .../Output/XmlArrayWriterTester.cs | 2 +- .../MappingModel/Output/XmlBagWriterTester.cs | 2 +- .../Output/XmlCacheWriterTester.cs | 2 +- .../Output/XmlClassWriterTester.cs | 2 +- .../XmlCollectionRelationshipWriterTester.cs | 2 +- .../Output/XmlCollectionWriterTester.cs | 2 +- .../Output/XmlColumnWriterTester.cs | 2 +- .../Output/XmlComponentWriterTester.cs | 4 +- .../Output/XmlCompositeElementWriterTester.cs | 2 +- .../Output/XmlCompositeIdWriterTester.cs | 2 +- .../Output/XmlDiscriminatorWriterTester.cs | 2 +- .../Output/XmlDynamicComponentWriterTester.cs | 4 +- .../Output/XmlElementWriterTester.cs | 2 +- .../Output/XmlGeneratorWriterTester.cs | 2 +- .../Output/XmlHibernateMappingWriterTester.cs | 2 +- .../Output/XmlIIndexWriterTester.cs | 2 +- .../MappingModel/Output/XmlIdWriterTester.cs | 2 +- .../Output/XmlIdentityBasedWriterTester.cs | 2 +- .../Output/XmlIndexManyToManyWriterTester.cs | 2 +- .../Output/XmlIndexWriterTester.cs | 2 +- .../Output/XmlInheritanceWriterTester.cs | 2 +- .../Output/XmlJoinWriterTester.cs | 2 +- .../Output/XmlJoinedSubclassWriterTester.cs | 4 +- .../Output/XmlKeyManyToOneWriterTester.cs | 2 +- .../Output/XmlKeyPropertyWriterTester.cs | 2 +- .../MappingModel/Output/XmlKeyWriterTester.cs | 2 +- .../Output/XmlListWriterTester.cs | 2 +- .../Output/XmlManyToManyWriterTester.cs | 2 +- .../Output/XmlManyToOneWriterTester.cs | 2 +- .../MappingModel/Output/XmlMapWriterTester.cs | 2 +- .../Output/XmlMetaValueWriterTester.cs | 2 +- .../Output/XmlNaturalIdWriterTester.cs | 2 +- .../Output/XmlOneToManyWriterTester.cs | 2 +- .../Output/XmlOneToOneWriterTester.cs | 2 +- .../Output/XmlPropertyWriterTester.cs | 2 +- .../XmlReferenceComponentWriterTester.cs | 11 ++-- .../MappingModel/Output/XmlSetWriterTester.cs | 2 +- .../Output/XmlStoredProcedureWriterTester.cs | 2 +- .../Output/XmlSubclassWriterTester.cs | 4 +- .../Output/XmlTuplizerWriterTester.cs | 2 +- .../Output/XmlVersionWriterTester.cs | 2 +- .../Output/XmlWriterContainerTester.cs | 2 +- .../ReferenceComponentMappingSpecs.cs | 23 +++---- .../JoinPersistenceModelTests.cs | 4 +- .../SeparateSubclassVisitorFixture.cs | 30 +++++----- .../StubTypeSource.cs | 4 +- ...PersistenceSpecificationExtensionsSpecs.cs | 24 ++++---- .../Testing/PersistenceSpecificationTester.cs | 16 ++--- ...PersistenceSpecificationTransactionTest.cs | 4 +- .../SessionSourceConfigurationTester.cs | 4 +- .../Testing/Values/Entities.cs | 4 +- .../Testing/Values/ListSpecs.cs | 4 +- .../Testing/Values/PropertySpecs.cs | 6 +- .../Testing/Values/ReferenceListSpecs.cs | 8 +-- .../Testing/Values/ReferencePropertySpecs.cs | 8 +-- .../Utils/TypeReferenceEnumTests.cs | 2 +- .../ComponentColumnPrefixVisitorSpecs.cs | 16 ++--- ...omponentReferenceResolutionVisitorSpecs.cs | 4 +- .../Automapping/AutoJoinedSubClassPart.cs | 4 +- .../Automapping/AutoMapper.cs | 6 +- .../AutoMappingAlterationCollection.cs | 4 +- .../Automapping/AutoMappingExpressions.cs | 2 +- .../Automapping/AutoPersistenceModel.cs | 14 ++--- .../Automapping/AutoSubClassPart.cs | 4 +- .../Automapping/Steps/HasManyToManyStep.cs | 4 +- .../Automapping/Steps/PropertyStep.cs | 6 +- .../Automapping/Steps/ReferenceStep.cs | 4 +- .../Steps/SimpleTypeCollectionStep.cs | 2 +- .../Cfg/AutoMappingsContainer.cs | 6 +- .../Cfg/Db/CacheSettingsBuilder.cs | 4 +- .../Cfg/Db/ConnectionStringBuilder.cs | 2 +- .../Cfg/Db/DB2ConnectionStringBuilder.cs | 8 +-- .../Cfg/Db/IfxDRDAConnectionStringBuilder.cs | 22 +++---- .../Cfg/Db/IfxSQLIConnectionStringBuilder.cs | 26 ++++---- .../Cfg/Db/IngresConnectionStringBuilder.cs | 10 ++-- .../Db/JetDriverConnectionStringBuilder.cs | 8 +-- .../Cfg/Db/MsSqlConnectionStringBuilder.cs | 10 ++-- .../Cfg/Db/MySQLConnectionStringBuilder.cs | 10 ++-- .../Cfg/Db/OdbcConnectionStringBuilder.cs | 8 +-- .../Cfg/Db/OracleConnectionStringBuilder.cs | 17 +++--- .../Db/PostgreSQLConnectionStringBuilder.cs | 10 ++-- ...ybaseSQLAnywhereConnectionStringBuilder.cs | 8 +-- .../Cfg/FluentConfiguration.cs | 2 +- .../Cfg/HbmMappingsContainer.cs | 4 +- .../ConcreteAcceptanceCriteria.cs | 2 +- .../Conventions/ConventionsCollection.cs | 6 +- .../Conventions/DefaultConventionFinder.cs | 14 ++--- .../Helpers/Builders/BagConventionBuilder.cs | 2 +- .../Builders/HasManyConventionBuilder.cs | 2 +- .../HasManyToManyConventionBuilder.cs | 2 +- .../Helpers/Builders/ListConventionBuilder.cs | 2 +- .../Helpers/Builders/MapConventionBuilder.cs | 2 +- .../Helpers/Builders/SetConventionBuilder.cs | 2 +- .../Helpers/Prebuilt/BuiltArrayConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltBagConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltClassConvention.cs | 2 +- .../Prebuilt/BuiltCompositeIdConvention.cs | 2 +- .../Prebuilt/BuiltHasManyConvention.cs | 2 +- .../Prebuilt/BuiltHasManyToManyConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltHasOneConvention.cs | 2 +- .../BuiltHibernateMappingConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltIdConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltJoinConvention.cs | 2 +- .../Prebuilt/BuiltJoinedSubclassConvention.cs | 2 +- .../Prebuilt/BuiltKeyManyToOneConvention.cs | 2 +- .../Prebuilt/BuiltKeyPropertyConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltListConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltMapConvention.cs | 2 +- .../Prebuilt/BuiltPropertyConvention.cs | 2 +- .../Prebuilt/BuiltReferenceConvention.cs | 2 +- .../Helpers/Prebuilt/BuiltSetConvention.cs | 2 +- .../Prebuilt/BuiltSubclassConvention.cs | 2 +- .../Prebuilt/BuiltVersionConvention.cs | 2 +- .../Conventions/Inspections/AnyInspector.cs | 4 +- .../Conventions/Inspections/CacheInspector.cs | 2 +- .../Conventions/Inspections/Cascade.cs | 6 +- .../Conventions/Inspections/ClassInspector.cs | 4 +- .../Inspections/ColumnBasedInspector.cs | 2 +- .../Inspections/ColumnInspector.cs | 2 +- .../Inspections/ComponentInspector.cs | 4 +- .../Inspections/CompositeElementInspector.cs | 2 +- .../Inspections/CompositeIdentityInspector.cs | 2 +- .../Inspections/DiscriminatorInspector.cs | 4 +- .../Inspections/DynamicComponentInspector.cs | 4 +- .../Inspections/ElementInspector.cs | 2 +- .../Conventions/Inspections/Fetch.cs | 6 +- .../Conventions/Inspections/Generated.cs | 4 +- .../Inspections/HibernateMappingInspector.cs | 2 +- .../Inspections/IGeneratorInspector.cs | 2 +- .../Inspections/IdentityInspector.cs | 4 +- .../Conventions/Inspections/Include.cs | 4 +- .../Conventions/Inspections/IndexInspector.cs | 2 +- .../Inspections/IndexManyToManyInspector.cs | 2 +- .../Inspections/InspectorModelMapper.cs | 4 +- .../Conventions/Inspections/JoinInspector.cs | 2 +- .../Conventions/Inspections/JoinInstance.cs | 4 +- .../Inspections/JoinedSubclassInspector.cs | 4 +- .../Conventions/Inspections/KeyInspector.cs | 2 +- .../Inspections/KeyManyToOneInspector.cs | 4 +- .../Inspections/KeyPropertyInspector.cs | 2 +- .../Inspections/ManyToManyInspector.cs | 4 +- .../Inspections/ManyToOneInspector.cs | 4 +- .../Inspections/MetaValueInspector.cs | 2 +- .../Conventions/Inspections/NotFound.cs | 4 +- .../Conventions/Inspections/OnDelete.cs | 4 +- .../Inspections/OneToManyInspector.cs | 2 +- .../Inspections/OneToOneInspector.cs | 4 +- .../Conventions/Inspections/OptimisticLock.cs | 4 +- .../Inspections/ParentInspector.cs | 2 +- .../Conventions/Inspections/Polymorphism.cs | 4 +- .../Conventions/Inspections/Prefix.cs | 2 +- .../Inspections/PropertyInspector.cs | 4 +- .../Conventions/Inspections/SchemaAction.cs | 6 +- .../Inspections/SubclassInspector.cs | 4 +- .../Inspections/VersionInspector.cs | 4 +- .../Conventions/Instances/AnyInstance.cs | 2 +- .../Conventions/Instances/ClassInstance.cs | 4 +- .../Instances/CollectionCascadeInstance.cs | 2 +- .../Conventions/Instances/ColumnInstance.cs | 2 +- .../Instances/ComponentInstance.cs | 2 +- .../Instances/CompositeIdentityInstance.cs | 4 +- .../Instances/DynamicComponentInstance.cs | 2 +- .../Conventions/Instances/ElementInstance.cs | 2 +- .../Instances/GeneratorInstance.cs | 2 +- .../Instances/HibernateMappingInstance.cs | 4 +- .../Conventions/Instances/IdentityInstance.cs | 4 +- .../Conventions/Instances/IndexInstance.cs | 2 +- .../Instances/IndexManyToManyInstance.cs | 2 +- .../Instances/JoinedSubclassInstance.cs | 4 +- .../Conventions/Instances/KeyInstance.cs | 2 +- .../Instances/KeyManyToOneInstance.cs | 4 +- .../Instances/KeyPropertyInstance.cs | 2 +- .../Instances/ManyToManyCollectionInstance.cs | 2 +- .../Instances/ManyToManyInstance.cs | 2 +- .../Instances/ManyToOneInstance.cs | 4 +- .../Instances/OneToManyCollectionInstance.cs | 2 +- .../Instances/OneToManyInstance.cs | 2 +- .../Conventions/Instances/OneToOneInstance.cs | 4 +- .../Conventions/Instances/PropertyInstance.cs | 6 +- .../Conventions/Instances/SubclassInstance.cs | 4 +- .../Conventions/ProxyConvention.cs | 4 +- src/FluentNHibernate/Driver/MsSQLiteDriver.cs | 2 +- .../Infrastructure/Container.cs | 2 +- .../NetStandardSerialization.cs | 28 ++++----- src/FluentNHibernate/Mapping/Access.cs | 6 +- .../Mapping/BaseAccessStrategyBuilder.cs | 10 ++-- src/FluentNHibernate/Mapping/ClassMap.cs | 2 +- .../Mapping/ClasslikeMapBase.cs | 4 +- .../Mapping/ColumnMappingCollection.cs | 2 +- src/FluentNHibernate/Mapping/ColumnPart.cs | 2 +- src/FluentNHibernate/Mapping/ComponentPart.cs | 8 +-- .../Mapping/DiscriminatorValue.cs | 4 +- .../Mapping/FilterDefinition.cs | 4 +- .../Mapping/GeneratorBuilder.cs | 14 ++--- .../IdentityGenerationStrategyBuilder.cs | 8 +-- .../Mapping/KeyManyToOnePart.cs | 4 +- .../Mapping/KeyPropertyPart.cs | 2 +- .../Mapping/ManyToManyPart.cs | 16 ++--- src/FluentNHibernate/Mapping/Member.cs | 6 +- src/FluentNHibernate/Mapping/OneToManyPart.cs | 10 ++-- .../Mapping/OptimisticLockBuilder.cs | 2 +- src/FluentNHibernate/Mapping/Prefix.cs | 2 +- ...minateSubclassMappingProviderCollection.cs | 4 +- src/FluentNHibernate/Mapping/SubClassPart.cs | 12 ++-- .../ClassBased/ComponentMappingBase.cs | 2 +- .../MappingModel/ClassBased/ComponentType.cs | 2 +- .../ClassBased/ReferenceComponentMapping.cs | 8 +-- .../MappingModel/ClassBased/SubclassType.cs | 2 +- .../Identity/CompositeIdMapping.cs | 4 +- .../MappingModel/JoinMapping.cs | 4 +- .../MappingModel/MappedMembers.cs | 8 +-- .../MappingModel/MetaValueMapping.cs | 2 +- .../MappingModel/NaturalIdMapping.cs | 6 +- .../MappingModel/OneToOneMapping.cs | 2 +- .../Output/BaseXmlComponentWriter.cs | 2 +- .../Output/MappingXmlSerializer.cs | 2 +- .../Output/Sorting/XmlClasslikeNodeSorter.cs | 2 +- .../MappingModel/Output/XmlAnyWriter.cs | 2 +- .../MappingModel/Output/XmlCacheWriter.cs | 2 +- .../MappingModel/Output/XmlClassWriter.cs | 2 +- .../Output/XmlCollectionRelationshipWriter.cs | 2 +- .../Output/XmlCollectionWriter.cs | 2 +- .../MappingModel/Output/XmlColumnWriter.cs | 2 +- .../MappingModel/Output/XmlComponentWriter.cs | 2 +- .../Output/XmlCompositeIdWriter.cs | 2 +- .../Output/XmlDiscriminatorWriter.cs | 2 +- .../MappingModel/Output/XmlElementWriter.cs | 2 +- .../Output/XmlFilterDefinitionWriter.cs | 2 +- .../MappingModel/Output/XmlFilterWriter.cs | 2 +- .../MappingModel/Output/XmlGeneratorWriter.cs | 2 +- .../Output/XmlHibernateMappingWriter.cs | 2 +- .../MappingModel/Output/XmlIIndexWriter.cs | 2 +- .../MappingModel/Output/XmlIdWriter.cs | 2 +- .../Output/XmlIdentityBasedWriter.cs | 2 +- .../MappingModel/Output/XmlImportWriter.cs | 2 +- .../Output/XmlIndexManyToManyWriter.cs | 2 +- .../MappingModel/Output/XmlIndexWriter.cs | 2 +- .../MappingModel/Output/XmlJoinWriter.cs | 2 +- .../Output/XmlKeyManyToOneWriter.cs | 2 +- .../Output/XmlKeyPropertyWriter.cs | 2 +- .../MappingModel/Output/XmlKeyWriter.cs | 2 +- .../Output/XmlManyToManyWriter.cs | 2 +- .../MappingModel/Output/XmlManyToOneWriter.cs | 2 +- .../MappingModel/Output/XmlMapWriter.cs | 2 +- .../MappingModel/Output/XmlMetaValueWriter.cs | 2 +- .../MappingModel/Output/XmlNaturalIdWriter.cs | 2 +- .../MappingModel/Output/XmlOneToManyWriter.cs | 2 +- .../MappingModel/Output/XmlOneToOneWriter.cs | 2 +- .../MappingModel/Output/XmlParentWriter.cs | 2 +- .../MappingModel/Output/XmlPropertyWriter.cs | 2 +- .../Output/XmlStoredProcedureWriter.cs | 2 +- .../MappingModel/Output/XmlSubclassWriter.cs | 2 +- .../MappingModel/Output/XmlTuplizerWriter.cs | 2 +- .../MappingModel/Output/XmlVersionWriter.cs | 2 +- .../MappingModel/Output/XmlWriterContainer.cs | 6 +- .../MappingModel/Output/XmlWriterFactory.cs | 2 +- .../MappingModel/ParentMapping.cs | 2 +- .../MappingModel/StoredProcedureMapping.cs | 2 +- .../MappingModel/TypeReference.cs | 2 +- .../PersistenceSpecificationExtensions.cs | 2 +- ...onSessionSourceForSQLiteInMemoryTesting.cs | 2 +- src/FluentNHibernate/Utils/ExpressionToSql.cs | 14 ++--- .../Utils/ObservableDictionary.cs | 20 +++---- .../Utils/Reflection/PropertyChain.cs | 6 +- .../Utils/Reflection/ReflectionHelper.cs | 14 ++--- .../Visitors/ComponentColumnPrefixVisitor.cs | 8 +-- .../Visitors/SeparateSubclassVisitor.cs | 12 ++-- 419 files changed, 1036 insertions(+), 1025 deletions(-) diff --git a/.editorconfig b/.editorconfig index 91e672525..8734e9995 100644 --- a/.editorconfig +++ b/.editorconfig @@ -15,13 +15,16 @@ max_line_length = off csharp_style_namespace_declarations = file_scoped dotnet_diagnostic.ide0161.severity = warning -dotnet_diagnostic.NUnit1032.severity = suggestion -dotnet_diagnostic.NUnit1028.severity = none -dotnet_diagnostic.NUnit2045.severity = none +dotnet_diagnostic.nunit1032.severity = suggestion +dotnet_diagnostic.nunit1028.severity = none +dotnet_diagnostic.nunit2045.severity = none # ReSharper properties resharper_default_private_modifier = implicit +# Microsoft .NET properties +dotnet_style_require_accessibility_modifiers = never:suggestion + [*.cake] indent_style = space indent_size = 4 diff --git a/src/Examples.FirstAutomappedProject/Program.cs b/src/Examples.FirstAutomappedProject/Program.cs index 91916ddba..9d7a5b086 100644 --- a/src/Examples.FirstAutomappedProject/Program.cs +++ b/src/Examples.FirstAutomappedProject/Program.cs @@ -22,7 +22,7 @@ namespace Examples.FirstAutomappedProject; /// class Program { - private const string DbFile = "firstProgram.db"; + const string DbFile = "firstProgram.db"; static void Main() { @@ -110,7 +110,7 @@ static AutoPersistenceModel CreateAutomappings() /// 7: Finally, build the session factory. /// /// - private static ISessionFactory CreateSessionFactory() + static ISessionFactory CreateSessionFactory() { return Fluently.Configure() .Database(SQLiteConfiguration.Standard @@ -121,7 +121,7 @@ private static ISessionFactory CreateSessionFactory() .BuildSessionFactory(); } - private static void BuildSchema(Configuration config) + static void BuildSchema(Configuration config) { // delete the existing db on each run if (File.Exists(DbFile)) @@ -133,7 +133,7 @@ private static void BuildSchema(Configuration config) .Create(false, true); } - private static void WriteStorePretty(Store store) + static void WriteStorePretty(Store store) { Console.WriteLine(store.Name); Console.WriteLine(" Products:"); diff --git a/src/Examples.FirstProject/Program.cs b/src/Examples.FirstProject/Program.cs index 69a647b36..fec38ebd4 100644 --- a/src/Examples.FirstProject/Program.cs +++ b/src/Examples.FirstProject/Program.cs @@ -11,7 +11,7 @@ namespace Examples.FirstProject; class Program { - private const string DbFile = "firstProgram.db"; + const string DbFile = "firstProgram.db"; static void Main() { @@ -76,7 +76,7 @@ static void Main() Console.ReadKey(); } - private static ISessionFactory CreateSessionFactory() + static ISessionFactory CreateSessionFactory() { return Fluently.Configure() .Database(SQLiteConfiguration.Standard @@ -87,7 +87,7 @@ private static ISessionFactory CreateSessionFactory() .BuildSessionFactory(); } - private static void BuildSchema(Configuration config) + static void BuildSchema(Configuration config) { // delete the existing db on each run if (File.Exists(DbFile)) @@ -99,7 +99,7 @@ private static void BuildSchema(Configuration config) .Create(false, true); } - private static void WriteStorePretty(Store store) + static void WriteStorePretty(Store store) { Console.WriteLine(store.Name); Console.WriteLine(" Products:"); diff --git a/src/FluentNHibernate.Specs/Automapping/AutoPersistenceModelSpecs.cs b/src/FluentNHibernate.Specs/Automapping/AutoPersistenceModelSpecs.cs index d093205b1..16b1cac30 100644 --- a/src/FluentNHibernate.Specs/Automapping/AutoPersistenceModelSpecs.cs +++ b/src/FluentNHibernate.Specs/Automapping/AutoPersistenceModelSpecs.cs @@ -62,7 +62,7 @@ public class when_the_automapper_is_ran_to_completion static FluentConfiguration setup; static Exception ex; - private static IPersistenceConfigurer CreateStandardInMemoryConfiguration() + static IPersistenceConfigurer CreateStandardInMemoryConfiguration() { #if NETFRAMEWORK var configuration = SQLiteConfiguration.Standard.InMemory(); diff --git a/src/FluentNHibernate.Specs/Automapping/AutomappingSpecs.NestedClasses.cs b/src/FluentNHibernate.Specs/Automapping/AutomappingSpecs.NestedClasses.cs index 271706399..331a1c968 100644 --- a/src/FluentNHibernate.Specs/Automapping/AutomappingSpecs.NestedClasses.cs +++ b/src/FluentNHibernate.Specs/Automapping/AutomappingSpecs.NestedClasses.cs @@ -83,7 +83,8 @@ public class PublicAddress { public int Id { get; set; } } - private class PrivateAddress + + class PrivateAddress { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Specs/Automapping/Fixtures/StubTypeSource.cs b/src/FluentNHibernate.Specs/Automapping/Fixtures/StubTypeSource.cs index f2cbf96ae..4f7060fb3 100644 --- a/src/FluentNHibernate.Specs/Automapping/Fixtures/StubTypeSource.cs +++ b/src/FluentNHibernate.Specs/Automapping/Fixtures/StubTypeSource.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.Specs.Automapping.Fixtures; -internal class StubTypeSource(params Type[] types) : ITypeSource +class StubTypeSource(params Type[] types) : ITypeSource { public IEnumerable GetTypes() { diff --git a/src/FluentNHibernate.Specs/Automapping/OverrideSpecs.cs b/src/FluentNHibernate.Specs/Automapping/OverrideSpecs.cs index 7779f6014..a93c82ef9 100644 --- a/src/FluentNHibernate.Specs/Automapping/OverrideSpecs.cs +++ b/src/FluentNHibernate.Specs/Automapping/OverrideSpecs.cs @@ -36,13 +36,13 @@ public class when_using_an_automapping_override_to_create_a_join public class when_using_an_automapping_override_to_specify_a_discriminators_and_join_on_subclass { - private Establish context = () => + Establish context = () => model = AutoMap.Source(new StubTypeSource(typeof (Parent), typeof (Child))) .Override(map => map.DiscriminateSubClassesOnColumn("type")) .Override(map => map.Join("table", part => { })); - private Because of = () => + Because of = () => mapping = model.BuildMappingFor(); It should_not_create_the_join_mapping = () => diff --git a/src/FluentNHibernate.Specs/Conventions/ComponentConventionSpecs.cs b/src/FluentNHibernate.Specs/Conventions/ComponentConventionSpecs.cs index 6a45da631..8563ea7d9 100644 --- a/src/FluentNHibernate.Specs/Conventions/ComponentConventionSpecs.cs +++ b/src/FluentNHibernate.Specs/Conventions/ComponentConventionSpecs.cs @@ -31,8 +31,8 @@ public class when_specifying_component_convention property.Columns.FirstOrDefault().Name.Should().Be("different"); }; - private static FluentNHibernate.PersistenceModel model; - private static ClassMapping mapping; + static FluentNHibernate.PersistenceModel model; + static ClassMapping mapping; } public class EntityWithComponent @@ -49,7 +49,7 @@ public class Address public string Line2 { get; set; } } -internal class AddressMap : ComponentMap
+class AddressMap : ComponentMap
{ public AddressMap() { diff --git a/src/FluentNHibernate.Specs/FluentInterface/ClassMapSpecs/ClassMapSpecs.Component.cs b/src/FluentNHibernate.Specs/FluentInterface/ClassMapSpecs/ClassMapSpecs.Component.cs index 4983e6146..315ab8c39 100644 --- a/src/FluentNHibernate.Specs/FluentInterface/ClassMapSpecs/ClassMapSpecs.Component.cs +++ b/src/FluentNHibernate.Specs/FluentInterface/ClassMapSpecs/ClassMapSpecs.Component.cs @@ -33,9 +33,9 @@ public class when_class_map_is_told_to_map_a_component_using_a_provider : Provid Behaves_like a_component_in_a_classlike; - protected static ClassMapping mapping; + protected static ClassMapping mapping; - private class ComponentMappingProviderStub : IComponentMappingProvider + class ComponentMappingProviderStub : IComponentMappingProvider { public IComponentMapping GetComponentMapping() { diff --git a/src/FluentNHibernate.Specs/FluentInterface/ComponentMapSpecs.cs b/src/FluentNHibernate.Specs/FluentInterface/ComponentMapSpecs.cs index 567df39ec..1b70fb16a 100644 --- a/src/FluentNHibernate.Specs/FluentInterface/ComponentMapSpecs.cs +++ b/src/FluentNHibernate.Specs/FluentInterface/ComponentMapSpecs.cs @@ -47,10 +47,10 @@ public class when_creating_the_mapping_for_a_component_using_component_map It should_add_references_to_the_references_collection = () => mapping.References.ShouldContain(x => x.Name == "a_reference"); - private static ComponentMap component; - private static ComponentMapping mapping; + static ComponentMap component; + static ComponentMapping mapping; - private class Target + class Target { public string a_property { get; set; } public Target an_any { get; set; } @@ -83,16 +83,16 @@ public class when_mapping_a_component_in_an_entity_without_defining_any_mappings It should_store_the_property_in_the_reference_component_mapping = () => (mapping as ReferenceComponentMapping).Member.Name.Should().Be("Component"); - private static ClassMap classmap; - private static IComponentMapping mapping; + static ClassMap classmap; + static IComponentMapping mapping; - private class Target + class Target { public int Id { get; set; } public Component Component { get; set;} } - private class Component {} + class Component {} } public class when_compiling_the_mappings_with_a_reference_component_in_a_subclass @@ -131,21 +131,21 @@ public class when_compiling_the_mappings_with_a_reference_component_in_a_subclas component_mapping.Properties.ShouldContain(x => x.Name == "Property"); }; - private static FluentNHibernate.PersistenceModel persistence_model; - private static IEnumerable mappings; - private static ClassMapping class_mapping; + static FluentNHibernate.PersistenceModel persistence_model; + static IEnumerable mappings; + static ClassMapping class_mapping; - private class Target + class Target { public int Id { get; set; } } - private class TargetChild : Target + class TargetChild : Target { public Component Component { get; set; } } - private class Component + class Component { public string Property { get; set; } } @@ -167,7 +167,7 @@ public class when_compiling_the_mappings_with_a_nested_reference_component_in_a_ static ComponentMap component_map; static Exception ex; - private class Component + class Component { public Component Compo { get; set; } } @@ -203,17 +203,17 @@ public class when_compiling_the_mappings_with_a_reference_component_and_a_relate component_mapping.Properties.ShouldContain(x => x.Name == "Property"); }; - private static FluentNHibernate.PersistenceModel persistence_model; - private static IEnumerable mappings; - private static ClassMapping class_mapping; + static FluentNHibernate.PersistenceModel persistence_model; + static IEnumerable mappings; + static ClassMapping class_mapping; - private class Target + class Target { public int Id { get; set; } public Component Component { get; set; } } - private class Component + class Component { public string Property { get; set; } } @@ -259,18 +259,18 @@ public class when_compiling_the_mappings_with_two_of_the_same_reference_componen .Should().Contain("B_PROP"); }; - private static FluentNHibernate.PersistenceModel persistence_model; - private static IEnumerable mappings; - private static ClassMapping class_mapping; + static FluentNHibernate.PersistenceModel persistence_model; + static IEnumerable mappings; + static ClassMapping class_mapping; - private class Target + class Target { public int Id { get; set; } public Component ComponentA { get; set; } public Component ComponentB { get; set; } } - private class Component + class Component { public string Property { get; set; } } @@ -316,23 +316,23 @@ public class when_compiling_the_mappings_with_multiple_nested_component_mappings .Should().Contain("A_PROP2"); }; - private static FluentNHibernate.PersistenceModel persistence_model; - private static IEnumerable mappings; - private static ClassMapping class_mapping; + static FluentNHibernate.PersistenceModel persistence_model; + static IEnumerable mappings; + static ClassMapping class_mapping; - private class Target + class Target { public int Id { get; set; } public Component Component { get; set; } } - private class Component + class Component { public NestedComponent NestedComponent1 { get; set; } public NestedComponent NestedComponent2 { get; set; } } - private class NestedComponent + class NestedComponent { public string Property { get; set; } } diff --git a/src/FluentNHibernate.Specs/FluentInterface/ExternalComponentOutputSpecs.cs b/src/FluentNHibernate.Specs/FluentInterface/ExternalComponentOutputSpecs.cs index 8eb5468d0..13ac1f23c 100644 --- a/src/FluentNHibernate.Specs/FluentInterface/ExternalComponentOutputSpecs.cs +++ b/src/FluentNHibernate.Specs/FluentInterface/ExternalComponentOutputSpecs.cs @@ -39,7 +39,7 @@ public class when_generating_the_output_for_a_resolved_component_reference referenced_xml.Should().Be(inline_xml); - private static string render_xml(Action addMappings) + static string render_xml(Action addMappings) { var model = new FluentNHibernate.PersistenceModel(); @@ -51,20 +51,20 @@ private static string render_xml(Action addMa return doc.OuterXml; } - private static ClassMap inline_component; - private static ClassMap reference_component; - private static ComponentMap external_component; - private static string inline_xml; - private static string referenced_xml; + static ClassMap inline_component; + static ClassMap reference_component; + static ComponentMap external_component; + static string inline_xml; + static string referenced_xml; - private class Target + class Target { public int Id { get; set;} public Component ComponentProperty1 { get; set; } public Component ComponentProperty2 { get; set; } } - private class Component + class Component { public string Property { get; set; } } diff --git a/src/FluentNHibernate.Specs/FluentInterface/Fixtures/EntityWithProperties.cs b/src/FluentNHibernate.Specs/FluentInterface/Fixtures/EntityWithProperties.cs index 6f0c326ea..38c9558ce 100644 --- a/src/FluentNHibernate.Specs/FluentInterface/Fixtures/EntityWithProperties.cs +++ b/src/FluentNHibernate.Specs/FluentInterface/Fixtures/EntityWithProperties.cs @@ -7,6 +7,6 @@ class EntityWithProperties class EntityWithPrivateProperties { - private string Name { get; set; } + string Name { get; set; } string name; } diff --git a/src/FluentNHibernate.Specs/Utilities/Fixtures/Target.cs b/src/FluentNHibernate.Specs/Utilities/Fixtures/Target.cs index bd5c0e1f2..91a125f56 100644 --- a/src/FluentNHibernate.Specs/Utilities/Fixtures/Target.cs +++ b/src/FluentNHibernate.Specs/Utilities/Fixtures/Target.cs @@ -2,9 +2,9 @@ namespace FluentNHibernate.Specs.Utilities.Fixtures; public class Target : TargetParent { - private int IntProperty { get; set; } - private string PrivateProperty { get; set; } - private string privateField; + int IntProperty { get; set; } + string PrivateProperty { get; set; } + string privateField; protected string ProtectedProperty { get; set; } protected string protectedField; public string PublicProperty { get; set; } diff --git a/src/FluentNHibernate.Specs/Utilities/Fixtures/TargetParent.cs b/src/FluentNHibernate.Specs/Utilities/Fixtures/TargetParent.cs index 5a119af4b..1dd7390c7 100644 --- a/src/FluentNHibernate.Specs/Utilities/Fixtures/TargetParent.cs +++ b/src/FluentNHibernate.Specs/Utilities/Fixtures/TargetParent.cs @@ -2,5 +2,5 @@ namespace FluentNHibernate.Specs.Utilities.Fixtures; public abstract class TargetParent { - private string SuperProperty { get; set; } + string SuperProperty { get; set; } } diff --git a/src/FluentNHibernate.Specs/Visitors/BiDirectionalManyToManyPairingVisitorSpecs.cs b/src/FluentNHibernate.Specs/Visitors/BiDirectionalManyToManyPairingVisitorSpecs.cs index cd84a1628..6eec5e63f 100644 --- a/src/FluentNHibernate.Specs/Visitors/BiDirectionalManyToManyPairingVisitorSpecs.cs +++ b/src/FluentNHibernate.Specs/Visitors/BiDirectionalManyToManyPairingVisitorSpecs.cs @@ -44,13 +44,13 @@ public class when_the_bi_directional_many_to_many_visitor_is_asked_to_pair_two_m static CollectionMapping membership_queues_in_user; static CollectionMapping supervised_queues_in_user; - private class User + class User { public IEnumerable GetMembershipQueues() { yield break; } public IEnumerable GetSupervisedQueues() { yield break; } } - private class Queue + class Queue { public IEnumerable GetMembers() { yield break; } public IEnumerable GetSupervisors() { yield break; } @@ -91,13 +91,13 @@ public class when_the_bi_directional_many_to_many_visitor_is_asked_to_pair_two_m static CollectionMapping eggs_in_queue; static Exception ex; - private class User + class User { public IEnumerable Bacon { get; set; } public IEnumerable Eggs { get; set; } } - private class Queue + class Queue { public IEnumerable Fish { get; set; } public IEnumerable Chips { get; set; } @@ -138,13 +138,13 @@ public class when_the_bi_directional_many_to_many_visitor_is_asked_to_pair_two_m static CollectionMapping eueues_in_user; static Exception ex; - private class User + class User { public IEnumerable GetWueues() { yield break; } public IEnumerable GetEueues() { yield break; } } - private class Queue + class Queue { public IEnumerable GetDsers() { yield break; } public IEnumerable GetFsers() { yield break; } @@ -180,12 +180,12 @@ public class when_the_bi_directional_many_to_many_visitor_is_asked_to_pair_a_man static CollectionMapping users2_in_queue; static CollectionMapping queues_in_user; - private class User + class User { public IEnumerable GetQueues() { yield break; } } - private class Queue + class Queue { public IEnumerable GetUsers() { yield break; } public IEnumerable GetUsers2() { yield break; } @@ -215,7 +215,7 @@ public class when_the_bi_directional_many_to_many_visitor_is_asked_to_pair_a_sel static CollectionMapping ancestors; static CollectionMapping descendants; - private class TreeNode + class TreeNode { public IEnumerable Ancestors { get; set; } public IEnumerable Descendants { get; set; } @@ -245,12 +245,12 @@ public class when_the_bi_directional_many_to_many_visitor_is_asked_to_pair_two_c static CollectionMapping users_in_queue; static CollectionMapping queues_in_user; - private class User + class User { public IEnumerable GetQueues() { yield break; } } - private class Queue + class Queue { public IEnumerable GetUsers() { yield break; } } diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationCollectionTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationCollectionTests.cs index 71044bef4..be5494edd 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationCollectionTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationCollectionTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.Automapping.Apm; [TestFixture] public class AlterationCollectionTests { - private AutoMappingAlterationCollection alterations; + AutoMappingAlterationCollection alterations; [SetUp] public void CreateAlterationsContainer() diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationTests.cs index b29f812e8..2b5b2d45e 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/AlterationTests.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.Automapping.Apm; [TestFixture] public class AlterationTests { - private AutoPersistenceModel model; + AutoPersistenceModel model; [SetUp] public void CreateAutoMapper() diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/AutoPersistenceModelTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/AutoPersistenceModelTests.cs index 4044aeda9..5628ef1df 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/AutoPersistenceModelTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/AutoPersistenceModelTests.cs @@ -80,7 +80,7 @@ public void ShouldUseAssignedGeneratorForStringIds() .Element("class/id/generator").HasAttribute("class", "assigned"); } - private class JoinedSubclassConvention : IJoinedSubclassConvention + class JoinedSubclassConvention : IJoinedSubclassConvention { public void Apply(IJoinedSubclassInstance instance) { @@ -89,7 +89,7 @@ public void Apply(IJoinedSubclassInstance instance) } } - private class TestIdConvention : IIdConvention + class TestIdConvention : IIdConvention { public void Apply(IIdentityInstance instance) { @@ -97,7 +97,7 @@ public void Apply(IIdentityInstance instance) } } - private class TestIdGeneratorConvention : IIdConvention + class TestIdGeneratorConvention : IIdConvention { public void Apply(IIdentityInstance instance) { @@ -105,7 +105,7 @@ public void Apply(IIdentityInstance instance) } } - private class TestClassConvention : IClassConvention + class TestClassConvention : IClassConvention { public void Apply(IClassInstance instance) { @@ -113,7 +113,7 @@ public void Apply(IClassInstance instance) } } - private class TestM2OConvention : IReferenceConvention + class TestM2OConvention : IReferenceConvention { public void Apply(IManyToOneInstance instance) { @@ -121,7 +121,7 @@ public void Apply(IManyToOneInstance instance) } } - private class TestO2MConvention : IHasManyConvention + class TestO2MConvention : IHasManyConvention { public void Apply(IOneToManyCollectionInstance instance) { diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/HasManyConventionTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/HasManyConventionTests.cs index 6d703c930..be00ce40c 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/HasManyConventionTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/HasManyConventionTests.cs @@ -39,7 +39,7 @@ public void ShouldBeAbleToSpecifyKeyColumnNameUsingForeignKeyConvention() .Key.Columns.First().Name.ShouldEqual("Targetxxx"); } - private class FKConvention : ForeignKeyConvention + class FKConvention : ForeignKeyConvention { protected override string GetKeyName(Member property, Type type) { @@ -47,7 +47,7 @@ protected override string GetKeyName(Member property, Type type) } } - private class HasManyConvention : IHasManyConvention + class HasManyConvention : IHasManyConvention { public void Apply(IOneToManyCollectionInstance instance) { @@ -56,14 +56,14 @@ public void Apply(IOneToManyCollectionInstance instance) } } -internal class Target +class Target { public int Id { get; set; } public IList Children { get; set; } public Child Child { get; set; } } -internal class Child +class Child { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/IdentityConventionTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/IdentityConventionTests.cs index 630b9b814..c208d4c70 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/IdentityConventionTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/IdentityConventionTests.cs @@ -24,7 +24,7 @@ public void ShouldBeAbleToSpecifyKeyInConvention() ((IdMapping)classMapping.Id).Columns.First().Name.ShouldEqual("xxx"); } - private class IdConvention : IIdConvention + class IdConvention : IIdConvention { public void Apply(IIdentityInstance instance) { @@ -33,7 +33,7 @@ public void Apply(IIdentityInstance instance) } } -internal class IdTarget +class IdTarget { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/ReferencesConventionTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/ReferencesConventionTests.cs index 9478b5d95..f8747f1f1 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/ReferencesConventionTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/ReferencesConventionTests.cs @@ -23,7 +23,7 @@ public void ShouldBeAbleToSpecifyKeyInConvention() .Columns.First().Name.ShouldEqual("xxx"); } - private class FKConvention : ForeignKeyConvention + class FKConvention : ForeignKeyConvention { protected override string GetKeyName(Member property, Type type) { diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/VersionConventionTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/VersionConventionTests.cs index d9717ed4a..c61c5e918 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/VersionConventionTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/Conventions/VersionConventionTests.cs @@ -23,7 +23,7 @@ public void ShouldBeAbleToSpecifyColumnInConvention() classMapping.Version.Columns.First().Name.ShouldEqual("xxx"); } - private class VersionConvention : IVersionConvention + class VersionConvention : IVersionConvention { public void Apply(IVersionInstance instance) { @@ -32,7 +32,7 @@ public void Apply(IVersionInstance instance) } } -internal class VersionTarget +class VersionTarget { public int Id { get; set; } public byte[] Version { get; set; } diff --git a/src/FluentNHibernate.Testing/AutoMapping/Apm/IgnoreBaseAutoPersistenceModelTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Apm/IgnoreBaseAutoPersistenceModelTests.cs index 195639e48..3d7e51513 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Apm/IgnoreBaseAutoPersistenceModelTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Apm/IgnoreBaseAutoPersistenceModelTests.cs @@ -36,10 +36,10 @@ public void ShouldntMapAnyTypesIgnoredByIgnoreBase() } } -internal class Entity +class Entity { public int Id { get; set; } } -internal class RealBase : Entity +class RealBase : Entity {} diff --git a/src/FluentNHibernate.Testing/AutoMapping/BaseAutoMapFixture.cs b/src/FluentNHibernate.Testing/AutoMapping/BaseAutoMapFixture.cs index c8cf01799..c1313c0b2 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/BaseAutoMapFixture.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/BaseAutoMapFixture.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Testing.Automapping; public abstract class BaseAutoMapFixture { - private Configuration cfg; - private AutoPersistenceModel apm; + Configuration cfg; + AutoPersistenceModel apm; [SetUp] public void CreateDatabaseCfg() diff --git a/src/FluentNHibernate.Testing/AutoMapping/Overrides/AutoMappingOverrideAlterationTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Overrides/AutoMappingOverrideAlterationTests.cs index 5700c95a7..cb187fddc 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Overrides/AutoMappingOverrideAlterationTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Overrides/AutoMappingOverrideAlterationTests.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.AutoMapping.Overrides; [TestFixture] public class AutoMappingOverrideAlterationTests { - private AutoMappingOverrideAlteration alteration; + AutoMappingOverrideAlteration alteration; [SetUp] public void CreateOverride() diff --git a/src/FluentNHibernate.Testing/AutoMapping/Overrides/CompositeIdOverrides.cs b/src/FluentNHibernate.Testing/AutoMapping/Overrides/CompositeIdOverrides.cs index ad4406db9..08b60d3c2 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Overrides/CompositeIdOverrides.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Overrides/CompositeIdOverrides.cs @@ -83,7 +83,7 @@ public void ShouldMapEnumIdAsOverridenType() }); } - private void VerifyMapping(AutoPersistenceModel model, Action verifier) + void VerifyMapping(AutoPersistenceModel model, Action verifier) { var idMapping = model.BuildMappings() .First() @@ -97,20 +97,20 @@ private void VerifyMapping(AutoPersistenceModel model, Action x.Entity); } - private ReferenceStep mapper; + ReferenceStep mapper; [SetUp] public void CreateMapper() diff --git a/src/FluentNHibernate.Testing/AutoMapping/Steps/VersionStepTests.cs b/src/FluentNHibernate.Testing/AutoMapping/Steps/VersionStepTests.cs index b8fc24998..e7fee475a 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/Steps/VersionStepTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/Steps/VersionStepTests.cs @@ -11,7 +11,7 @@ namespace FluentNHibernate.Testing.AutoMapping.Steps; [TestFixture] public class VersionStepTests { - private VersionStep mapper; + VersionStep mapper; [SetUp] public void CreateMapper() @@ -91,19 +91,19 @@ public void ShouldSetContainingEntityType() mapping.Version.ContainingEntityType.ShouldEqual(typeof(Target)); } - private class Target + class Target { public byte[] Version { get; set; } } - private class SubTarget : Target + class SubTarget : Target {} } [TestFixture] public class When_mapping_a_byte_array_version_property_and_the_version_property_is_on_a_base_class { - private VersionStep mapper; + VersionStep mapper; [SetUp] public void CreateMapper() @@ -161,11 +161,11 @@ public void ShouldMapByteArrayWithUnsavedValueOfNull() mapping.Version.UnsavedValue.ShouldEqual(null); } - private class Target : BaseEntityClass + class Target : BaseEntityClass { } - private class BaseEntityClass + class BaseEntityClass { public byte[] Version { get; set; } } diff --git a/src/FluentNHibernate.Testing/AutoMapping/VersionTests.cs b/src/FluentNHibernate.Testing/AutoMapping/VersionTests.cs index 1c40492c1..a326a6ca5 100644 --- a/src/FluentNHibernate.Testing/AutoMapping/VersionTests.cs +++ b/src/FluentNHibernate.Testing/AutoMapping/VersionTests.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.Automapping; [TestFixture] public class VersionTests : BaseAutoPersistenceTests { - private AutoMappingTester VerifyAutoMap() + AutoMappingTester VerifyAutoMap() { var autoMapper = AutoMap.Source(new StubTypeSource(typeof(TEntity))); diff --git a/src/FluentNHibernate.Testing/Cfg/Db/CacheSettingsBuilderTester.cs b/src/FluentNHibernate.Testing/Cfg/Db/CacheSettingsBuilderTester.cs index e2d614b21..302fb64c0 100644 --- a/src/FluentNHibernate.Testing/Cfg/Db/CacheSettingsBuilderTester.cs +++ b/src/FluentNHibernate.Testing/Cfg/Db/CacheSettingsBuilderTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.Cfg.Db; [TestFixture] public class CacheSettingsBuilderTester { - private CacheSettingsBuilderDouble cache; + CacheSettingsBuilderDouble cache; [SetUp] public void CreateCache() @@ -104,12 +104,12 @@ public void CanSetThemAll() HasProperty("cache.use_query_cache", "true"); } - private void HasProperty(string key, string value) + void HasProperty(string key, string value) { cache.Properties.ShouldContain(key, value); } - private class CacheSettingsBuilderDouble : CacheSettingsBuilder + class CacheSettingsBuilderDouble : CacheSettingsBuilder { public IDictionary Properties => Create(); } diff --git a/src/FluentNHibernate.Testing/Cfg/Db/ConnectionStringBuilderTester.cs b/src/FluentNHibernate.Testing/Cfg/Db/ConnectionStringBuilderTester.cs index bb9e53779..196612e61 100644 --- a/src/FluentNHibernate.Testing/Cfg/Db/ConnectionStringBuilderTester.cs +++ b/src/FluentNHibernate.Testing/Cfg/Db/ConnectionStringBuilderTester.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Testing.Cfg.Db; [TestFixture] public class ConnectionStringBuilderTester { - private ConnectionStringBuilderDouble builder; + ConnectionStringBuilderDouble builder; [SetUp] public void CreateBuilder() @@ -39,7 +39,7 @@ public void ConnectionStringSetFromConnectionStrings() } #endif - private class ConnectionStringBuilderDouble : ConnectionStringBuilder + class ConnectionStringBuilderDouble : ConnectionStringBuilder { public string ConnectionString => Create(); } diff --git a/src/FluentNHibernate.Testing/Cfg/Db/FirebirdConfigurationTester.cs b/src/FluentNHibernate.Testing/Cfg/Db/FirebirdConfigurationTester.cs index 26ddbe3a9..c1f28ba32 100644 --- a/src/FluentNHibernate.Testing/Cfg/Db/FirebirdConfigurationTester.cs +++ b/src/FluentNHibernate.Testing/Cfg/Db/FirebirdConfigurationTester.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Testing.Cfg.Db; [TestFixture] public class FirebirdConfigurationTester { - private FirebirdConfiguration _config; - private IDictionary _props; + FirebirdConfiguration _config; + IDictionary _props; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/Cfg/Db/PersistenceConfigurationTester.cs b/src/FluentNHibernate.Testing/Cfg/Db/PersistenceConfigurationTester.cs index 60ebcf992..e2165fbac 100644 --- a/src/FluentNHibernate.Testing/Cfg/Db/PersistenceConfigurationTester.cs +++ b/src/FluentNHibernate.Testing/Cfg/Db/PersistenceConfigurationTester.cs @@ -8,8 +8,9 @@ namespace FluentNHibernate.Testing.Cfg.Db; public class PersistenceConfigurationTester { #region Test Setup - private ConfigTester _config; - private Configuration _nhibConfig; + + ConfigTester _config; + Configuration _nhibConfig; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/Cfg/FluentConfigurationTests.cs b/src/FluentNHibernate.Testing/Cfg/FluentConfigurationTests.cs index 9ef5020f6..1992eee1d 100644 --- a/src/FluentNHibernate.Testing/Cfg/FluentConfigurationTests.cs +++ b/src/FluentNHibernate.Testing/Cfg/FluentConfigurationTests.cs @@ -218,9 +218,9 @@ public void Provider_Class_should_set_property_value() [TestFixture] public class InvalidFluentConfigurationTests { - private const string ExceptionMessage = "An invalid or incomplete configuration was used while creating a SessionFactory. Check PotentialReasons collection, and InnerException for more detail."; - private const string ExceptionDatabaseMessage = "Database was not configured through Database method."; - private const string ExceptionMappingMessage = "No mappings were configured through the Mappings method."; + const string ExceptionMessage = "An invalid or incomplete configuration was used while creating a SessionFactory. Check PotentialReasons collection, and InnerException for more detail."; + const string ExceptionDatabaseMessage = "Database was not configured through Database method."; + const string ExceptionMappingMessage = "No mappings were configured through the Mappings method."; [Test] public void BuildSessionFactoryShouldThrowIfCalledBeforeAnythingSetup() @@ -300,7 +300,7 @@ public void InnerExceptionSet() [TestFixture] public class FluentConfigurationWriteMappingsTests { - private string ExportPath; + string ExportPath; [SetUp] public void CreateTempDir() @@ -437,7 +437,7 @@ public void DoesNotThrowWhenExportToIsBeforeBuildConfigurationOnCachePartMapping .BuildConfiguration(); } - private static bool HbmFor(string path) + static bool HbmFor(string path) { return Path.GetFileName(path) == typeof(T).FullName + ".hbm.xml"; } diff --git a/src/FluentNHibernate.Testing/Cfg/MappingConfigurationTests.cs b/src/FluentNHibernate.Testing/Cfg/MappingConfigurationTests.cs index dc630309d..162d3fd1f 100644 --- a/src/FluentNHibernate.Testing/Cfg/MappingConfigurationTests.cs +++ b/src/FluentNHibernate.Testing/Cfg/MappingConfigurationTests.cs @@ -15,8 +15,8 @@ namespace FluentNHibernate.Testing.Cfg; [TestFixture] public class MappingConfigurationTests { - private Configuration cfg; - private MappingConfiguration mapping; + Configuration cfg; + MappingConfiguration mapping; IDiagnosticLogger logger; [SetUp] diff --git a/src/FluentNHibernate.Testing/ConventionFinderTests/AddingTypeTests.cs b/src/FluentNHibernate.Testing/ConventionFinderTests/AddingTypeTests.cs index c6534c901..fb3fc0b90 100644 --- a/src/FluentNHibernate.Testing/ConventionFinderTests/AddingTypeTests.cs +++ b/src/FluentNHibernate.Testing/ConventionFinderTests/AddingTypeTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionFinderTests; [TestFixture] public class AddingTypeTests { - private DefaultConventionFinder finder; + DefaultConventionFinder finder; [SetUp] public void CreateFinder() diff --git a/src/FluentNHibernate.Testing/ConventionFinderTests/FindTests.cs b/src/FluentNHibernate.Testing/ConventionFinderTests/FindTests.cs index 5712be721..247eaca4d 100644 --- a/src/FluentNHibernate.Testing/ConventionFinderTests/FindTests.cs +++ b/src/FluentNHibernate.Testing/ConventionFinderTests/FindTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionFinderTests; [TestFixture] public class FindTests { - private DefaultConventionFinder finder; + DefaultConventionFinder finder; [SetUp] public void CreateConventionFinder() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaAnyTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaAnyTests.cs index 1d6abd0dd..1c9ae87e4 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaAnyTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaAnyTests.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaAnyTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaCollectionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaCollectionTests.cs index 4de3d123f..eb4816fa5 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaCollectionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaCollectionTests.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaCollectionTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualComplexTypeTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualComplexTypeTests.cs index 0da3e158e..b0c7141c0 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualComplexTypeTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualComplexTypeTests.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaEqualComplexTypeTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeEvalTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeEvalTests.cs index d667b527d..1092d0496 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeEvalTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeEvalTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaEqualSimpleTypeEvalTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeTests.cs index 192bffb14..499c568d8 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSimpleTypeTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaEqualSimpleTypeTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSubPropertyTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSubPropertyTests.cs index 845e7b053..423f8e0f1 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSubPropertyTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaEqualSubPropertyTests.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaEqualSubPropertyTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaInheritanceTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaInheritanceTests.cs index 1f8274001..1872ecb4e 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaInheritanceTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaInheritanceTests.cs @@ -11,7 +11,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaInheritanceTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() @@ -65,7 +65,7 @@ public void ShouldUseInheritedOppositeCriteria() .ShouldBeTrue(); } - private class AnotherConvention : IPropertyConvention, IConventionAcceptance + class AnotherConvention : IPropertyConvention, IConventionAcceptance { public void Accept(IAcceptanceCriteria criteria) { diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsAnyTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsAnyTests.cs index c49204bec..b92827cf0 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsAnyTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsAnyTests.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaIsAnyTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsSetTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsSetTests.cs index b0cc9a573..ada2d0959 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsSetTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaIsSetTests.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaIsSetTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaTests.cs index ec9b73b1d..7966e9fca 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AcceptanceCriteria/PropertyAcceptanceCriteriaTests.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.AcceptanceCriteria; [TestFixture] public class PropertyAcceptanceCriteriaTests { - private IAcceptanceCriteria acceptance; + IAcceptanceCriteria acceptance; [SetUp] public void CreateAcceptanceCriteria() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AccessConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AccessConventionTests.cs index bcae39c22..e62e79d09 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AccessConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AccessConventionTests.cs @@ -12,13 +12,13 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class AccessConventionTests { - private string expectedAccess = "backfield"; + string expectedAccess = "backfield"; - private ClassMapping compositeId; - private ClassMapping manyToMany; - private ClassMapping manyToOne; - private ClassMapping oneToOne; - private ClassMapping parent; + ClassMapping compositeId; + ClassMapping manyToMany; + ClassMapping manyToOne; + ClassMapping oneToOne; + ClassMapping parent; [SetUp] @@ -128,7 +128,7 @@ public void AnyIsSet() Assert.That(parent.Anys.First(x => x.Name.Equals("Any")).Access, Is.EqualTo(expectedAccess)); } - private class BackfieldAccessConvention : AccessConvention + class BackfieldAccessConvention : AccessConvention { protected override void Apply(Type owner, string name, FluentNHibernate.Conventions.Instances.IAccessInstance access) { diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ArrayConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ArrayConventionTests.cs index e8dbbcfa1..73035846b 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ArrayConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ArrayConventionTests.cs @@ -13,7 +13,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class ArrayConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -168,13 +168,13 @@ public void ShouldSetWhereProperty() #region Helpers #pragma warning disable 612,618 - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ArrayConventionBuilder().Always(convention)); } #pragma warning restore 612,618 - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ClassConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ClassConventionTests.cs index 05bb3b4e2..3f133f872 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ClassConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ClassConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class ClassConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -134,12 +134,12 @@ public void ShouldSetProxyProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ClassConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -156,6 +156,6 @@ private void VerifyModel(Action modelVerification) #endregion - private class CustomProxy + class CustomProxy { } } diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ComponentConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ComponentConventionTests.cs index de4d16ffd..3c1b50a0b 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ComponentConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ComponentConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class ComponentConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -62,12 +62,12 @@ public void ShouldSetOptimisticLockProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ComponentConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/CompositeIdConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/CompositeIdConventionTests.cs index 990fca7fe..ef41f573e 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/CompositeIdConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/CompositeIdConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class CompositeIdConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -46,12 +46,12 @@ public void ShouldSetMappedValueProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new CompositeIdConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); var map = classMap.CompositeId(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/DynamicComponentConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/DynamicComponentConventionTests.cs index 8f9fd9802..ff7a6704b 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/DynamicComponentConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/DynamicComponentConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class DynamicComponentConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -62,12 +62,12 @@ public void ShouldSetOptimisticLockProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new DynamicComponentConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyCollectionConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyCollectionConventionTests.cs index 8013aa2c0..be32257a0 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyCollectionConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyCollectionConventionTests.cs @@ -13,7 +13,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class HasManyCollectionConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -242,12 +242,12 @@ public void ShouldChangeCollectionTypeToList() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new CollectionConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyConventionTests.cs index a09c0f5a5..f6eb879db 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyConventionTests.cs @@ -13,7 +13,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class HasManyConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -224,12 +224,12 @@ public void ShouldSetInversePropertyToFalseWhenUsingNot() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new OneToManyCollectionConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyCollectionConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyCollectionConventionTests.cs index b40723ca3..e7a0334e8 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyCollectionConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyCollectionConventionTests.cs @@ -13,7 +13,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class HasManyToManyCollectionConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -183,12 +183,12 @@ public void ShouldSetTableNameProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new CollectionConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyConventionTests.cs index 888313fcb..905be74c7 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasManyToManyConventionTests.cs @@ -13,7 +13,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class HasManyToManyConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -230,12 +230,12 @@ public void ShouldSetOrderByProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ManyToManyCollectionConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasOneConventionTests.cs index 7214a0aa5..ea64715f3 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HasOneConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class HasOneConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -86,12 +86,12 @@ public void ShouldSetPropertyRefProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new HasOneConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HibernateMappingConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HibernateMappingConventionTests.cs index b4dc2ce3b..4554999ba 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HibernateMappingConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/HibernateMappingConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class HibernateMappingConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistanceModel() @@ -70,12 +70,12 @@ public void ShouldSetAutoImportProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new HibernateMappingConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/IdConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/IdConventionTests.cs index 83f5a2e4b..34665d662 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/IdConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/IdConventionTests.cs @@ -16,7 +16,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class IdConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -162,12 +162,12 @@ public void ShouldSetTriggerIdentityGenerator() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new IdConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); var map = classMap.Id(x => x.Id); @@ -185,7 +185,7 @@ private void VerifyModel(Action modelVerification) #endregion - private class CustomGenerator : IIdentifierGenerator + class CustomGenerator : IIdentifierGenerator { public object Generate(ISessionImplementor session, object obj) { diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinConventionTests.cs index c55fb06e9..035aa2460 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class JoinConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -70,12 +70,12 @@ public void ShouldSetOptionalProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new JoinConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinedSubclassConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinedSubclassConventionTests.cs index 5806866fd..1ac5c6ffa 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinedSubclassConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/JoinedSubclassConventionTests.cs @@ -13,7 +13,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class JoinedSubclassConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -120,12 +120,12 @@ public void BatchSizeShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new JoinedSubclassConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyManyToOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyManyToOneConventionTests.cs index 1e2ab7ebb..5fb608d02 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyManyToOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyManyToOneConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class KeyManyToOneConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -54,12 +54,12 @@ public void ShouldSetNotFoundValueProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new KeyManyToOneConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); var map = classMap.CompositeId() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyPropertyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyPropertyConventionTests.cs index eb69e37d4..c4a0a4391 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyPropertyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/KeyPropertyConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class KeyPropertyConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -37,12 +37,12 @@ public void ShouldSetLength() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new KeyPropertyConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); var map = classMap.CompositeId() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ManyToOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ManyToOneConventionTests.cs index 909d75efd..ecd98cd15 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ManyToOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/ManyToOneConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class ManyToOneConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -170,12 +170,12 @@ public void ShouldSetOptimisticLockProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ReferenceConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdManyToOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdManyToOneConventionTests.cs index e0a53d5da..36a5b21bd 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdManyToOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdManyToOneConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class NaturalIdManyToOneConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -170,12 +170,12 @@ public void ShouldSetOptimisticLockProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ReferenceConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdPropertyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdPropertyConventionTests.cs index 611f23032..20d508db4 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdPropertyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/NaturalIdPropertyConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class NaturalIdPropertyConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -206,12 +206,12 @@ public void ShouldSetCheckProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new PropertyConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/PropertyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/PropertyConventionTests.cs index 3b60e0dbb..a9b76e11d 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/PropertyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/PropertyConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class PropertyConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -206,12 +206,12 @@ public void ShouldSetCheckProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new PropertyConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/SubclassConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/SubclassConventionTests.cs index 765803615..0251433c7 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/SubclassConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/SubclassConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class SubclassConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -70,12 +70,12 @@ public void ShouldSetSelectBeforeUpdateProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new SubclassConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/VersionConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/VersionConventionTests.cs index 3081fdc70..bbc3968c8 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/VersionConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ApplyingToModel/VersionConventionTests.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.ConventionsTests.ApplyingToModel; [TestFixture] public class VersionConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -142,12 +142,12 @@ public void ShouldSetTypeValueProperty() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new VersionConventionBuilder().Always(convention)); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { var classMap = new ClassMap(); classMap.Id(x => x.Id); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/AutoImportHelperTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/AutoImportHelperTests.cs index 687872ae8..b1d19661a 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/AutoImportHelperTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/AutoImportHelperTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class AutoImportHelperTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -28,7 +28,7 @@ public void ShouldSetDefaultAccessToValue() .AutoImport.ShouldEqual(false); } - private class Target + class Target { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ConventionsCollectionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ConventionsCollectionTests.cs index 9ef64f13a..659fbec4e 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ConventionsCollectionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ConventionsCollectionTests.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class ConventionsCollectionTests { - private ConventionsCollection collection; + ConventionsCollection collection; [SetUp] public void CreateCollection() diff --git a/src/FluentNHibernate.Testing/ConventionsTests/DefaultAccessHelperTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/DefaultAccessHelperTests.cs index 6ff19a16f..8a5f3148f 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/DefaultAccessHelperTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/DefaultAccessHelperTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class DefaultAccessHelperTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -28,7 +28,7 @@ public void ShouldSetDefaultAccessToValue() .DefaultAccess.ShouldEqual("field"); } - private class Target + class Target { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/ConventionsTests/DefaultCascadeHelperTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/DefaultCascadeHelperTests.cs index 7a1364e03..2d987ebc3 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/DefaultCascadeHelperTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/DefaultCascadeHelperTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class DefaultCascadeHelperTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -28,7 +28,7 @@ public void ShouldSetDefaultAccessToValue() .DefaultCascade.ShouldEqual("all"); } - private class Target + class Target { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/ConventionsTests/DefaultLazyHelperTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/DefaultLazyHelperTests.cs index 0860a464d..3888673b9 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/DefaultLazyHelperTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/DefaultLazyHelperTests.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class DefaultLazyHelperTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -40,7 +40,7 @@ public void NeverShouldSetDefaultLazyToFalse() .DefaultLazy.ShouldBeFalse(); } - private class Target + class Target { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ForeignKeyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/ForeignKeyConventionTests.cs index 031d1735a..b40ce4dea 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ForeignKeyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ForeignKeyConventionTests.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class ForeignKeyConventionTests { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -105,7 +105,7 @@ public void ShouldSetForeignKeyOnJoinedSubclasses() .Key.Columns.First().Name.ShouldEqual("ExampleClass!"); } - private class TestForeignKeyConvention : ForeignKeyConvention + class TestForeignKeyConvention : ForeignKeyConvention { protected override string GetKeyName(Member property, Type type) { diff --git a/src/FluentNHibernate.Testing/ConventionsTests/MixedConventionInstanceTester.cs b/src/FluentNHibernate.Testing/ConventionsTests/MixedConventionInstanceTester.cs index 6a93af652..434ed30eb 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/MixedConventionInstanceTester.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/MixedConventionInstanceTester.cs @@ -23,7 +23,7 @@ public void CanApplySameInstanceToMultipleParts() .Element("class/property[@name='LineOne']/column").HasAttribute("name", "prop-col"); } - private class CustomConvention : IIdConvention, IPropertyConvention + class CustomConvention : IIdConvention, IPropertyConvention { public void Apply(IIdentityInstance instance) { diff --git a/src/FluentNHibernate.Testing/ConventionsTests/MultipleHelperConventions.cs b/src/FluentNHibernate.Testing/ConventionsTests/MultipleHelperConventions.cs index 554d25476..f34da4713 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/MultipleHelperConventions.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/MultipleHelperConventions.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class MultipleHelperConventions { - private PersistenceModel model; + PersistenceModel model; [SetUp] public void CreatePersistenceModel() @@ -31,7 +31,7 @@ public void AlwaysShouldSetDefaultLazyToTrue() mapping.DefaultCascade.ShouldEqual("all"); } - private class Target + class Target { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OptionalAcceptTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OptionalAcceptTests.cs index b1f4d3d05..9a1dc4689 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OptionalAcceptTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OptionalAcceptTests.cs @@ -12,8 +12,8 @@ namespace FluentNHibernate.Testing.ConventionsTests; [TestFixture] public class OptionalAcceptTests { - private DefaultConventionFinder conventions; - private ConventionVisitor visitor; + DefaultConventionFinder conventions; + ConventionVisitor visitor; [SetUp] public void CreateVisitor() @@ -58,7 +58,7 @@ public void ShouldApplyConventionWithNoAccept() mapping.IsSpecified("TableName").ShouldBeTrue(); } - private class ConventionWithFailingAccept : IClassConvention, IConventionAcceptance + class ConventionWithFailingAccept : IClassConvention, IConventionAcceptance { public void Accept(IAcceptanceCriteria criteria) { @@ -71,7 +71,7 @@ public void Apply(IClassInstance instance) } } - private class ConventionWithSuccessfulAccept : IClassConvention, IConventionAcceptance + class ConventionWithSuccessfulAccept : IClassConvention, IConventionAcceptance { public void Accept(IAcceptanceCriteria criteria) { @@ -84,7 +84,7 @@ public void Apply(IClassInstance instance) } } - private class ConventionWithNoAccept : IClassConvention + class ConventionWithNoAccept : IClassConvention { public void Apply(IClassInstance instance) { diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ArrayConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ArrayConventionTests.cs index 641befa05..f1b414055 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ArrayConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ArrayConventionTests.cs @@ -13,9 +13,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class ArrayConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -196,13 +196,13 @@ public void WhereShouldntBeOverwritten() #region Helpers #pragma warning disable 612,618 - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ArrayConventionBuilder().Always(convention)); } #pragma warning restore 612,618 - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -215,7 +215,7 @@ private void Mapping(Action> mappingDefinition) mappingType = typeof(ExampleParentClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ClassConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ClassConventionTests.cs index 451987b82..ff8d0602c 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ClassConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ClassConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class ClassConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -152,17 +152,17 @@ public void ShouldSetProxyProperty() VerifyModel(x => x.Proxy.ShouldEqual("type")); } - private class CustomProxy + class CustomProxy {} #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ClassConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -173,7 +173,7 @@ private void Mapping(Action> mappingDefinition) mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ComponentConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ComponentConventionTests.cs index 68af0c473..e4247c317 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ComponentConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ComponentConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class ComponentConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -74,12 +74,12 @@ public void OptimisticLockShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ComponentConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -91,7 +91,7 @@ private void Mapping(Action> mappingDefinition) mappingType = typeof(PropertyTarget); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/CompositeIdConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/CompositeIdConventionTests.cs index 145021394..2a884305a 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/CompositeIdConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/CompositeIdConventionTests.cs @@ -13,9 +13,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class CompositeIdConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -55,12 +55,12 @@ public void MappedValueShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new CompositeIdConventionBuilder().Always(convention)); } - private void Mapping(Expression> property, Action> mappingDefinition) + void Mapping(Expression> property, Action> mappingDefinition) { var classMap = new ClassMap(); var map = classMap.CompositeId(property); @@ -71,7 +71,7 @@ private void Mapping(Expression> property, Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/DynamicComponentConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/DynamicComponentConventionTests.cs index 872791eaa..c50a4714f 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/DynamicComponentConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/DynamicComponentConventionTests.cs @@ -13,9 +13,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class DynamicComponentConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -75,12 +75,12 @@ public void OptimisticLockShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new DynamicComponentConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -97,7 +97,7 @@ private void Mapping(Action> mappingDefinition mappingType = typeof(PropertyTarget); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyCollectionConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyCollectionConventionTests.cs index 800427eb7..c59e05ed2 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyCollectionConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyCollectionConventionTests.cs @@ -15,9 +15,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class HasManyCollectionConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -247,12 +247,12 @@ public void TableNameShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new CollectionConventionBuilder().Always(convention)); } - private void Mapping(Expression>> property, Action> mappingDefinition) + void Mapping(Expression>> property, Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -264,7 +264,7 @@ private void Mapping(Expression modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyConventionTests.cs index 587b652ee..e1539c867 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyConventionTests.cs @@ -15,9 +15,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class HasManyConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -257,12 +257,12 @@ public void NotFoundShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new OneToManyCollectionConventionBuilder().Always(convention)); } - private void Mapping(Expression>> property, Action> mappingDefinition) + void Mapping(Expression>> property, Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -274,7 +274,7 @@ private void Mapping(Expression modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyCollectionConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyCollectionConventionTests.cs index 56f45cbb8..675617c13 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyCollectionConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyCollectionConventionTests.cs @@ -15,9 +15,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class HasManyToManyCollectionConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -227,12 +227,12 @@ public void TableNameShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new CollectionConventionBuilder().Always(convention)); } - private void Mapping(Expression>> property, Action> mappingDefinition) + void Mapping(Expression>> property, Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -244,7 +244,7 @@ private void Mapping(Expression modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyConventionTests.cs index 3fa77e58e..42a1c3bd9 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasManyToManyConventionTests.cs @@ -15,9 +15,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class HasManyToManyConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -267,12 +267,12 @@ public void ChildForeignKeyConstraintNameShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ManyToManyCollectionConventionBuilder().Always(convention)); } - private void Mapping(Expression>> property, Action> mappingDefinition) + void Mapping(Expression>> property, Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -284,7 +284,7 @@ private void Mapping(Expression modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasOneConventionTests.cs index e66c2489a..644809944 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HasOneConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class HasOneConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -104,12 +104,12 @@ public void PropertyRefShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new HasOneConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -121,7 +121,7 @@ private void Mapping(Action> mappingDefinition) mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HibernateMappingConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HibernateMappingConventionTests.cs index ebb15bbea..d5f9ab3b9 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HibernateMappingConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/HibernateMappingConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class HibernateMappingConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistanceModel() @@ -84,12 +84,12 @@ public void AutoImportShouldntBeOverridden() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new HibernateMappingConventionBuilder().Always(convention)); } - private void Mapping(Action mappingDefinition) + void Mapping(Action mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -100,7 +100,7 @@ private void Mapping(Action mappingDefinition) mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/IdConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/IdConventionTests.cs index cd44db961..e6e82edba 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/IdConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/IdConventionTests.cs @@ -13,9 +13,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class IdConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -175,12 +175,12 @@ public void TypeValueShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new IdConventionBuilder().Always(convention)); } - private void Mapping(Expression> property, Action mappingDefinition) + void Mapping(Expression> property, Action mappingDefinition) { var classMap = new ClassMap(); var map = classMap.Id(property); @@ -191,7 +191,7 @@ private void Mapping(Expression> property, Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinConventionTests.cs index ed1bf88e1..0f2236bcd 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class JoinConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -84,12 +84,12 @@ public void OptionalShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new JoinConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -100,7 +100,7 @@ private void Mapping(Action> mappingDefinition) mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinedSubclassConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinedSubclassConventionTests.cs index 6f9eff37f..04aa40b55 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinedSubclassConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/JoinedSubclassConventionTests.cs @@ -13,9 +13,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class JoinedSubclassConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -145,12 +145,12 @@ public void BatchSizeShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new JoinedSubclassConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -164,7 +164,7 @@ private void Mapping(Action> mappingDefinitio mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyManyToOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyManyToOneConventionTests.cs index faedcd3a6..54b40a83d 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyManyToOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyManyToOneConventionTests.cs @@ -12,8 +12,8 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class KeyManyToOneConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; + PersistenceModel model; + IMappingProvider mapping; [SetUp] public void CreatePersistenceModel() @@ -63,12 +63,12 @@ public void NotFoundShouldntBeOveridden() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new KeyManyToOneConventionBuilder().Always(convention)); } - private void Mapping(Action mappingDefinition) + void Mapping(Action mappingDefinition) { var classMap = new ClassMap(); var map = classMap.CompositeId() @@ -78,7 +78,7 @@ private void Mapping(Action mappingDefinition) mapping = classMap; } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyPropertyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyPropertyConventionTests.cs index 8cb0562af..d326e6bc1 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyPropertyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/KeyPropertyConventionTests.cs @@ -12,8 +12,8 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class KeyPropertyConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; + PersistenceModel model; + IMappingProvider mapping; [SetUp] public void CreatePersistenceModel() @@ -33,12 +33,12 @@ public void AccessShouldntBeOveridden() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new KeyPropertyConventionBuilder().Always(convention)); } - private void Mapping(Action mappingDefinition) + void Mapping(Action mappingDefinition) { var classMap = new ClassMap(); var map = classMap.CompositeId() @@ -48,7 +48,7 @@ private void Mapping(Action mappingDefinition) mapping = classMap; } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ManyToOneConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ManyToOneConventionTests.cs index dda9cb2fb..07106bd2b 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ManyToOneConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/ManyToOneConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class ManyToOneConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -198,12 +198,12 @@ public void FormulaShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new ReferenceConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -215,7 +215,7 @@ private void Mapping(Action> mappingDefinition mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/PropertyConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/PropertyConventionTests.cs index 565c7e827..3a1ce8a36 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/PropertyConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/PropertyConventionTests.cs @@ -14,9 +14,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class PropertyConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -254,12 +254,12 @@ public void CheckShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new PropertyConventionBuilder().Always(convention)); } - private void Mapping(Expression> property, Action mappingDefinition) + void Mapping(Expression> property, Action mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -271,7 +271,7 @@ private void Mapping(Expression> property, Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/SubclassConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/SubclassConventionTests.cs index 38f014804..fca009e35 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/SubclassConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/SubclassConventionTests.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class SubclassConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -94,12 +94,12 @@ public void ExtendsShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new SubclassConventionBuilder().Always(convention)); } - private void Mapping(Action> mappingDefinition) + void Mapping(Action> mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -115,7 +115,7 @@ private void Mapping(Action> mappingDefinitio mappingType = typeof(ExampleClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/VersionConventionTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/VersionConventionTests.cs index 618efe904..422e7b7fc 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/VersionConventionTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/OverridingFluentInterface/VersionConventionTests.cs @@ -13,9 +13,9 @@ namespace FluentNHibernate.Testing.ConventionsTests.OverridingFluentInterface; [TestFixture] public class VersionConventionTests { - private PersistenceModel model; - private IMappingProvider mapping; - private Type mappingType; + PersistenceModel model; + IMappingProvider mapping; + Type mappingType; [SetUp] public void CreatePersistenceModel() @@ -176,12 +176,12 @@ public void TypeValueShouldntBeOverwritten() #region Helpers - private void Convention(Action convention) + void Convention(Action convention) { model.Conventions.Add(new VersionConventionBuilder().Always(convention)); } - private void Mapping(Expression> property, Action mappingDefinition) + void Mapping(Expression> property, Action mappingDefinition) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -193,7 +193,7 @@ private void Mapping(Expression> property, Actio mappingType = typeof(ValidVersionClass); } - private void VerifyModel(Action modelVerification) + void VerifyModel(Action modelVerification) { model.Add(mapping); diff --git a/src/FluentNHibernate.Testing/ConventionsTests/ProxyConventionTester.cs b/src/FluentNHibernate.Testing/ConventionsTests/ProxyConventionTester.cs index 2ae22b915..a998e1f4b 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/ProxyConventionTester.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/ProxyConventionTester.cs @@ -157,20 +157,20 @@ public void ConventionDoesNotSetOneToOneTypeIfUnrecognised() .MustNotHaveHappened(); } - private static ProxyConvention GetConvention() + static ProxyConvention GetConvention() { return new ProxyConvention(PersistentTypeToProxy, ProxyToPersistentType); } - private static Type PersistentTypeToProxy(Type type) + static Type PersistentTypeToProxy(Type type) { return type == typeof(ProxiedObject) ? typeof(IProxiedObject) : null; } - private static Type ProxyToPersistentType(Type type) + static Type ProxyToPersistentType(Type type) { return type == typeof(IProxiedObject) ? typeof(ProxiedObject) diff --git a/src/FluentNHibernate.Testing/ConventionsTests/RunnableConventionsTests.cs b/src/FluentNHibernate.Testing/ConventionsTests/RunnableConventionsTests.cs index 1119adc9f..778449d44 100644 --- a/src/FluentNHibernate.Testing/ConventionsTests/RunnableConventionsTests.cs +++ b/src/FluentNHibernate.Testing/ConventionsTests/RunnableConventionsTests.cs @@ -447,7 +447,7 @@ public void ShouldApplyIHibernateMappingConvention() #region conventions #pragma warning disable 612,618 - private class ArrayConvention : IArrayConvention + class ArrayConvention : IArrayConvention { public void Apply(IArrayInstance instance) { @@ -455,7 +455,7 @@ public void Apply(IArrayInstance instance) } } - private class BagConvention : IBagConvention + class BagConvention : IBagConvention { public void Apply(IBagInstance instance) { @@ -463,7 +463,7 @@ public void Apply(IBagInstance instance) } } - private class ClassConvention : IClassConvention + class ClassConvention : IClassConvention { public void Apply(IClassInstance instance) { @@ -471,7 +471,7 @@ public void Apply(IClassInstance instance) } } - private class CollectionConvention : ICollectionConvention + class CollectionConvention : ICollectionConvention { public void Apply(ICollectionInstance instance) { @@ -479,7 +479,7 @@ public void Apply(ICollectionInstance instance) } } - private class ColumnConvention : IColumnConvention + class ColumnConvention : IColumnConvention { public void Apply(IColumnInstance instance) { @@ -487,7 +487,7 @@ public void Apply(IColumnInstance instance) } } - private class ComponentConvention : IComponentConvention + class ComponentConvention : IComponentConvention { public void Apply(IComponentInstance instance) { @@ -495,7 +495,7 @@ public void Apply(IComponentInstance instance) } } - private class DynamicComponentConvention : IDynamicComponentConvention + class DynamicComponentConvention : IDynamicComponentConvention { public void Apply(IDynamicComponentInstance instance) { @@ -503,7 +503,7 @@ public void Apply(IDynamicComponentInstance instance) } } - private class HasManyConvention : IHasManyConvention + class HasManyConvention : IHasManyConvention { public void Apply(IOneToManyCollectionInstance instance) { @@ -511,7 +511,7 @@ public void Apply(IOneToManyCollectionInstance instance) } } - private class HasManyToManyConvention : IHasManyToManyConvention + class HasManyToManyConvention : IHasManyToManyConvention { public void Apply(IManyToManyCollectionInstance instance) { @@ -638,7 +638,7 @@ public void Apply(IHibernateMappingInstance instance) #pragma warning restore 612,618 - private class OtherObjectUserType : IUserType + class OtherObjectUserType : IUserType { public OtherObjectUserType() { @@ -701,7 +701,7 @@ public void NullSafeSet(DbCommand cmd, object value, int index, ISessionImplemen #endregion - private ClassMapping TestConvention(T convention, Func getMapping) where T : IConvention + ClassMapping TestConvention(T convention, Func getMapping) where T : IConvention { var model = new PersistenceModel(); @@ -713,7 +713,7 @@ private ClassMapping TestConvention(T convention, Func getM .Classes.First(); } - private HibernateMapping TestConvention(HibernateMappingConvention convention, Func getMapping) + HibernateMapping TestConvention(HibernateMappingConvention convention, Func getMapping) { var model = new PersistenceModel(); @@ -724,7 +724,7 @@ private HibernateMapping TestConvention(HibernateMappingConvention convention, F .First(); } - private class Target + class Target { public OtherObject[] Array { get; set; } public IList Bag { get; set; } @@ -736,10 +736,10 @@ private class Target public IDictionary DictionaryBag { get; set; } } - private class TargetSubclass : Target + class TargetSubclass : Target {} - private class OtherObject + class OtherObject { public int Id { get; set; } } diff --git a/src/FluentNHibernate.Testing/DomainModel/ConnectedTester.cs b/src/FluentNHibernate.Testing/DomainModel/ConnectedTester.cs index c32e63c51..65f003693 100644 --- a/src/FluentNHibernate.Testing/DomainModel/ConnectedTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/ConnectedTester.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.DomainModel; [TestFixture] public class ConnectedTester { - private ISessionSource source; + ISessionSource source; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/DomainModel/Employees.cs b/src/FluentNHibernate.Testing/DomainModel/Employees.cs index c0982ecbf..0b7b9547f 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Employees.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Employees.cs @@ -18,7 +18,7 @@ public class CasualEmployee : Employee public class Money { - private Money() + Money() { } public Money(decimal amount, string currency) diff --git a/src/FluentNHibernate.Testing/DomainModel/InverseOneToManyTester.cs b/src/FluentNHibernate.Testing/DomainModel/InverseOneToManyTester.cs index 73eac687e..c7af29c9c 100644 --- a/src/FluentNHibernate.Testing/DomainModel/InverseOneToManyTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/InverseOneToManyTester.cs @@ -21,7 +21,7 @@ public void SetUp() _source.BuildSchema(); } - private ISessionSource _source; + ISessionSource _source; [Test] public void Should_handle_inverse_collections() diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/CascadeExpressionTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/CascadeExpressionTester.cs index bc7c10dd4..59d4dc901 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/CascadeExpressionTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/CascadeExpressionTester.cs @@ -11,7 +11,7 @@ public class CascadeExpressionTester protected CascadeExpression _cascade; protected string cascadeValue; - private Func _currentCascadeAction; + Func _currentCascadeAction; [SetUp] public virtual void SetUp() diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/ClassCacheTests.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/ClassCacheTests.cs index 72909267c..0b9660b8c 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/ClassCacheTests.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/ClassCacheTests.cs @@ -66,7 +66,7 @@ public void ShouldWriteRegionWhenAssigned() .Element("class/cache").HasAttribute("region", "MyRegion"); } - private class CacheTarget + class CacheTarget { public virtual int Id { get; set; } public virtual string Name { get; set; } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/CollectionCascadeExpressionTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/CollectionCascadeExpressionTester.cs index 4a218fe72..895b96bd5 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/CollectionCascadeExpressionTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/CollectionCascadeExpressionTester.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Testing.DomainModel.Mapping; [TestFixture] public class CollectionCascadeExpressionTester : CascadeExpressionTester { - private CollectionCascadeExpression _collectionCascade; + CollectionCascadeExpression _collectionCascade; [SetUp] public override void SetUp() diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentElementPartTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentElementPartTester.cs index 85bbbcd8f..ce7cd55dd 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentElementPartTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentElementPartTester.cs @@ -71,12 +71,12 @@ public void CanCreateNestedCompositeElement() .HasAttribute("name", "Target"); } - private class TopLevel + class TopLevel { public IList Items { get; set; } } - private class Item + class Item { public PropertyTarget Target { get; set; } public string SomeString { get; set; } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentPropertyMapTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentPropertyMapTester.cs index 6311b6ead..bef64a618 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentPropertyMapTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/ComponentPropertyMapTester.cs @@ -55,7 +55,7 @@ public void Map_WithFluentColumnName_UsesColumnNameFor_ColumnNameAttribute() .Element("//property/column").HasAttribute("name", "column_name"); } - private MappingTester Model(Action> mapping) + MappingTester Model(Action> mapping) { return new MappingTester() .ForMapping(mapping); diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/FetchTypeExpressionTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/FetchTypeExpressionTester.cs index 57800b7aa..077ce60f0 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/FetchTypeExpressionTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/FetchTypeExpressionTester.cs @@ -9,7 +9,7 @@ public class FetchTypeExpressionTester { #region Test Setup public FetchTypeExpression _fetchType; - private string fetchValue; + string fetchValue; [SetUp] public virtual void SetUp() @@ -24,7 +24,7 @@ protected FetchTypeExpressionTester A_call_to(Func fetchAction) return this; } - private void should_set_the_fetch_value_to(string expected) + void should_set_the_fetch_value_to(string expected) { fetchValue.ShouldEqual(expected); } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/FilterTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/FilterTester.cs index bf6eb4000..ab8b999da 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/FilterTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/FilterTester.cs @@ -183,7 +183,7 @@ public void Applying_a_named_child_filter_to_a_many_to_many_with_no_condition() } } -internal class TestFilter : FilterDefinition +class TestFilter : FilterDefinition { public TestFilter() { diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/IdentityPartTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/IdentityPartTester.cs index bc7342e03..d39b2b6ab 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/IdentityPartTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/IdentityPartTester.cs @@ -515,7 +515,7 @@ public void CanCreateIdWithoutPropertyOrColumns() .DoesntExist(); } - private class TestIdConvention : IIdConvention + class TestIdConvention : IIdConvention { public void Apply(IIdentityInstance instance) { diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinPartTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinPartTester.cs index 6ae57479a..c6b061607 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinPartTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinPartTester.cs @@ -78,7 +78,7 @@ public void CanOverrideKeyInConvention() .Element("class/join/key/column").HasAttribute("name", "JoinTargetID"); } - private class JoinConvention : IJoinConvention + class JoinConvention : IJoinConvention { public void Apply(IJoinInstance instance) { @@ -124,7 +124,7 @@ public void JoinContainsAnSqlDeleteElement() .Element("class/join/sql-delete").Exists(); } - private class JoinTarget + class JoinTarget { public string Name { get; set; } public string CustomerName { get; set; } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinedSubClassTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinedSubClassTester.cs index ce55f6e0c..2db0fbd15 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinedSubClassTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/JoinedSubClassTester.cs @@ -221,19 +221,19 @@ public void MapsReferencesAny() .Element("//joined-subclass/any").Exists(); } - private class SuperClass + class SuperClass { public int Id { get; set; } public string Type { get; set; } public SuperClass Parent { get; set; } } - private class SubClass : SuperClass + class SubClass : SuperClass { public string Name { get; set; } } - private class ProxyClass + class ProxyClass {} } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyIntegrationTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyIntegrationTester.cs index 881c34332..9a0bd7c1a 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyIntegrationTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyIntegrationTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.DomainModel.Mapping; [TestFixture] public class ManyToManyIntegrationTester { - private class ManyToManyPersistenceModel : PersistenceModel + class ManyToManyPersistenceModel : PersistenceModel { public override void Configure(Configuration configuration) { @@ -17,7 +17,7 @@ public override void Configure(Configuration configuration) base.Configure(configuration); } - private class ChildObjectMap : ClassMap + class ChildObjectMap : ClassMap { public ChildObjectMap() { @@ -25,7 +25,7 @@ public ChildObjectMap() } } - private class ManyToManyTargetMap : ClassMap + class ManyToManyTargetMap : ClassMap { public ManyToManyTargetMap() { diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManySelfReferencedInverseIntegrationTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManySelfReferencedInverseIntegrationTester.cs index c35a4e22b..a1f74e57f 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManySelfReferencedInverseIntegrationTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManySelfReferencedInverseIntegrationTester.cs @@ -39,7 +39,7 @@ public TreeNodeMap() } } - private class ManyToManyPersistenceModel : PersistenceModel + class ManyToManyPersistenceModel : PersistenceModel { public override void Configure(Configuration configuration) { diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyTester.cs index bb9e4e29b..9c3711f28 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/ManyToManyTester.cs @@ -25,7 +25,7 @@ public class ManyToManyTarget public virtual IDictionary MapOfChildrenToBools{ get; set; } public virtual IDictionary NonGenericTernaryMapOfChildren { get; set; } - private IList otherChildren = new List(); + IList otherChildren = new List(); public virtual IList GetOtherChildren() { return otherChildren; } } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/MappingTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/MappingTester.cs index 71a92e939..7c2878f50 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/MappingTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/MappingTester.cs @@ -12,8 +12,8 @@ public class MappingTester { protected XmlElement currentElement; protected XmlDocument document; - private readonly PersistenceModel model; - private string currentPath; + readonly PersistenceModel model; + string currentPath; public MappingTester(): this(new PersistenceModel()) {} diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyIntegrationTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyIntegrationTester.cs index 123050554..cc25a94ae 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyIntegrationTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyIntegrationTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.DomainModel.Mapping; [TestFixture] public class OneToManyIntegrationTester { - private class OneToManyPersistenceModel : PersistenceModel + class OneToManyPersistenceModel : PersistenceModel { public override void Configure(NHibernate.Cfg.Configuration configuration) { @@ -17,7 +17,7 @@ public override void Configure(NHibernate.Cfg.Configuration configuration) base.Configure(configuration); } - private class ChildObjectMap : ClassMap + class ChildObjectMap : ClassMap { public ChildObjectMap() { @@ -25,7 +25,7 @@ public ChildObjectMap() } } - private class OneToManyTargetMap : ClassMap + class OneToManyTargetMap : ClassMap { public OneToManyTargetMap() { diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyTester.cs index 3b8fc7a15..175ca3e2d 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToManyTester.cs @@ -39,10 +39,10 @@ public class OneToManyTarget public virtual IDictionary EntityMapOfComplexValues { get; set; } public virtual IDictionary EntityMapOfValues { get; set; } - private IList otherChildren = new List(); + IList otherChildren = new List(); public virtual IList GetOtherChildren() { return otherChildren; } - private IList listToArrayChild = new List(); + IList listToArrayChild = new List(); public virtual ChildObject[] ListToArrayChild => listToArrayChild.ToArray(); } @@ -453,7 +453,7 @@ public void OneToManyMapping_with_private_backing_field() .HasAttribute("access", "field.camelcase"); } - private class StaticExample + class StaticExample { public static string SomeValue = "SomeValue"; } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToOneTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToOneTester.cs index 1ee123ea4..f4bea299c 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToOneTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/OneToOneTester.cs @@ -84,10 +84,12 @@ public void The_class_is_determined_by_the_return_value_of_the_HasOne_expression .HasAttribute("class", typeof (UserLoginInfo).AssemblyQualifiedName); } - - private interface IUserLoginInfo {} - private class UserLoginInfo : IUserLoginInfo { } - private class User + + interface IUserLoginInfo {} + + class UserLoginInfo : IUserLoginInfo { } + + class User { public int Id { get; set; } public IUserLoginInfo LoginInfo => null; diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/PropertyPartTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/PropertyPartTester.cs index f3aff732d..8ec0384a1 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/PropertyPartTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/PropertyPartTester.cs @@ -603,7 +603,7 @@ public class FieldTarget public class PrivatePropertyTarget { public int Id { get; set; } - private string Name { get; set; } + string Name { get; set; } public PropertyReferenceTarget Reference { get; set; } public IList References { get; set; } public ComponentTarget Component { get; set; } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/SubClassTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/SubClassTester.cs index e9c92fed0..d378d2287 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/SubClassTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/SubClassTester.cs @@ -616,7 +616,7 @@ public void Apply(IOneToManyCollectionInstance instance) } } - private class ProxyClass + class ProxyClass {} } diff --git a/src/FluentNHibernate.Testing/DomainModel/Mapping/VersionTester.cs b/src/FluentNHibernate.Testing/DomainModel/Mapping/VersionTester.cs index 048a8e670..9dffb4ce5 100644 --- a/src/FluentNHibernate.Testing/DomainModel/Mapping/VersionTester.cs +++ b/src/FluentNHibernate.Testing/DomainModel/Mapping/VersionTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.DomainModel.Mapping; [TestFixture] public class VersionTester { - private ClassMap _classMap; + ClassMap _classMap; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/DomainModel/RevealTests.cs b/src/FluentNHibernate.Testing/DomainModel/RevealTests.cs index d6c4918f6..9276a6b09 100644 --- a/src/FluentNHibernate.Testing/DomainModel/RevealTests.cs +++ b/src/FluentNHibernate.Testing/DomainModel/RevealTests.cs @@ -50,12 +50,12 @@ public void Can_use_references_using_string_name_on_private_property() public class StringTarget { public int Id { get; set; } - private Double DoubleProperty { get; set; } - private int IntProperty { get; set; } - private string PrivateProperty { get; set; } + Double DoubleProperty { get; set; } + int IntProperty { get; set; } + string PrivateProperty { get; set; } protected string ProtectedProperty { get; set; } protected string PublicProperty { get; set; } - private IList PrivateCollection { get; set; } - private IDictionary PrivateDictionary { get; set; } - private ExampleClass PrivateObject { get; set; } + IList PrivateCollection { get; set; } + IDictionary PrivateDictionary { get; set; } + ExampleClass PrivateObject { get; set; } } diff --git a/src/FluentNHibernate.Testing/EmptySource.cs b/src/FluentNHibernate.Testing/EmptySource.cs index bebcd09b8..4b2b305ce 100644 --- a/src/FluentNHibernate.Testing/EmptySource.cs +++ b/src/FluentNHibernate.Testing/EmptySource.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.Testing; -internal class EmptySource : ITypeSource +class EmptySource : ITypeSource { public IEnumerable GetTypes() { diff --git a/src/FluentNHibernate.Testing/ExpressionToSqlTests.cs b/src/FluentNHibernate.Testing/ExpressionToSqlTests.cs index 1fb17dca0..c4e2bd1a2 100644 --- a/src/FluentNHibernate.Testing/ExpressionToSqlTests.cs +++ b/src/FluentNHibernate.Testing/ExpressionToSqlTests.cs @@ -136,7 +136,7 @@ public void ConvertLocalVariable() sql.ShouldEqual("'someValue'"); } - private const string someValue = "someValue"; + const string someValue = "someValue"; [Test] public void ConvertConst() @@ -146,7 +146,7 @@ public void ConvertConst() sql.ShouldEqual("'someValue'"); } - private class StaticExample + class StaticExample { public static string Value = "someValue"; public static string Method() @@ -171,7 +171,7 @@ public void ConvertStaticMethodCall() sql.ShouldEqual("'someValue'"); } - private enum Something + enum Something { Else = 10 } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/ClassMapFilterPartModelGenerationTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/ClassMapFilterPartModelGenerationTests.cs index 86de2d64a..2142886e7 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/ClassMapFilterPartModelGenerationTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/ClassMapFilterPartModelGenerationTests.cs @@ -16,13 +16,13 @@ public void MapShouldAddFilterMappingToClassMapping() .ModelShouldMatch(CheckFirstFilterWithCondition); } - private void CheckFirstFilterWithoutCondition(ClassMapping mapping) + void CheckFirstFilterWithoutCondition(ClassMapping mapping) { if (!mapping.Filters.Any()) Assert.Fail("No filter added"); if (mapping.Filters.First().Name != "test") Assert.Fail("Wrong filter name added"); } - private void CheckFirstFilterWithCondition(ClassMapping mapping) + void CheckFirstFilterWithCondition(ClassMapping mapping) { CheckFirstFilterWithoutCondition(mapping); if (mapping.Filters.First().Condition != "Name = :name") Assert.Fail("Wrong filter condition added"); diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/ColumnPartTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/ColumnPartTests.cs index b5ab7776e..484df7fc9 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/ColumnPartTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/ColumnPartTests.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; [TestFixture] public class ColumnPartTests { - private ColumnMapping mapping; - private ColumnPart columnPart; + ColumnMapping mapping; + ColumnPart columnPart; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomPersister.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomPersister.cs index 9553a8d88..d5645a2fc 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomPersister.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomPersister.cs @@ -14,10 +14,10 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; -internal class SecondCustomPersister : CustomPersister +class SecondCustomPersister : CustomPersister {} -internal class CustomPersister : IEntityPersister +class CustomPersister : IEntityPersister { public void PostInstantiate() {} diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomProxy.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomProxy.cs index 309d5f46d..e59c35c84 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomProxy.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/CustomProxy.cs @@ -1,7 +1,7 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; -internal class CustomProxy +class CustomProxy {} -internal class SecondCustomProxy : CustomProxy +class SecondCustomProxy : CustomProxy {} diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/IdGeneratorTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/IdGeneratorTests.cs index 22e41f766..5242eed44 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/IdGeneratorTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/IdGeneratorTests.cs @@ -81,14 +81,14 @@ public void ShouldAllowCustomGenerators() .ModelShouldMatch(x => ((IdMapping)x.Id).Generator.Class.ShouldEqual(typeof(CustomGenerator).AssemblyQualifiedName)); } - private class IdentityExamples + class IdentityExamples { public string String { get; set; } public int Int { get; set; } public Guid Guid { get; set; } } - private class IdConvention : IIdConvention + class IdConvention : IIdConvention { public void Apply(IIdentityInstance instance) { @@ -96,7 +96,7 @@ public void Apply(IIdentityInstance instance) } } - private class CustomGenerator : IIdentifierGenerator + class CustomGenerator : IIdentifierGenerator { public object Generate(ISessionImplementor session, object obj) { diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/JoinedSubclassMutablePropertyModelGenerationTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/JoinedSubclassMutablePropertyModelGenerationTests.cs index 12c202821..a984403da 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/JoinedSubclassMutablePropertyModelGenerationTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/JoinedSubclassMutablePropertyModelGenerationTests.cs @@ -135,6 +135,6 @@ public void EntityNameShouldSetModelEntityNamePropertyToFalse() .ModelShouldMatch(x => x.EntityName.ShouldEqual("entity1")); } - private class FakeProxyType + class FakeProxyType {} } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyManyToOnePartTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyManyToOnePartTests.cs index 63000f4b9..66de7b8f6 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyManyToOnePartTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyManyToOnePartTests.cs @@ -6,9 +6,8 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; [TestFixture] public class KeyManyToOnePartTests { - - private KeyManyToOneMapping mapping; - private KeyManyToOnePart keyPart; + KeyManyToOneMapping mapping; + KeyManyToOnePart keyPart; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyPropertyPartTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyPropertyPartTests.cs index 0c15dafbf..ec3d84577 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyPropertyPartTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/KeyPropertyPartTests.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; [TestFixture] public class KeyPropertyPartTests { - private KeyPropertyMapping mapping; - private KeyPropertyPart part; + KeyPropertyMapping mapping; + KeyPropertyPart part; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/ManyToManyTableNameTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/ManyToManyTableNameTests.cs index 951300d3c..0686b95f8 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/ManyToManyTableNameTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/ManyToManyTableNameTests.cs @@ -195,7 +195,7 @@ public void ShouldAllowConventionsToAlterUniDirectionalTableNames() leftMapping.Collections.First().TableName.ShouldEqual("RightUni"); } - private class TestTableNameConvention : ManyToManyTableNameConvention + class TestTableNameConvention : ManyToManyTableNameConvention { protected override string GetBiDirectionalTableName(IManyToManyCollectionInspector collection, IManyToManyCollectionInspector otherSide) { diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/ModelTester.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/ModelTester.cs index 3090d7dc2..b3fc8b586 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/ModelTester.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/ModelTester.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; public class ModelTester(Func instantiatePart, Func getModel) { - private TFluentClass fluentClass; + TFluentClass fluentClass; public ModelTester Mapping(Action action) { diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/PropertyEnumerablesTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/PropertyEnumerablesTests.cs index e10b20cee..638cd9feb 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/PropertyEnumerablesTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/PropertyEnumerablesTests.cs @@ -34,13 +34,13 @@ public void ShouldSetEnumsToUseEnumStringType() .ModelShouldMatch(x => x.Type.GetUnderlyingSystemType().ShouldEqual(typeof(EnumStringType))); } - private class Target + class Target { public Enum? NullableEnum { get; set; } public Enum Enum { get; set; } } - private enum Enum + enum Enum { } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassConventionTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassConventionTests.cs index f30ca950f..60276b755 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassConventionTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassConventionTests.cs @@ -31,7 +31,7 @@ public void ShouldAllowSettingOfKeyInConvention() subclass.Key.Columns.Count().ShouldEqual(1); } - private class SCKeyConvention : IJoinedSubclassConvention + class SCKeyConvention : IJoinedSubclassConvention { public void Apply(IJoinedSubclassInstance instance) { @@ -39,11 +39,11 @@ public void Apply(IJoinedSubclassInstance instance) } } - private class Parent + class Parent { public int Id { get; set; } } - private class Child : Parent + class Child : Parent {} } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassMutablePropertyModelGenerationTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassMutablePropertyModelGenerationTests.cs index 8b66351ea..e50214865 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassMutablePropertyModelGenerationTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForJoinedSubclassMutablePropertyModelGenerationTests.cs @@ -167,6 +167,6 @@ public void EntityNameShouldSetModelEntityName() .ModelShouldMatch(x => x.EntityName.ShouldEqual("name1")); } - private class FakeProxyType + class FakeProxyType {} } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassMutablePropertyModelGenerationTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassMutablePropertyModelGenerationTests.cs index c047055e6..08da710c1 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassMutablePropertyModelGenerationTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassMutablePropertyModelGenerationTests.cs @@ -150,6 +150,6 @@ public void EntityNameShouldSetModelEntityName() .ModelShouldMatch(x => x.EntityName.ShouldEqual("name1")); } - private class FakeProxyType + class FakeProxyType {} } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassSubPartModelGenerationTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassSubPartModelGenerationTests.cs index 8e4aeb67a..e65c866ff 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassSubPartModelGenerationTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapForSubclassSubPartModelGenerationTests.cs @@ -40,17 +40,17 @@ public void ComponentWithPropertiesShouldAddToModelComponentsCollection() .Components.Count().ShouldEqual(1); } - private class Parent + class Parent { public int Id { get; set; } } - private class Child : Parent + class Child : Parent { public Component Component { get; set; } } - private class Component + class Component { public string Name { get; set; } } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapWithUserTypeTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapWithUserTypeTests.cs index c1eb74fe7..d5c6b77ce 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapWithUserTypeTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMapWithUserTypeTests.cs @@ -57,7 +57,7 @@ public MediaMap() public class Image : Media { - private IList contexts = new List(); + IList contexts = new List(); public virtual string Title { get; set; } public virtual string Description { get; set; } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMutablePropertyModelGenerationTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMutablePropertyModelGenerationTests.cs index 237ed2902..00a3d26ae 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMutablePropertyModelGenerationTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/SubclassMutablePropertyModelGenerationTests.cs @@ -111,6 +111,6 @@ public void EntityNameShouldSetModelEntityNamePropertyToFalse() .ModelShouldMatch(x => x.EntityName.ShouldEqual("entity1")); } - private class FakeProxyType + class FakeProxyType {} } diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/TablePerHierarchyTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/TablePerHierarchyTests.cs index 082b72edf..305f76d99 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/TablePerHierarchyTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/TablePerHierarchyTests.cs @@ -67,8 +67,8 @@ public DerivedMapping() public abstract class BaseManualMapFixture { - private Configuration cfg; - private PersistenceModel model; + Configuration cfg; + PersistenceModel model; [SetUp] public void CreateDatabaseCfg() diff --git a/src/FluentNHibernate.Testing/FluentInterfaceTests/WhereTests.cs b/src/FluentNHibernate.Testing/FluentInterfaceTests/WhereTests.cs index acbb099c4..37ad97044 100644 --- a/src/FluentNHibernate.Testing/FluentInterfaceTests/WhereTests.cs +++ b/src/FluentNHibernate.Testing/FluentInterfaceTests/WhereTests.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.FluentInterfaceTests; [TestFixture] public class WhereTests { - private class StaticExample + class StaticExample { public static string SomeValue = "SomeValue"; } @@ -111,7 +111,7 @@ public void ShouldAllowInheritedProperty() } #region helpers - private string Where(Expression> where) + string Where(Expression> where) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -129,7 +129,7 @@ private string Where(Expression> where) .Where; } - private string WhereSubChild(Expression> where) + string WhereSubChild(Expression> where) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -147,7 +147,7 @@ private string WhereSubChild(Expression> where) .Where; } - private string Where(string where) + string Where(string where) { var classMap = new ClassMap(); classMap.Id(x => x.Id); @@ -167,25 +167,25 @@ private string Where(string where) #endregion - private class Target + class Target { public int Id { get; set; } public IList Children { get; set;} public IList SubChildren { get; set; } } - private class Child + class Child { public string String { get; set; } public int Int { get; set; } public Enum Enum { get; set; } } - private class SubChild : Child + class SubChild : Child { } - private enum Enum + enum Enum { One = 1 } diff --git a/src/FluentNHibernate.Testing/Infrastructure/ContainerTester.cs b/src/FluentNHibernate.Testing/Infrastructure/ContainerTester.cs index 5ce1d3f28..67dd3f481 100644 --- a/src/FluentNHibernate.Testing/Infrastructure/ContainerTester.cs +++ b/src/FluentNHibernate.Testing/Infrastructure/ContainerTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.Infrastructure; [TestFixture] public class ContainerTester { - private Container container; + Container container; [SetUp] public void CreateContainer() @@ -34,9 +34,9 @@ public void ShouldThrowExceptionWhenResolvingUnregisteredType() .WithMessage($"Unable to resolve dependency: '{typeof(IExample).FullName}'"); } - private interface IExample + interface IExample {} - private class Example : IExample + class Example : IExample {} } diff --git a/src/FluentNHibernate.Testing/MappingModel/AttributeStoreTester.cs b/src/FluentNHibernate.Testing/MappingModel/AttributeStoreTester.cs index 064a61a72..ea7fbbc2f 100644 --- a/src/FluentNHibernate.Testing/MappingModel/AttributeStoreTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/AttributeStoreTester.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Testing.MappingModel; [TestFixture] public class AttributeStoreTester { - private sealed class TestStore : AttributeStore + sealed class TestStore : AttributeStore { public bool IsSomething => this.GetOrDefault("IsSomething"); diff --git a/src/FluentNHibernate.Testing/MappingModel/ClassMappingTester.cs b/src/FluentNHibernate.Testing/MappingModel/ClassMappingTester.cs index 6a49c08bc..629e5a625 100644 --- a/src/FluentNHibernate.Testing/MappingModel/ClassMappingTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/ClassMappingTester.cs @@ -11,7 +11,7 @@ namespace FluentNHibernate.Testing.MappingModel; [TestFixture] public class ClassMappingTester { - private ClassMapping mapping; + ClassMapping mapping; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/MappingModel/Defaults/PropertyColumnDefaultsTester.cs b/src/FluentNHibernate.Testing/MappingModel/Defaults/PropertyColumnDefaultsTester.cs index c024fd267..8713842e1 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Defaults/PropertyColumnDefaultsTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Defaults/PropertyColumnDefaultsTester.cs @@ -44,7 +44,7 @@ public void DefaultColumnShouldInheritColumnAttributes() mapping.Columns.First().NotNull.ShouldBeTrue(); } - private Member Prop(Expression> propertyAccessor) + Member Prop(Expression> propertyAccessor) { return ReflectionHelper.GetMember(propertyAccessor); } diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlAnyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlAnyWriterTester.cs index eee9e804a..4de7d5c37 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlAnyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlAnyWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlAnyWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlArrayWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlArrayWriterTester.cs index a15bf617e..925d77f44 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlArrayWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlArrayWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlArrayWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlBagWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlBagWriterTester.cs index 302e3cdc3..3d1cf2001 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlBagWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlBagWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlBagWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCacheWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCacheWriterTester.cs index f4ebd5150..8f2266912 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCacheWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCacheWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlCacheWriterTester { - private XmlCacheWriter writer; + XmlCacheWriter writer; [Test] public void ShouldWriteRegionAttribute() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlClassWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlClassWriterTester.cs index 26378e1ea..ecd441b70 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlClassWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlClassWriterTester.cs @@ -11,7 +11,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlClassWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionRelationshipWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionRelationshipWriterTester.cs index 24e705390..f0aea77ba 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionRelationshipWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionRelationshipWriterTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlCollectionRelationshipWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionWriterTester.cs index 9a5099df9..2f990e3c8 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCollectionWriterTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlCollectionWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlColumnWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlColumnWriterTester.cs index c5e972966..3795e87b1 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlColumnWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlColumnWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlColumnWriterTester { - private XmlColumnWriter writer; + XmlColumnWriter writer; [Test] public void ShouldWriteCheckAttribute() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlComponentWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlComponentWriterTester.cs index ea350af29..37c6225c8 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlComponentWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlComponentWriterTester.cs @@ -10,9 +10,9 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlComponentWriterTester { - private IXmlWriter writer; + IXmlWriter writer; - private XmlWriterTestHelper create_helper() + XmlWriterTestHelper create_helper() { var helper = new XmlWriterTestHelper(); helper.CreateInstance(() => new ComponentMapping(ComponentType.Component)); diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeElementWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeElementWriterTester.cs index 3f69d6de1..8ebf0b4d6 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeElementWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeElementWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlCompositeElementWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeIdWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeIdWriterTester.cs index 9a1c8dfed..b93a73b5d 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeIdWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlCompositeIdWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlCompositeIdWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlDiscriminatorWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlDiscriminatorWriterTester.cs index d2aaaaab8..6c4c7c996 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlDiscriminatorWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlDiscriminatorWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlDiscriminatorWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlDynamicComponentWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlDynamicComponentWriterTester.cs index c2c8227a2..822a0214d 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlDynamicComponentWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlDynamicComponentWriterTester.cs @@ -10,9 +10,9 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlDynamicComponentWriterTester { - private IXmlWriter writer; + IXmlWriter writer; - private XmlWriterTestHelper create_helper() + XmlWriterTestHelper create_helper() { var helper = new XmlWriterTestHelper(); helper.CreateInstance(() => new ComponentMapping(ComponentType.DynamicComponent)); diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlElementWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlElementWriterTester.cs index 526f91828..c015da494 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlElementWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlElementWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlElementWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlGeneratorWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlGeneratorWriterTester.cs index 5c38a2be7..1c25a8484 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlGeneratorWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlGeneratorWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlGeneratorWriterTester { - private XmlGeneratorWriter writer; + XmlGeneratorWriter writer; [Test] public void ShouldWriteRegionAttribute() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlHibernateMappingWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlHibernateMappingWriterTester.cs index a6c601ada..5297e72d0 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlHibernateMappingWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlHibernateMappingWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlHibernateMappingWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIIndexWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIIndexWriterTester.cs index 199b71280..9397eb100 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIIndexWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIIndexWriterTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlIIndexWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdWriterTester.cs index 48e4ea527..3371bbc79 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlIdWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdentityBasedWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdentityBasedWriterTester.cs index df004ee5b..7ee055466 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdentityBasedWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIdentityBasedWriterTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlIdentityBasedWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexManyToManyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexManyToManyWriterTester.cs index d3fa2162f..a4494b69b 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexManyToManyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexManyToManyWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlIndexManyToManyWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexWriterTester.cs index c443ebcf8..9de273000 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlIndexWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlIndexWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlInheritanceWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlInheritanceWriterTester.cs index b7a5aeaea..e8865acd9 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlInheritanceWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlInheritanceWriterTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlInheritanceWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinWriterTester.cs index 27786e9d0..1bbe76994 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinWriterTester.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlJoinWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinedSubclassWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinedSubclassWriterTester.cs index 75ee42f81..edf305560 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinedSubclassWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlJoinedSubclassWriterTester.cs @@ -10,9 +10,9 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlJoinedSubclassWriterTester { - private IXmlWriter writer; + IXmlWriter writer; - private XmlWriterTestHelper create_helper() + XmlWriterTestHelper create_helper() { var helper = new XmlWriterTestHelper(); helper.CreateInstance(() => new SubclassMapping(SubclassType.JoinedSubclass)); diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyManyToOneWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyManyToOneWriterTester.cs index 0eb82b0cf..a93e4d9ca 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyManyToOneWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyManyToOneWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlKeyManyToOneWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyPropertyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyPropertyWriterTester.cs index 8213cbfb6..e5afb26df 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyPropertyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyPropertyWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlKeyPropertyWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyWriterTester.cs index 352f51879..d1c326fc5 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlKeyWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlKeyWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlListWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlListWriterTester.cs index d42e78302..699e9fa8c 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlListWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlListWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlListWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToManyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToManyWriterTester.cs index f63d98e17..afb428071 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToManyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToManyWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlManyToManyWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToOneWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToOneWriterTester.cs index 2e17fa528..1e9c9061c 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToOneWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlManyToOneWriterTester.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlManyToOneWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlMapWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlMapWriterTester.cs index 5627cdac4..d21ac4a98 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlMapWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlMapWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlMapWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlMetaValueWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlMetaValueWriterTester.cs index 47261cdf9..d8f787b31 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlMetaValueWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlMetaValueWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlMetaValueWriterTester { - private XmlMetaValueWriter writer; + XmlMetaValueWriter writer; [Test] public void ShouldWriteValueAttribute() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlNaturalIdWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlNaturalIdWriterTester.cs index 7e5c432e8..d37c3b12e 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlNaturalIdWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlNaturalIdWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlNaturalIdWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToManyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToManyWriterTester.cs index 163bb8b48..949b2de60 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToManyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToManyWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlOneToManyWriterTester { - private XmlOneToManyWriter writer; + XmlOneToManyWriter writer; [SetUp] public void SetUp() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToOneWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToOneWriterTester.cs index 25d3cbec1..31a6b9837 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToOneWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlOneToOneWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlOneToOneWriterTester { - private XmlOneToOneWriter writer; + XmlOneToOneWriter writer; [Test] public void ShouldWriteAccessAttribute() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlPropertyWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlPropertyWriterTester.cs index 0892bda83..a8a52fc96 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlPropertyWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlPropertyWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlPropertyWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlReferenceComponentWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlReferenceComponentWriterTester.cs index 03dfab299..bd096f456 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlReferenceComponentWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlReferenceComponentWriterTester.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlReferenceComponentWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() @@ -28,7 +28,7 @@ public void ShouldWriteNameAttribute() testHelper.VerifyAll(writer); } - private XmlWriterTestHelper CreateTestHelper() + XmlWriterTestHelper CreateTestHelper() { var testHelper = new XmlWriterTestHelper(); @@ -36,7 +36,7 @@ private XmlWriterTestHelper CreateTestHelper() return testHelper; } - private ReferenceComponentMapping CreateInstance() + ReferenceComponentMapping CreateInstance() { var property = new DummyPropertyInfo("ComponentProperty", typeof(ComponentTarget)).ToMember(); var instance = new ReferenceComponentMapping(ComponentType.Component, property, typeof(ComponentTarget), typeof(Target), null); @@ -222,6 +222,7 @@ public void ShouldWritePrimitiveArrays() Assert.Fail(); } - private class Target {} - private class ComponentTarget {} + class Target {} + + class ComponentTarget {} } diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlSetWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlSetWriterTester.cs index 110ab39b1..2536dfe2a 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlSetWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlSetWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlSetWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlStoredProcedureWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlStoredProcedureWriterTester.cs index e94e49117..218712e21 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlStoredProcedureWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlStoredProcedureWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlStoredProcedureWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlSubclassWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlSubclassWriterTester.cs index f84380e69..2f9390e18 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlSubclassWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlSubclassWriterTester.cs @@ -10,9 +10,9 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlSubclassWriterTester { - private IXmlWriter writer; + IXmlWriter writer; - private XmlWriterTestHelper create_helper() + XmlWriterTestHelper create_helper() { var helper = new XmlWriterTestHelper(); helper.CreateInstance(() => new SubclassMapping(SubclassType.Subclass)); diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlTuplizerWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlTuplizerWriterTester.cs index 49adce522..c05d45f41 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlTuplizerWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlTuplizerWriterTester.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlTuplizerWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlVersionWriterTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlVersionWriterTester.cs index 565e2a7e6..cb9612570 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlVersionWriterTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlVersionWriterTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlVersionWriterTester { - private IXmlWriter writer; + IXmlWriter writer; [SetUp] public void GetWriterFromContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/Output/XmlWriterContainerTester.cs b/src/FluentNHibernate.Testing/MappingModel/Output/XmlWriterContainerTester.cs index 5a104a759..6163888e2 100644 --- a/src/FluentNHibernate.Testing/MappingModel/Output/XmlWriterContainerTester.cs +++ b/src/FluentNHibernate.Testing/MappingModel/Output/XmlWriterContainerTester.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Testing.MappingModel.Output; [TestFixture] public class XmlWriterContainerTester { - private XmlWriterContainer container; + XmlWriterContainer container; [SetUp] public void CreateContainer() diff --git a/src/FluentNHibernate.Testing/MappingModel/ReferenceComponentMappingSpecs.cs b/src/FluentNHibernate.Testing/MappingModel/ReferenceComponentMappingSpecs.cs index 5047baf64..fbe5dfc44 100644 --- a/src/FluentNHibernate.Testing/MappingModel/ReferenceComponentMappingSpecs.cs +++ b/src/FluentNHibernate.Testing/MappingModel/ReferenceComponentMappingSpecs.cs @@ -38,10 +38,12 @@ public void should_allow_access_to_the_member_property() referenceComponentMapping.Member.ShouldEqual(memberProperty); } - private Member memberProperty; - private ReferenceComponentMapping referenceComponentMapping; - private class Target {} - private class ComponentTarget {} + Member memberProperty; + ReferenceComponentMapping referenceComponentMapping; + + class Target {} + + class ComponentTarget {} } [TestFixture] @@ -119,13 +121,14 @@ public void should_copy_all_the_collections_from_the_external_component() referenceComponentMapping.References.ItemsShouldBeEqual(externalComponentMapping.References); } - private ReferenceComponentMapping referenceComponentMapping; - private ExternalComponentMapping externalComponentMapping; - private Member memberProperty; - private ParentMapping parentMapping; + ReferenceComponentMapping referenceComponentMapping; + ExternalComponentMapping externalComponentMapping; + Member memberProperty; + ParentMapping parentMapping; + + class ComponentTarget { } - private class ComponentTarget { } - private class Target + class Target { public ComponentTarget Component { get; set; } } diff --git a/src/FluentNHibernate.Testing/PersistenceModelTests/JoinPersistenceModelTests.cs b/src/FluentNHibernate.Testing/PersistenceModelTests/JoinPersistenceModelTests.cs index bb6ddf954..164e8dd2e 100644 --- a/src/FluentNHibernate.Testing/PersistenceModelTests/JoinPersistenceModelTests.cs +++ b/src/FluentNHibernate.Testing/PersistenceModelTests/JoinPersistenceModelTests.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Testing.PersistenceModelTests; [TestFixture] public class JoinPersistenceModelTests { - private Configuration cfg; + Configuration cfg; [SetUp] public void CreateConfig() @@ -36,7 +36,7 @@ public void ShouldntDuplicateJoinMapping() .JoinClosureIterator.Count().ShouldEqual(1); } - private class Target + class Target { public int Id { get; set; } public string Property { get; set; } diff --git a/src/FluentNHibernate.Testing/PersistenceModelTests/SeparateSubclassVisitorFixture.cs b/src/FluentNHibernate.Testing/PersistenceModelTests/SeparateSubclassVisitorFixture.cs index ca6571193..9b6d0f2b5 100644 --- a/src/FluentNHibernate.Testing/PersistenceModelTests/SeparateSubclassVisitorFixture.cs +++ b/src/FluentNHibernate.Testing/PersistenceModelTests/SeparateSubclassVisitorFixture.cs @@ -11,8 +11,8 @@ namespace FluentNHibernate.Testing.PersistenceModelTests; [TestFixture] public class SeparateSubclassVisitorFixture { - private IIndeterminateSubclassMappingProviderCollection providers; - private ClassMapping fooMapping; + IIndeterminateSubclassMappingProviderCollection providers; + ClassMapping fooMapping; [SetUp] public void SetUp() @@ -151,47 +151,47 @@ public void Should_choose_UnionSubclass_when_the_class_mapping_IsUnionSubclass_i fooMapping.Subclasses.First().SubclassType.ShouldEqual(SubclassType.UnionSubclass); } - private SeparateSubclassVisitor CreateSut() + SeparateSubclassVisitor CreateSut() { return new SeparateSubclassVisitor(providers); } - private interface IFoo + interface IFoo { } - private class Base : IFoo + class Base : IFoo { } - private abstract class BaseImpl : Base + abstract class BaseImpl : Base { } - private class Foo : BaseImpl, IFoo + class Foo : BaseImpl, IFoo { } - private class FooMap : ClassMap + class FooMap : ClassMap { } - private class BaseMap : ClassMap + class BaseMap : ClassMap { } - private class BaseImplMap : SubclassMap + class BaseImplMap : SubclassMap { } - private abstract class GenericFooMap : SubclassMap> + abstract class GenericFooMap : SubclassMap> { } - private class StringFooMap : GenericFooMap + class StringFooMap : GenericFooMap { } - private interface IStand + interface IStand { } - private class StandAlone : IStand + class StandAlone : IStand { } - private class StandAloneMap : SubclassMap + class StandAloneMap : SubclassMap { } class ExtendsParent diff --git a/src/FluentNHibernate.Testing/StubTypeSource.cs b/src/FluentNHibernate.Testing/StubTypeSource.cs index 31e2d2b6f..fa5ca8658 100644 --- a/src/FluentNHibernate.Testing/StubTypeSource.cs +++ b/src/FluentNHibernate.Testing/StubTypeSource.cs @@ -4,9 +4,9 @@ namespace FluentNHibernate.Testing; -internal class StubTypeSource : ITypeSource +class StubTypeSource : ITypeSource { - private readonly IEnumerable types; + readonly IEnumerable types; public StubTypeSource(params Type[] types) { diff --git a/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationExtensionsSpecs.cs b/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationExtensionsSpecs.cs index 99e8ebc6b..0aebfa48e 100644 --- a/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationExtensionsSpecs.cs +++ b/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationExtensionsSpecs.cs @@ -29,7 +29,7 @@ public InspectablePersistenceSpecification(ISession session, IEqualityComparer e public abstract class With_persistence_specification : Specification { - private ISession session; + ISession session; protected InspectablePersistenceSpecification sut; protected IEqualityComparer comparer; @@ -135,7 +135,7 @@ public void should_set_the_custom_equality_comparer() [TestFixture] public class When_the_value_setter_of_a_checked_property_is_invoked : When_a_checked_property_with_a_custom_setter_is_added { - private PropertyEntity entity; + PropertyEntity entity; public override void establish_context() { @@ -221,8 +221,8 @@ public void should_set_the_custom_equality_comparer() [TestFixture] public class When_the_value_setter_of_a_checked_reference_is_invoked : When_a_checked_reference_with_a_custom_setter_is_added { - private ReferenceEntity entity; - private OtherEntity referenced; + ReferenceEntity entity; + OtherEntity referenced; public override void establish_context() { @@ -376,8 +376,8 @@ public void should_set_the_custom_equality_comparer() [TestFixture] public class When_the_list_setter_of_a_checked_list_is_invoked : When_a_checked_list_with_a_custom_list_setter_is_added { - private ReferenceEntity entity; - private OtherEntity[] referenced; + ReferenceEntity entity; + OtherEntity[] referenced; public override void establish_context() { @@ -437,8 +437,8 @@ public void should_set_the_custom_equality_comparer() [TestFixture] public class When_the_list_item_setter_of_a_checked_list_is_invoked : When_a_checked_list_with_a_custom_list_item_setter_is_added { - private ReferenceEntity entity; - private OtherEntity[] referenced; + ReferenceEntity entity; + OtherEntity[] referenced; public override void establish_context() { @@ -526,8 +526,8 @@ public void should_set_the_custom_equality_comparer() [TestFixture] public class When_the_list_setter_of_a_checked_component_list_is_invoked : When_a_checked_component_list_with_a_custom_list_setter_is_added { - private ReferenceEntity entity; - private OtherEntity[] referenced; + ReferenceEntity entity; + OtherEntity[] referenced; public override void establish_context() { @@ -587,8 +587,8 @@ public void should_set_the_custom_equality_comparer() [TestFixture] public class When_the_list_item_setter_of_a_checked_component_list_is_invoked : When_a_checked_component_list_with_a_custom_list_item_setter_is_added { - private ReferenceEntity entity; - private OtherEntity[] referenced; + ReferenceEntity entity; + OtherEntity[] referenced; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTester.cs b/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTester.cs index 6f094ae2a..49c0f3ce4 100644 --- a/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTester.cs +++ b/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTester.cs @@ -69,12 +69,12 @@ public int GetHashCode(object obj) } } - private PersistenceSpecification spec; - private ISession session; - private ITransaction transaction; - private Cat cat; - private Cat identicalCat; - private ISessionSource sessionSource; + PersistenceSpecification spec; + ISession session; + ITransaction transaction; + Cat cat; + Cat identicalCat; + ISessionSource sessionSource; [SetUp] public void Setup() @@ -189,7 +189,7 @@ public void Comparing_reference_should_use_the_specified_property_comparisons() [TestFixture] public class PersistenceSpecificationConstructorTests { - private ISessionSource sessionSource; + ISessionSource sessionSource; [SetUp] public void Setup() @@ -251,7 +251,7 @@ protected ProtectedConstructorClass() { } public class PrivateConstructorClass { - private PrivateConstructorClass() { } + PrivateConstructorClass() { } } public class NoParameterlessConstructorClass diff --git a/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTransactionTest.cs b/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTransactionTest.cs index 086ec1eed..94ab7cede 100644 --- a/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTransactionTest.cs +++ b/src/FluentNHibernate.Testing/Testing/PersistenceSpecificationTransactionTest.cs @@ -8,14 +8,14 @@ namespace FluentNHibernate.Testing.Testing; [TestFixture] public class PersistenceSpecificationTransactionTest { - private class Cat + class Cat { public long Id { get; set; } public string Name { get; set; } public CatType CatType { get; set; } } - private class CatType + class CatType { public string Name { get; set; } } diff --git a/src/FluentNHibernate.Testing/Testing/SessionSourceConfigurationTester.cs b/src/FluentNHibernate.Testing/Testing/SessionSourceConfigurationTester.cs index c9ca02e09..99c217399 100644 --- a/src/FluentNHibernate.Testing/Testing/SessionSourceConfigurationTester.cs +++ b/src/FluentNHibernate.Testing/Testing/SessionSourceConfigurationTester.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Testing.Testing; [TestFixture] public class when_building_a_session_source : with_fluent_configuration { - private ISessionSource _sessionSource; + ISessionSource _sessionSource; public override void establish_context() { @@ -31,7 +31,7 @@ public void should_be_able_to_generate_the_schema() [TestFixture] public class when_using_a_session_source_and_schema : with_fluent_configuration { - private ISessionSource _sessionSource; + ISessionSource _sessionSource; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Testing/Values/Entities.cs b/src/FluentNHibernate.Testing/Testing/Values/Entities.cs index a59b22396..eb280504e 100644 --- a/src/FluentNHibernate.Testing/Testing/Values/Entities.cs +++ b/src/FluentNHibernate.Testing/Testing/Values/Entities.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Testing.Testing.Values; public class ListEntity { - private readonly IList backingField = new List(); + readonly IList backingField = new List(); //Set = new HashedSet(); @@ -40,7 +40,7 @@ public void SetReference(OtherEntity value) public class PropertyEntity { - private string backingField; + string backingField; public string GetterAndSetter { get; set; } public string GetterAndPrivateSetter { get; private set; } diff --git a/src/FluentNHibernate.Testing/Testing/Values/ListSpecs.cs b/src/FluentNHibernate.Testing/Testing/Values/ListSpecs.cs index 63a2a6dba..82abbc86a 100644 --- a/src/FluentNHibernate.Testing/Testing/Values/ListSpecs.cs +++ b/src/FluentNHibernate.Testing/Testing/Values/ListSpecs.cs @@ -12,7 +12,7 @@ namespace FluentNHibernate.Testing.Testing.Values; public abstract class With_list_entity : Specification { - private Accessor property; + Accessor property; protected ListEntity target; protected List sut; protected string[] listItems; @@ -450,7 +450,7 @@ public void should_perform_the_check_with_the_custom_equality_comparer() [TestFixture] public class When_a_list_is_checked_with_a_custom_equality_comparer_that_fails : With_initialized_list { - private InvalidOperationException exception; + InvalidOperationException exception; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Testing/Values/PropertySpecs.cs b/src/FluentNHibernate.Testing/Testing/Values/PropertySpecs.cs index 9b314bcf1..79f5c505c 100644 --- a/src/FluentNHibernate.Testing/Testing/Values/PropertySpecs.cs +++ b/src/FluentNHibernate.Testing/Testing/Values/PropertySpecs.cs @@ -11,7 +11,7 @@ namespace FluentNHibernate.Testing.Testing.Values; public abstract class With_property_entity : Specification { - private Accessor property; + Accessor property; protected PropertyEntity target; protected Property sut; @@ -158,7 +158,7 @@ public void should_tell_which_property_failed_to_be_set() public abstract class With_initialized_property : Specification { - private Accessor property; + Accessor property; protected PropertyEntity target; protected Property sut; @@ -263,7 +263,7 @@ public void should_perform_the_check_with_the_custom_equality_comparer() [TestFixture] public class When_a_property_is_checked_with_a_custom_equality_comparer_that_fails : With_initialized_property { - private InvalidOperationException exception; + InvalidOperationException exception; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Testing/Values/ReferenceListSpecs.cs b/src/FluentNHibernate.Testing/Testing/Values/ReferenceListSpecs.cs index 7b6c7216f..dbc01d4d1 100644 --- a/src/FluentNHibernate.Testing/Testing/Values/ReferenceListSpecs.cs +++ b/src/FluentNHibernate.Testing/Testing/Values/ReferenceListSpecs.cs @@ -12,10 +12,10 @@ namespace FluentNHibernate.Testing.Testing.Values; [TestFixture] public class When_a_reference_list_is_registered_on_the_persistence_specification : Specification { - private ReferenceList sut; - private PersistenceSpecification specification; - private ISession session; - private List referencedEntities; + ReferenceList sut; + PersistenceSpecification specification; + ISession session; + List referencedEntities; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Testing/Values/ReferencePropertySpecs.cs b/src/FluentNHibernate.Testing/Testing/Values/ReferencePropertySpecs.cs index f44646807..3f7a2a7b8 100644 --- a/src/FluentNHibernate.Testing/Testing/Values/ReferencePropertySpecs.cs +++ b/src/FluentNHibernate.Testing/Testing/Values/ReferencePropertySpecs.cs @@ -11,10 +11,10 @@ namespace FluentNHibernate.Testing.Testing.Values; [TestFixture] public class When_a_reference_property_is_registered_on_the_persistence_specification : Specification { - private ReferenceProperty sut; - private PersistenceSpecification specification; - private OtherEntity referencedEntity; - private ISession session; + ReferenceProperty sut; + PersistenceSpecification specification; + OtherEntity referencedEntity; + ISession session; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Utils/TypeReferenceEnumTests.cs b/src/FluentNHibernate.Testing/Utils/TypeReferenceEnumTests.cs index b92b42619..7c74e2ab2 100644 --- a/src/FluentNHibernate.Testing/Utils/TypeReferenceEnumTests.cs +++ b/src/FluentNHibernate.Testing/Utils/TypeReferenceEnumTests.cs @@ -23,7 +23,7 @@ public void IsEnumOnTypeReferenceToGenericEnumMapperShouldBeTrue() enumTypeReference.IsEnum.ShouldBeTrue(); } - private enum TestEnum + enum TestEnum { Value1 } diff --git a/src/FluentNHibernate.Testing/Visitors/ComponentColumnPrefixVisitorSpecs.cs b/src/FluentNHibernate.Testing/Visitors/ComponentColumnPrefixVisitorSpecs.cs index 39fd20612..90f1afff2 100644 --- a/src/FluentNHibernate.Testing/Visitors/ComponentColumnPrefixVisitorSpecs.cs +++ b/src/FluentNHibernate.Testing/Visitors/ComponentColumnPrefixVisitorSpecs.cs @@ -16,7 +16,7 @@ public class when_the_component_column_prefix_visitor_processes_a_reference_comp PersistenceModel model; IEnumerable mappings; ClassMapping target_mapping; - private const string column_prefix = "{property}_"; + const string column_prefix = "{property}_"; public override void establish_context() { @@ -57,8 +57,8 @@ public class when_the_component_column_prefix_visitor_processes_a_reference_comp PersistenceModel model; IEnumerable mappings; ClassMapping target_mapping; - private const string first_prefix = "first_"; - private const string second_prefix = "second_"; + const string first_prefix = "first_"; + const string second_prefix = "second_"; public override void establish_context() { @@ -105,10 +105,10 @@ public void should_prefix_sub_component_columns_with_both_prefixes() [TestFixture] public class when_the_component_column_prefix_visitor_processes_a_reference_component_after_already_processed_another : ComponentColumnPrefixVisitorSpec { - private const string column_prefix = "prefix_"; - private ComponentColumnPrefixVisitor visitor; - private ReferenceComponentMapping reference_with_a_prefix; - private ReferenceComponentMapping reference_without_a_prefix; + const string column_prefix = "prefix_"; + ComponentColumnPrefixVisitor visitor; + ReferenceComponentMapping reference_with_a_prefix; + ReferenceComponentMapping reference_without_a_prefix; public override void establish_context() { @@ -144,7 +144,7 @@ public class when_the_component_column_prefix_visitor_processes_a_reference_comp PersistenceModel model; IEnumerable mappings; ClassMapping target_mapping; - private const string column_prefix = "prefix_"; + const string column_prefix = "prefix_"; public override void establish_context() { diff --git a/src/FluentNHibernate.Testing/Visitors/ComponentReferenceResolutionVisitorSpecs.cs b/src/FluentNHibernate.Testing/Visitors/ComponentReferenceResolutionVisitorSpecs.cs index 9ba094d6b..341ddc1d6 100644 --- a/src/FluentNHibernate.Testing/Visitors/ComponentReferenceResolutionVisitorSpecs.cs +++ b/src/FluentNHibernate.Testing/Visitors/ComponentReferenceResolutionVisitorSpecs.cs @@ -35,8 +35,8 @@ public void should_associate_external_mapping_with_reference_mapping() referenceComponentMapping.IsAssociated.ShouldBeTrue(); } - private ReferenceComponentMapping referenceComponentMapping; - private ExternalComponentMapping externalComponentMapping; + ReferenceComponentMapping referenceComponentMapping; + ExternalComponentMapping externalComponentMapping; } [TestFixture] diff --git a/src/FluentNHibernate/Automapping/AutoJoinedSubClassPart.cs b/src/FluentNHibernate/Automapping/AutoJoinedSubClassPart.cs index e38fbfa1a..10af890bc 100644 --- a/src/FluentNHibernate/Automapping/AutoJoinedSubClassPart.cs +++ b/src/FluentNHibernate/Automapping/AutoJoinedSubClassPart.cs @@ -10,8 +10,8 @@ namespace FluentNHibernate.Automapping; public class AutoJoinedSubClassPart : JoinedSubClassPart, IAutoClasslike #pragma warning restore 612,618 { - private readonly MappingProviderStore providers; - private readonly IList mappedMembers = new List(); + readonly MappingProviderStore providers; + readonly IList mappedMembers = new List(); public AutoJoinedSubClassPart(string keyColumn) : this(keyColumn, new MappingProviderStore()) diff --git a/src/FluentNHibernate/Automapping/AutoMapper.cs b/src/FluentNHibernate/Automapping/AutoMapper.cs index 8b73395b6..32dd161fe 100644 --- a/src/FluentNHibernate/Automapping/AutoMapper.cs +++ b/src/FluentNHibernate/Automapping/AutoMapper.cs @@ -16,7 +16,7 @@ public class AutoMapper( { List mappingTypes; - private void ApplyOverrides(Type classType, IList mappedMembers, ClassMappingBase mapping) + void ApplyOverrides(Type classType, IList mappedMembers, ClassMappingBase mapping) { var autoMapType = ReflectionHelper.AutomappingTypeForEntityType(classType); var autoMap = Activator.CreateInstance(autoMapType, mappedMembers); @@ -42,7 +42,7 @@ public ClassMappingBase MergeMap(Type classType, ClassMappingBase mapping, IList return mapping; } - private void MapInheritanceTree(Type classType, ClassMappingBase mapping, IList mappedMembers) + void MapInheritanceTree(Type classType, ClassMappingBase mapping, IList mappedMembers) { var discriminatorSet = HasDiscriminator(mapping); var isDiscriminated = cfg.IsDiscriminated(classType) || discriminatorSet; @@ -136,7 +136,7 @@ static AutoMapType GetLogicalParent(Type type, IDictionary av return GetLogicalParent(type.BaseType, availableTypes); } - private void MapSubclass(IList mappedMembers, SubclassMapping subclass, AutoMapType inheritedClass) + void MapSubclass(IList mappedMembers, SubclassMapping subclass, AutoMapType inheritedClass) { subclass.Set(x => x.Name, Layer.Defaults, inheritedClass.Type.AssemblyQualifiedName); subclass.Set(x => x.Type, Layer.Defaults, inheritedClass.Type); diff --git a/src/FluentNHibernate/Automapping/AutoMappingAlterationCollection.cs b/src/FluentNHibernate/Automapping/AutoMappingAlterationCollection.cs index 1b9a930b6..77ddd13ff 100644 --- a/src/FluentNHibernate/Automapping/AutoMappingAlterationCollection.cs +++ b/src/FluentNHibernate/Automapping/AutoMappingAlterationCollection.cs @@ -8,13 +8,13 @@ namespace FluentNHibernate.Automapping; public class AutoMappingAlterationCollection : IEnumerable { - private readonly List alterations = new List(); + readonly List alterations = new List(); /// /// Creates an instance of an IAutoMappingAlteration from a type instance, then adds it to the alterations collection. /// /// Type of an IAutoMappingAlteration - private void Add(Type type) + void Add(Type type) { Add((IAutoMappingAlteration)Activator.CreateInstance(type)); } diff --git a/src/FluentNHibernate/Automapping/AutoMappingExpressions.cs b/src/FluentNHibernate/Automapping/AutoMappingExpressions.cs index f75e43f6f..12df6fa3a 100644 --- a/src/FluentNHibernate/Automapping/AutoMappingExpressions.cs +++ b/src/FluentNHibernate/Automapping/AutoMappingExpressions.cs @@ -58,7 +58,7 @@ public class AutoMappingExpressions #pragma warning disable 612,618 // disabled obsolete warnings for this class -internal class ExpressionBasedAutomappingConfiguration(AutoMappingExpressions expressions) +class ExpressionBasedAutomappingConfiguration(AutoMappingExpressions expressions) : DefaultAutomappingConfiguration { public override bool ShouldMap(Member member) diff --git a/src/FluentNHibernate/Automapping/AutoPersistenceModel.cs b/src/FluentNHibernate/Automapping/AutoPersistenceModel.cs index f3407cc74..c78f0a940 100644 --- a/src/FluentNHibernate/Automapping/AutoPersistenceModel.cs +++ b/src/FluentNHibernate/Automapping/AutoPersistenceModel.cs @@ -135,7 +135,7 @@ public override IEnumerable BuildMappings() return base.BuildMappings(); } - private void CompileMappings() + void CompileMappings() { if (autoMappingsCreated) return; @@ -179,7 +179,7 @@ private void CompileMappings() autoMappingsCreated = true; } - private int InheritanceHierarchyDepth(Type type) + int InheritanceHierarchyDepth(Type type) { var depth = 0; var parent = type; @@ -200,7 +200,7 @@ public override void Configure(NHibernate.Cfg.Configuration configuration) base.Configure(configuration); } - private void AddMapping(Type type) + void AddMapping(Type type) { Type typeToMap = GetTypeToMap(type); @@ -218,7 +218,7 @@ private void AddMapping(Type type) Add(new PassThroughMappingProvider(mapping)); } - private Type GetTypeToMap(Type type) + Type GetTypeToMap(Type type) { while (ShouldMapParent(type)) { @@ -228,12 +228,12 @@ private Type GetTypeToMap(Type type) return type; } - private bool ShouldMapParent(Type type) + bool ShouldMapParent(Type type) { return ShouldMap(type.BaseType) && !cfg.IsConcreteBaseType(type.BaseType); } - private bool ShouldMap(Type type) + bool ShouldMap(Type type) { if (includedTypes.Contains(type)) return true; // inclusions take precedence over everything @@ -390,7 +390,7 @@ public void Override(Type overrideType) } //called reflectively from method above - private void OverrideHelper(AutoMapping x, IAutoMappingOverride mappingOverride) + void OverrideHelper(AutoMapping x, IAutoMappingOverride mappingOverride) { mappingOverride.Override(x); } diff --git a/src/FluentNHibernate/Automapping/AutoSubClassPart.cs b/src/FluentNHibernate/Automapping/AutoSubClassPart.cs index 0bdb3ba57..c42d76105 100644 --- a/src/FluentNHibernate/Automapping/AutoSubClassPart.cs +++ b/src/FluentNHibernate/Automapping/AutoSubClassPart.cs @@ -10,8 +10,8 @@ namespace FluentNHibernate.Automapping; public class AutoSubClassPart : SubClassPart, IAutoClasslike #pragma warning restore 612,618 { - private readonly MappingProviderStore providers; - private readonly IList mappedMembers = new List(); + readonly MappingProviderStore providers; + readonly IList mappedMembers = new List(); public AutoSubClassPart(DiscriminatorPart parent, string discriminatorValue) : this(parent, discriminatorValue, new MappingProviderStore()) diff --git a/src/FluentNHibernate/Automapping/Steps/HasManyToManyStep.cs b/src/FluentNHibernate/Automapping/Steps/HasManyToManyStep.cs index 89fe0185b..480905e63 100644 --- a/src/FluentNHibernate/Automapping/Steps/HasManyToManyStep.cs +++ b/src/FluentNHibernate/Automapping/Steps/HasManyToManyStep.cs @@ -25,7 +25,7 @@ public bool ShouldMap(Member member) return hasInverse; } - private static Member GetInverseProperty(Member member) + static Member GetInverseProperty(Member member) { var type = member.PropertyType; var expectedInversePropertyType = type.GetGenericTypeDefinition() @@ -45,7 +45,7 @@ static CollectionMapping GetCollection(Member property) return CollectionMapping.For(collectionType); } - private void ConfigureModel(Member member, CollectionMapping mapping, ClassMappingBase classMap, Type parentSide) + void ConfigureModel(Member member, CollectionMapping mapping, ClassMappingBase classMap, Type parentSide) { // TODO: Make the child type safer mapping.ContainingEntityType = classMap.Type; diff --git a/src/FluentNHibernate/Automapping/Steps/PropertyStep.cs b/src/FluentNHibernate/Automapping/Steps/PropertyStep.cs index a82acd692..621487447 100644 --- a/src/FluentNHibernate/Automapping/Steps/PropertyStep.cs +++ b/src/FluentNHibernate/Automapping/Steps/PropertyStep.cs @@ -22,7 +22,7 @@ public bool ShouldMap(Member member) return IsMappableToColumnType(member); } - private bool HasExplicitTypeConvention(Member property) + bool HasExplicitTypeConvention(Member property) { // todo: clean this up! // What it's doing is finding if there are any IUserType conventions @@ -53,7 +53,7 @@ private bool HasExplicitTypeConvention(Member property) return conventions.FirstOrDefault() is not null; } - private static bool IsMappableToColumnType(Member property) + static bool IsMappableToColumnType(Member property) { return property.PropertyType.Namespace == "System" || property.PropertyType.FullName == "System.Drawing.Bitmap" @@ -65,7 +65,7 @@ public void Map(ClassMappingBase classMap, Member member) classMap.AddProperty(GetPropertyMapping(classMap.Type, member)); } - private PropertyMapping GetPropertyMapping(Type type, Member property) + PropertyMapping GetPropertyMapping(Type type, Member property) { var mapping = new PropertyMapping { diff --git a/src/FluentNHibernate/Automapping/Steps/ReferenceStep.cs b/src/FluentNHibernate/Automapping/Steps/ReferenceStep.cs index 2118d40c9..64745cbb2 100644 --- a/src/FluentNHibernate/Automapping/Steps/ReferenceStep.cs +++ b/src/FluentNHibernate/Automapping/Steps/ReferenceStep.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Automapping.Steps; public class ReferenceStep(IAutomappingConfiguration cfg) : IAutomappingStep { - private readonly Func findPropertyconvention = p => ( + readonly Func findPropertyconvention = p => ( p.PropertyType.Namespace != "System" && // ignore clr types (won't be entities) p.PropertyType.Namespace != "System.Collections.Generic" && p.PropertyType.Namespace != "Iesi.Collections.Generic" && @@ -25,7 +25,7 @@ public void Map(ClassMappingBase classMap, Member member) classMap.AddReference(manyToOne); } - private ManyToOneMapping CreateMapping(Member member) + ManyToOneMapping CreateMapping(Member member) { var mapping = new ManyToOneMapping { Member = member }; diff --git a/src/FluentNHibernate/Automapping/Steps/SimpleTypeCollectionStep.cs b/src/FluentNHibernate/Automapping/Steps/SimpleTypeCollectionStep.cs index eb310d8ec..7f5ff22d0 100644 --- a/src/FluentNHibernate/Automapping/Steps/SimpleTypeCollectionStep.cs +++ b/src/FluentNHibernate/Automapping/Steps/SimpleTypeCollectionStep.cs @@ -59,7 +59,7 @@ void SetDefaultAccess(Member member, CollectionMapping mapping) mapping.Set(x => x.Access, Layer.Defaults, cfg.GetAccessStrategyForReadOnlyProperty(member).ToString()); } - private void SetElement(Member property, ClassMappingBase classMap, CollectionMapping mapping) + void SetElement(Member property, ClassMappingBase classMap, CollectionMapping mapping) { var element = new ElementMapping { diff --git a/src/FluentNHibernate/Cfg/AutoMappingsContainer.cs b/src/FluentNHibernate/Cfg/AutoMappingsContainer.cs index 5d5f7c40d..ffcd6d4f7 100644 --- a/src/FluentNHibernate/Cfg/AutoMappingsContainer.cs +++ b/src/FluentNHibernate/Cfg/AutoMappingsContainer.cs @@ -12,9 +12,9 @@ namespace FluentNHibernate.Cfg; /// public class AutoMappingsContainer : IEnumerable { - private readonly IList mappings = new List(); - private string exportPath; - private TextWriter exportTextWriter; + readonly IList mappings = new List(); + string exportPath; + TextWriter exportTextWriter; internal AutoMappingsContainer() {} diff --git a/src/FluentNHibernate/Cfg/Db/CacheSettingsBuilder.cs b/src/FluentNHibernate/Cfg/Db/CacheSettingsBuilder.cs index 7c291622d..2bed6850d 100644 --- a/src/FluentNHibernate/Cfg/Db/CacheSettingsBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/CacheSettingsBuilder.cs @@ -14,8 +14,8 @@ public class CacheSettingsBuilder protected const string CacheQueryCacheFactoryKey = NHibEnvironment.QueryCacheFactory; protected const string CacheRegionPrefixKey = NHibEnvironment.CacheRegionPrefix; - private readonly IDictionary settings = new Dictionary(); - private bool nextBool = true; + readonly IDictionary settings = new Dictionary(); + bool nextBool = true; [DebuggerBrowsable(DebuggerBrowsableState.Never)] public CacheSettingsBuilder Not diff --git a/src/FluentNHibernate/Cfg/Db/ConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/ConnectionStringBuilder.cs index 20406ae3a..05f2dc10b 100644 --- a/src/FluentNHibernate/Cfg/Db/ConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/ConnectionStringBuilder.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.Cfg.Db; public class ConnectionStringBuilder { - private string connectionString; + string connectionString; #if NETFRAMEWORK public ConnectionStringBuilder FromAppSetting(string appSettingKey) diff --git a/src/FluentNHibernate/Cfg/Db/DB2ConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/DB2ConnectionStringBuilder.cs index c0a10dcc5..236e59cd0 100644 --- a/src/FluentNHibernate/Cfg/Db/DB2ConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/DB2ConnectionStringBuilder.cs @@ -4,10 +4,10 @@ namespace FluentNHibernate.Cfg.Db; public class DB2ConnectionStringBuilder : ConnectionStringBuilder { - private string server; - private string database; - private string username; - private string password; + string server; + string database; + string username; + string password; public DB2ConnectionStringBuilder Server(string server) { diff --git a/src/FluentNHibernate/Cfg/Db/IfxDRDAConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/IfxDRDAConnectionStringBuilder.cs index 8d49fdf51..265640474 100644 --- a/src/FluentNHibernate/Cfg/Db/IfxDRDAConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/IfxDRDAConnectionStringBuilder.cs @@ -2,17 +2,17 @@ namespace FluentNHibernate.Cfg.Db; public class IfxDRDAConnectionStringBuilder : ConnectionStringBuilder { - private string authentication = ""; - private string database = ""; - private string hostVarParameter = ""; - private string isolationLevel = ""; - private string maxPoolSize = ""; - private string minPoolSize = ""; - private string password = ""; - private string pooling = ""; - private string server = ""; - private string username = ""; - private string otherOptions = ""; + string authentication = ""; + string database = ""; + string hostVarParameter = ""; + string isolationLevel = ""; + string maxPoolSize = ""; + string minPoolSize = ""; + string password = ""; + string pooling = ""; + string server = ""; + string username = ""; + string otherOptions = ""; /// /// The type of authentication to be used. Acceptable values: diff --git a/src/FluentNHibernate/Cfg/Db/IfxSQLIConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/IfxSQLIConnectionStringBuilder.cs index de46e5b61..1d20149f8 100644 --- a/src/FluentNHibernate/Cfg/Db/IfxSQLIConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/IfxSQLIConnectionStringBuilder.cs @@ -2,19 +2,19 @@ namespace FluentNHibernate.Cfg.Db; public class IfxSQLIConnectionStringBuilder : ConnectionStringBuilder { - private string clientLocale = ""; - private string database = ""; - private string databaseLocale = ""; - private bool delimident = true; - private string host = ""; - private string maxPoolSize = ""; - private string minPoolSize = ""; - private string password = ""; - private string pooling = ""; - private string server = ""; - private string service = ""; - private string username = ""; - private string otherOptions = ""; + string clientLocale = ""; + string database = ""; + string databaseLocale = ""; + bool delimident = true; + string host = ""; + string maxPoolSize = ""; + string minPoolSize = ""; + string password = ""; + string pooling = ""; + string server = ""; + string service = ""; + string username = ""; + string otherOptions = ""; /// /// Client locale, default value is en_us.CP1252 (Windows) diff --git a/src/FluentNHibernate/Cfg/Db/IngresConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/IngresConnectionStringBuilder.cs index f0cdd5e19..ddbb2e2f2 100644 --- a/src/FluentNHibernate/Cfg/Db/IngresConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/IngresConnectionStringBuilder.cs @@ -4,11 +4,11 @@ namespace FluentNHibernate.Cfg.Db; public class IngresConnectionStringBuilder : ConnectionStringBuilder { - private string server; - private string database; - private string port; - private string username; - private string password; + string server; + string database; + string port; + string username; + string password; public IngresConnectionStringBuilder Server(string server) { diff --git a/src/FluentNHibernate/Cfg/Db/JetDriverConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/JetDriverConnectionStringBuilder.cs index 0309ec073..e7ce5f397 100644 --- a/src/FluentNHibernate/Cfg/Db/JetDriverConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/JetDriverConnectionStringBuilder.cs @@ -4,11 +4,11 @@ namespace FluentNHibernate.Cfg.Db; public class JetDriverConnectionStringBuilder : ConnectionStringBuilder { - private string databaseFile; + string databaseFile; // Default provider - private string provider = "Microsoft.Jet.OLEDB.4.0"; - private string username; - private string password; + string provider = "Microsoft.Jet.OLEDB.4.0"; + string username; + string password; // Use Provider("Microsoft.ACE.OLEDB.12.0") for Access 2007 database public JetDriverConnectionStringBuilder Provider(string provider) diff --git a/src/FluentNHibernate/Cfg/Db/MsSqlConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/MsSqlConnectionStringBuilder.cs index dec2b4d61..655178551 100644 --- a/src/FluentNHibernate/Cfg/Db/MsSqlConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/MsSqlConnectionStringBuilder.cs @@ -4,11 +4,11 @@ namespace FluentNHibernate.Cfg.Db; public class MsSqlConnectionStringBuilder : ConnectionStringBuilder { - private string server; - private string database; - private string username; - private string password; - private bool trustedConnection; + string server; + string database; + string username; + string password; + bool trustedConnection; public MsSqlConnectionStringBuilder Server(string server) { diff --git a/src/FluentNHibernate/Cfg/Db/MySQLConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/MySQLConnectionStringBuilder.cs index 3569c13cc..386b76914 100644 --- a/src/FluentNHibernate/Cfg/Db/MySQLConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/MySQLConnectionStringBuilder.cs @@ -4,11 +4,11 @@ namespace FluentNHibernate.Cfg.Db; public class MySQLConnectionStringBuilder : ConnectionStringBuilder { - private string server; - private int? port; - private string database; - private string username; - private string password; + string server; + int? port; + string database; + string username; + string password; public MySQLConnectionStringBuilder Server(string server) { diff --git a/src/FluentNHibernate/Cfg/Db/OdbcConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/OdbcConnectionStringBuilder.cs index 65aa82914..b8e425da2 100644 --- a/src/FluentNHibernate/Cfg/Db/OdbcConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/OdbcConnectionStringBuilder.cs @@ -2,10 +2,10 @@ namespace FluentNHibernate.Cfg.Db; public class OdbcConnectionStringBuilder : ConnectionStringBuilder { - private string dsn = ""; - private string username = ""; - private string password = ""; - private string otherOptions = ""; + string dsn = ""; + string username = ""; + string password = ""; + string otherOptions = ""; public OdbcConnectionStringBuilder Dsn(string dsn) { diff --git a/src/FluentNHibernate/Cfg/Db/OracleConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/OracleConnectionStringBuilder.cs index 013afc71e..dc62188cf 100644 --- a/src/FluentNHibernate/Cfg/Db/OracleConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/OracleConnectionStringBuilder.cs @@ -2,15 +2,16 @@ namespace FluentNHibernate.Cfg.Db; public class OracleConnectionStringBuilder : ConnectionStringBuilder { - private string instance; - private string otherOptions; - private string password; + string instance; + string otherOptions; + + string password; // Port is pre-slugged as 1521 is the default Oracle port. - private int port = 1521; - private string server; - private string username; - private bool pooling; - private string statementCacheSize; + int port = 1521; + string server; + string username; + bool pooling; + string statementCacheSize; /// /// Specifies the server to connect. This can be either the DNS name of the diff --git a/src/FluentNHibernate/Cfg/Db/PostgreSQLConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/PostgreSQLConnectionStringBuilder.cs index bf8d5fca6..82cf73f1c 100644 --- a/src/FluentNHibernate/Cfg/Db/PostgreSQLConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/PostgreSQLConnectionStringBuilder.cs @@ -4,11 +4,11 @@ namespace FluentNHibernate.Cfg.Db; public class PostgreSQLConnectionStringBuilder : ConnectionStringBuilder { - private string host; - private int port; - private string database; - private string username; - private string password; + string host; + int port; + string database; + string username; + string password; public PostgreSQLConnectionStringBuilder Host(string host) { diff --git a/src/FluentNHibernate/Cfg/Db/SybaseSQLAnywhereConnectionStringBuilder.cs b/src/FluentNHibernate/Cfg/Db/SybaseSQLAnywhereConnectionStringBuilder.cs index 667f5d5be..85fe3670d 100644 --- a/src/FluentNHibernate/Cfg/Db/SybaseSQLAnywhereConnectionStringBuilder.cs +++ b/src/FluentNHibernate/Cfg/Db/SybaseSQLAnywhereConnectionStringBuilder.cs @@ -4,10 +4,10 @@ namespace FluentNHibernate.Cfg.Db; public class SybaseSQLAnywhereConnectionStringBuilder : ConnectionStringBuilder { - private string server; - private string links; - private string username; - private string password; + string server; + string links; + string username; + string password; public SybaseSQLAnywhereConnectionStringBuilder Server(string server) { diff --git a/src/FluentNHibernate/Cfg/FluentConfiguration.cs b/src/FluentNHibernate/Cfg/FluentConfiguration.cs index 579a35d6c..9024c5343 100644 --- a/src/FluentNHibernate/Cfg/FluentConfiguration.cs +++ b/src/FluentNHibernate/Cfg/FluentConfiguration.cs @@ -266,7 +266,7 @@ public Configuration BuildConfiguration() /// /// Inner exception /// FluentConfigurationException with state - private FluentConfigurationException CreateConfigurationException(Exception innerException) + FluentConfigurationException CreateConfigurationException(Exception innerException) { var ex = new FluentConfigurationException(ExceptionMessage, innerException); diff --git a/src/FluentNHibernate/Cfg/HbmMappingsContainer.cs b/src/FluentNHibernate/Cfg/HbmMappingsContainer.cs index 084038a7e..638f939c4 100644 --- a/src/FluentNHibernate/Cfg/HbmMappingsContainer.cs +++ b/src/FluentNHibernate/Cfg/HbmMappingsContainer.cs @@ -10,8 +10,8 @@ namespace FluentNHibernate.Cfg; /// public class HbmMappingsContainer { - private readonly IList classes = new List(); - private readonly IList assemblies = new List(); + readonly IList classes = new List(); + readonly IList assemblies = new List(); internal HbmMappingsContainer() {} diff --git a/src/FluentNHibernate/Conventions/AcceptanceCriteria/ConcreteAcceptanceCriteria.cs b/src/FluentNHibernate/Conventions/AcceptanceCriteria/ConcreteAcceptanceCriteria.cs index 7737c279a..719e543e6 100644 --- a/src/FluentNHibernate/Conventions/AcceptanceCriteria/ConcreteAcceptanceCriteria.cs +++ b/src/FluentNHibernate/Conventions/AcceptanceCriteria/ConcreteAcceptanceCriteria.cs @@ -11,7 +11,7 @@ namespace FluentNHibernate.Conventions.AcceptanceCriteria; public class ConcreteAcceptanceCriteria : IAcceptanceCriteria where TInspector : IInspector { - private readonly List expectations = new List(); + readonly List expectations = new List(); public IAcceptanceCriteria SameAs() where T : IConventionAcceptance, new() { diff --git a/src/FluentNHibernate/Conventions/ConventionsCollection.cs b/src/FluentNHibernate/Conventions/ConventionsCollection.cs index 21f2ac4e1..a65f7c92d 100644 --- a/src/FluentNHibernate/Conventions/ConventionsCollection.cs +++ b/src/FluentNHibernate/Conventions/ConventionsCollection.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Conventions; public class ConventionsCollection : IEnumerable { - private readonly List inner = new List(); - private readonly List types = new List(); + readonly List inner = new List(); + readonly List types = new List(); public IEnumerator GetEnumerator() { @@ -53,7 +53,7 @@ public IEnumerable this[Type type] get { return inner.Find(x => x.Type == type).GetInstances(); } } - private class AddedConvention(Type type) + class AddedConvention(Type type) { public IList Instances { get; } = new List(); public Type Type { get; } = type; diff --git a/src/FluentNHibernate/Conventions/DefaultConventionFinder.cs b/src/FluentNHibernate/Conventions/DefaultConventionFinder.cs index 8fb5b7a49..9240ecbe7 100644 --- a/src/FluentNHibernate/Conventions/DefaultConventionFinder.cs +++ b/src/FluentNHibernate/Conventions/DefaultConventionFinder.cs @@ -122,7 +122,7 @@ public void Add(T instance) where T : IConvention Conventions.Add(typeof(T), instance); } - private void Add(Type type, MissingConstructor missingConstructor) + void Add(Type type, MissingConstructor missingConstructor) { if (missingConstructor == MissingConstructor.Throw && !HasValidConstructor(type)) throw new MissingConstructorException(type); @@ -135,12 +135,12 @@ private void Add(Type type, MissingConstructor missingConstructor) log.ConventionDiscovered(type); } - private bool AllowMultiplesOf(Type type) + bool AllowMultiplesOf(Type type) { return Attribute.GetCustomAttribute(type, typeof(MultipleAttribute), true) is not null; } - private object Instantiate(Type type) + object Instantiate(Type type) { object instance = null; @@ -156,7 +156,7 @@ private object Instantiate(Type type) return instance; } - private bool HasValidConstructor(Type type) + bool HasValidConstructor(Type type) { foreach (var constructor in type.GetConstructors()) { @@ -166,21 +166,21 @@ private bool HasValidConstructor(Type type) return false; } - private bool IsFinderConstructor(ConstructorInfo constructor) + bool IsFinderConstructor(ConstructorInfo constructor) { var parameters = constructor.GetParameters(); return parameters.Length == 1 && parameters[0].ParameterType == typeof (IConventionFinder); } - private bool IsParameterlessConstructor(ConstructorInfo constructor) + bool IsParameterlessConstructor(ConstructorInfo constructor) { var parameters = constructor.GetParameters(); return parameters.Length == 0; } - private enum MissingConstructor + enum MissingConstructor { Throw, Ignore diff --git a/src/FluentNHibernate/Conventions/Helpers/Builders/BagConventionBuilder.cs b/src/FluentNHibernate/Conventions/Helpers/Builders/BagConventionBuilder.cs index 58345d65b..3e2c98350 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Builders/BagConventionBuilder.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Builders/BagConventionBuilder.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Helpers.Builders; [Obsolete("Use CollectionConventionBuilder")] -internal class BagConventionBuilder : IConventionBuilder +class BagConventionBuilder : IConventionBuilder { public IBagConvention Always(Action convention) { diff --git a/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyConventionBuilder.cs b/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyConventionBuilder.cs index 918e9154f..157544fc3 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyConventionBuilder.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyConventionBuilder.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Conventions.Helpers.Builders; -internal class HasManyConventionBuilder : IConventionBuilder +class HasManyConventionBuilder : IConventionBuilder { public IHasManyConvention Always(Action convention) { diff --git a/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyToManyConventionBuilder.cs b/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyToManyConventionBuilder.cs index 4ec937855..a63511d69 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyToManyConventionBuilder.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Builders/HasManyToManyConventionBuilder.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Conventions.Helpers.Builders; -internal class HasManyToManyConventionBuilder : IConventionBuilder +class HasManyToManyConventionBuilder : IConventionBuilder { public IHasManyToManyConvention Always(Action convention) { diff --git a/src/FluentNHibernate/Conventions/Helpers/Builders/ListConventionBuilder.cs b/src/FluentNHibernate/Conventions/Helpers/Builders/ListConventionBuilder.cs index 073c0beba..71e676d49 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Builders/ListConventionBuilder.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Builders/ListConventionBuilder.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Helpers.Builders; [Obsolete("Use CollectionConventionBuilder")] -internal class ListConventionBuilder : IConventionBuilder +class ListConventionBuilder : IConventionBuilder { public IListConvention Always(Action convention) { diff --git a/src/FluentNHibernate/Conventions/Helpers/Builders/MapConventionBuilder.cs b/src/FluentNHibernate/Conventions/Helpers/Builders/MapConventionBuilder.cs index cac506547..29c8270ed 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Builders/MapConventionBuilder.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Builders/MapConventionBuilder.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Helpers.Builders; [Obsolete("Use CollectionConventionBuilder")] -internal class MapConventionBuilder : IConventionBuilder +class MapConventionBuilder : IConventionBuilder { public IMapConvention Always(Action convention) { diff --git a/src/FluentNHibernate/Conventions/Helpers/Builders/SetConventionBuilder.cs b/src/FluentNHibernate/Conventions/Helpers/Builders/SetConventionBuilder.cs index c5c2aef3f..37e76dae0 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Builders/SetConventionBuilder.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Builders/SetConventionBuilder.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Helpers.Builders; [Obsolete("Use CollectionConventionBuilder")] -internal class SetConventionBuilder : IConventionBuilder +class SetConventionBuilder : IConventionBuilder { public ISetConvention Always(Action convention) { diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltArrayConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltArrayConvention.cs index 3d98993c2..d2f204dc7 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltArrayConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltArrayConvention.cs @@ -6,5 +6,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; [Obsolete("Use BuiltCollectionConvention")] -internal class BuiltArrayConvention(Action> accept, Action convention) +class BuiltArrayConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IArrayConvention, IArrayConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltBagConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltBagConvention.cs index 59800a500..095048984 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltBagConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltBagConvention.cs @@ -6,5 +6,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; [Obsolete("Use BuiltCollectionConvention")] -internal class BuiltBagConvention(Action> accept, Action convention) +class BuiltBagConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IBagConvention, IBagConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltClassConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltClassConvention.cs index 3ee70a62a..fab177b19 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltClassConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltClassConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltClassConvention(Action> accept, Action convention) +class BuiltClassConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IClassConvention, IClassConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltCompositeIdConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltCompositeIdConvention.cs index 6314c9a25..1f01179dd 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltCompositeIdConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltCompositeIdConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltCompositeIdConvention(Action> accept, Action convention) +class BuiltCompositeIdConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), ICompositeIdentityConvention, ICompositeIdentityConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyConvention.cs index f911df45b..b90f615cb 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltHasManyConvention(Action> accept, Action convention) +class BuiltHasManyConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IHasManyConvention, IHasManyConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyToManyConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyToManyConvention.cs index 3086f9e34..890c9d110 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyToManyConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasManyToManyConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltHasManyToManyConvention(Action> accept, Action convention) +class BuiltHasManyToManyConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IHasManyToManyConvention, IHasManyToManyConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasOneConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasOneConvention.cs index a5fae25ce..bf176531d 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasOneConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHasOneConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltHasOneConvention(Action> accept, Action convention) +class BuiltHasOneConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IHasOneConvention, IHasOneConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHibernateMappingConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHibernateMappingConvention.cs index 921d7f6f4..a70947945 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHibernateMappingConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltHibernateMappingConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltHibernateMappingConvention(Action> accept, Action convention) +class BuiltHibernateMappingConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IHibernateMappingConvention; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltIdConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltIdConvention.cs index 2be7e1387..64a6ec35e 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltIdConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltIdConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltIdConvention(Action> accept, Action convention) +class BuiltIdConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IIdConvention, IIdConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinConvention.cs index bac252e5b..1c08e73df 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltJoinConvention(Action> accept, Action convention) +class BuiltJoinConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IJoinConvention, IJoinConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinedSubclassConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinedSubclassConvention.cs index 32f877462..67894f7ce 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinedSubclassConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltJoinedSubclassConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltJoinedSubclassConvention(Action> accept, Action convention) +class BuiltJoinedSubclassConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IJoinedSubclassConvention, IJoinedSubclassConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyManyToOneConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyManyToOneConvention.cs index 4b3e7fe38..67836f090 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyManyToOneConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyManyToOneConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltKeyManyToOneConvention(Action> accept, Action convention) +class BuiltKeyManyToOneConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IKeyManyToOneConvention, IKeyManyToOneConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyPropertyConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyPropertyConvention.cs index 0e722a6cf..6358dbfc1 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyPropertyConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltKeyPropertyConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltKeyPropertyConvention(Action> accept, Action convention) +class BuiltKeyPropertyConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IKeyPropertyConvention, IKeyPropertyConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltListConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltListConvention.cs index 684e61587..73d633a3c 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltListConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltListConvention.cs @@ -6,5 +6,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; [Obsolete("Use BuiltCollectionConvention")] -internal class BuiltListConvention(Action> accept, Action convention) +class BuiltListConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IListConvention, IListConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltMapConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltMapConvention.cs index 5790d2796..54454a666 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltMapConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltMapConvention.cs @@ -6,5 +6,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; [Obsolete("Use BuiltCollectionConvention")] -internal class BuiltMapConvention(Action> accept, Action convention) +class BuiltMapConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IMapConvention, IMapConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltPropertyConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltPropertyConvention.cs index 0be79fef9..400f4ad3a 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltPropertyConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltPropertyConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltPropertyConvention(Action> accept, Action convention) +class BuiltPropertyConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IPropertyConvention, IPropertyConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltReferenceConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltReferenceConvention.cs index cbd1ebd04..5c9ed8946 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltReferenceConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltReferenceConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltReferenceConvention(Action> accept, Action convention) +class BuiltReferenceConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IReferenceConvention, IReferenceConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSetConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSetConvention.cs index 34893d692..4f1d639b3 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSetConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSetConvention.cs @@ -6,5 +6,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; [Obsolete("Use BuiltCollectionConvention")] -internal class BuiltSetConvention(Action> accept, Action convention) +class BuiltSetConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), ISetConvention, ISetConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSubclassConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSubclassConvention.cs index 4258c447d..3b87d9735 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSubclassConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltSubclassConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltSubclassConvention(Action> accept, Action convention) +class BuiltSubclassConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), ISubclassConvention, ISubclassConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltVersionConvention.cs b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltVersionConvention.cs index 29d6075db..86c50e251 100644 --- a/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltVersionConvention.cs +++ b/src/FluentNHibernate/Conventions/Helpers/Prebuilt/BuiltVersionConvention.cs @@ -5,5 +5,5 @@ namespace FluentNHibernate.Conventions.Helpers.Prebuilt; -internal class BuiltVersionConvention(Action> accept, Action convention) +class BuiltVersionConvention(Action> accept, Action convention) : BuiltConventionBase(accept, convention), IVersionConvention, IVersionConventionAcceptance; diff --git a/src/FluentNHibernate/Conventions/Inspections/AnyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/AnyInspector.cs index fc09ff69b..1b717354f 100644 --- a/src/FluentNHibernate/Conventions/Inspections/AnyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/AnyInspector.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class AnyInspector : IAnyInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly AnyMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly AnyMapping mapping; public AnyInspector(AnyMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/CacheInspector.cs b/src/FluentNHibernate/Conventions/Inspections/CacheInspector.cs index e0e3f7959..1c8abfda0 100644 --- a/src/FluentNHibernate/Conventions/Inspections/CacheInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/CacheInspector.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class CacheInspector(CacheMapping mapping) : ICacheInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public string Usage => mapping.Usage; diff --git a/src/FluentNHibernate/Conventions/Inspections/Cascade.cs b/src/FluentNHibernate/Conventions/Inspections/Cascade.cs index d6d4fefde..78f18b62b 100644 --- a/src/FluentNHibernate/Conventions/Inspections/Cascade.cs +++ b/src/FluentNHibernate/Conventions/Inspections/Cascade.cs @@ -12,10 +12,10 @@ public class Cascade : IEquatable public static readonly Cascade Delete = new Cascade("delete"); public static readonly Cascade Merge = new Cascade("merge"); public static readonly Cascade Replicate = new Cascade("replicate"); - - private readonly string value; - private Cascade(string value) + readonly string value; + + Cascade(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/ClassInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ClassInspector.cs index d22b60751..bae451575 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ClassInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ClassInspector.cs @@ -10,8 +10,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class ClassInspector : IClassInspector { - private readonly ClassMapping mapping; - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly ClassMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public ClassInspector(ClassMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/ColumnBasedInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ColumnBasedInspector.cs index 53a83f91b..b227277ce 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ColumnBasedInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ColumnBasedInspector.cs @@ -12,7 +12,7 @@ public abstract class ColumnBasedInspector(IEnumerable columns) /// /// /// - private T GetValueFromColumns(Func property) + T GetValueFromColumns(Func property) { var column = columns.FirstOrDefault(); diff --git a/src/FluentNHibernate/Conventions/Inspections/ColumnInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ColumnInspector.cs index 2574acf76..413bc73e2 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ColumnInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ColumnInspector.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class ColumnInspector(Type containingEntityType, ColumnMapping mapping) : IColumnInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public Type EntityType { get; } = containingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/ComponentInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ComponentInspector.cs index 8f6bbc288..158be0bd8 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ComponentInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ComponentInspector.cs @@ -4,8 +4,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class ComponentInspector : ComponentBaseInspector, IComponentInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); - private readonly IComponentMapping mapping; + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly IComponentMapping mapping; public ComponentInspector(IComponentMapping mapping) : base(mapping) diff --git a/src/FluentNHibernate/Conventions/Inspections/CompositeElementInspector.cs b/src/FluentNHibernate/Conventions/Inspections/CompositeElementInspector.cs index 5f508e306..dc7be0b5b 100644 --- a/src/FluentNHibernate/Conventions/Inspections/CompositeElementInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/CompositeElementInspector.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class CompositeElementInspector(CompositeElementMapping mapping) : ICompositeElementInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/CompositeIdentityInspector.cs b/src/FluentNHibernate/Conventions/Inspections/CompositeIdentityInspector.cs index 7d2fb978e..7b8327357 100644 --- a/src/FluentNHibernate/Conventions/Inspections/CompositeIdentityInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/CompositeIdentityInspector.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class CompositeIdentityInspector(CompositeIdMapping mapping) : ICompositeIdentityInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/DiscriminatorInspector.cs b/src/FluentNHibernate/Conventions/Inspections/DiscriminatorInspector.cs index f0f59d33a..df024f274 100644 --- a/src/FluentNHibernate/Conventions/Inspections/DiscriminatorInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/DiscriminatorInspector.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class DiscriminatorInspector : ColumnBasedInspector, IDiscriminatorInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly DiscriminatorMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly DiscriminatorMapping mapping; public DiscriminatorInspector(DiscriminatorMapping mapping) : base(mapping.Columns) diff --git a/src/FluentNHibernate/Conventions/Inspections/DynamicComponentInspector.cs b/src/FluentNHibernate/Conventions/Inspections/DynamicComponentInspector.cs index 22d0e44e4..62cd766ec 100644 --- a/src/FluentNHibernate/Conventions/Inspections/DynamicComponentInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/DynamicComponentInspector.cs @@ -5,8 +5,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class DynamicComponentInspector(IComponentMapping mapping) : ComponentBaseInspector(mapping), IDynamicComponentInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); - private readonly IComponentMapping mapping = mapping; + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly IComponentMapping mapping = mapping; public override bool IsSet(Member property) { diff --git a/src/FluentNHibernate/Conventions/Inspections/ElementInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ElementInspector.cs index 1edfa4105..85021468c 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ElementInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ElementInspector.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class ElementInspector(ElementMapping mapping) : IElementInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/Fetch.cs b/src/FluentNHibernate/Conventions/Inspections/Fetch.cs index 7c8672234..3ecb2f24f 100644 --- a/src/FluentNHibernate/Conventions/Inspections/Fetch.cs +++ b/src/FluentNHibernate/Conventions/Inspections/Fetch.cs @@ -8,10 +8,10 @@ public class Fetch : IEquatable public static readonly Fetch Select = new Fetch("select"); public static readonly Fetch Join = new Fetch("join"); public static readonly Fetch Subselect = new Fetch("subselect"); - - private readonly string value; - private Fetch(string value) + readonly string value; + + Fetch(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/Generated.cs b/src/FluentNHibernate/Conventions/Inspections/Generated.cs index 295a8be2d..7d9be7b40 100644 --- a/src/FluentNHibernate/Conventions/Inspections/Generated.cs +++ b/src/FluentNHibernate/Conventions/Inspections/Generated.cs @@ -26,9 +26,9 @@ public class Generated : IEquatable /// public static readonly Generated Always = new Generated("always"); - private readonly string value; + readonly string value; - private Generated(string value) + Generated(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/HibernateMappingInspector.cs b/src/FluentNHibernate/Conventions/Inspections/HibernateMappingInspector.cs index b970a679d..b6b07934d 100644 --- a/src/FluentNHibernate/Conventions/Inspections/HibernateMappingInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/HibernateMappingInspector.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class HibernateMappingInspector(HibernateMapping mapping) : IHibernateMappingInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public Type EntityType => mapping.Classes.First().Type; diff --git a/src/FluentNHibernate/Conventions/Inspections/IGeneratorInspector.cs b/src/FluentNHibernate/Conventions/Inspections/IGeneratorInspector.cs index 785c86495..7066bd5c8 100644 --- a/src/FluentNHibernate/Conventions/Inspections/IGeneratorInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/IGeneratorInspector.cs @@ -12,7 +12,7 @@ public interface IGeneratorInspector : IInspector public class GeneratorInspector(GeneratorMapping mapping) : IGeneratorInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/IdentityInspector.cs b/src/FluentNHibernate/Conventions/Inspections/IdentityInspector.cs index 7e2238fbd..e0ac6b2b9 100644 --- a/src/FluentNHibernate/Conventions/Inspections/IdentityInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/IdentityInspector.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class IdentityInspector : ColumnBasedInspector, IIdentityInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly IdMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly IdMapping mapping; public IdentityInspector(IdMapping mapping) : base(mapping.Columns) diff --git a/src/FluentNHibernate/Conventions/Inspections/Include.cs b/src/FluentNHibernate/Conventions/Inspections/Include.cs index ee9c801af..5d2b7c30f 100644 --- a/src/FluentNHibernate/Conventions/Inspections/Include.cs +++ b/src/FluentNHibernate/Conventions/Inspections/Include.cs @@ -13,9 +13,9 @@ public static Include Custom(string value) return new Include(value); } - private readonly string value; + readonly string value; - private Include(string value) + Include(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/IndexInspector.cs b/src/FluentNHibernate/Conventions/Inspections/IndexInspector.cs index 4d033c05e..574535c1c 100644 --- a/src/FluentNHibernate/Conventions/Inspections/IndexInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/IndexInspector.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class IndexInspector(IndexMapping mapping) : IIndexInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/IndexManyToManyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/IndexManyToManyInspector.cs index 56606cc72..ce79f8314 100644 --- a/src/FluentNHibernate/Conventions/Inspections/IndexManyToManyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/IndexManyToManyInspector.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class IndexManyToManyInspector(IndexManyToManyMapping mapping) : IIndexManyToManyInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/InspectorModelMapper.cs b/src/FluentNHibernate/Conventions/Inspections/InspectorModelMapper.cs index 6a777dfa4..3d55dc429 100644 --- a/src/FluentNHibernate/Conventions/Inspections/InspectorModelMapper.cs +++ b/src/FluentNHibernate/Conventions/Inspections/InspectorModelMapper.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class InspectorModelMapper { - private readonly IDictionary mappings = new Dictionary(); + readonly IDictionary mappings = new Dictionary(); public void Map(Expression> inspectorProperty, Expression> mappingProperty) { @@ -19,7 +19,7 @@ public void Map(Expression> inspectorProperty, string m mappings[inspectorProperty.ToMember().Name] = mappingProperty; } - private void Map(Member inspectorProperty, Expression> mappingProperty) + void Map(Member inspectorProperty, Expression> mappingProperty) { mappings[inspectorProperty.Name] = mappingProperty.ToMember().Name; } diff --git a/src/FluentNHibernate/Conventions/Inspections/JoinInspector.cs b/src/FluentNHibernate/Conventions/Inspections/JoinInspector.cs index 440d6b7e5..fa2709eb6 100644 --- a/src/FluentNHibernate/Conventions/Inspections/JoinInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/JoinInspector.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class JoinInspector(JoinMapping mapping) : IJoinInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/JoinInstance.cs b/src/FluentNHibernate/Conventions/Inspections/JoinInstance.cs index d49d9594d..a6bd2a698 100644 --- a/src/FluentNHibernate/Conventions/Inspections/JoinInstance.cs +++ b/src/FluentNHibernate/Conventions/Inspections/JoinInstance.cs @@ -6,8 +6,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class JoinInstance(JoinMapping mapping) : JoinInspector(mapping), IJoinInstance { - private readonly JoinMapping mapping = mapping; - private bool nextBool = true; + readonly JoinMapping mapping = mapping; + bool nextBool = true; [DebuggerBrowsable(DebuggerBrowsableState.Never)] public IJoinInstance Not diff --git a/src/FluentNHibernate/Conventions/Inspections/JoinedSubclassInspector.cs b/src/FluentNHibernate/Conventions/Inspections/JoinedSubclassInspector.cs index d9c440fe4..1e7a76491 100644 --- a/src/FluentNHibernate/Conventions/Inspections/JoinedSubclassInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/JoinedSubclassInspector.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class JoinedSubclassInspector : IJoinedSubclassInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); - private readonly SubclassMapping mapping; + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly SubclassMapping mapping; public JoinedSubclassInspector(SubclassMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/KeyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/KeyInspector.cs index 54d50f6d8..28934ba35 100644 --- a/src/FluentNHibernate/Conventions/Inspections/KeyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/KeyInspector.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class KeyInspector(KeyMapping mapping) : IKeyInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/KeyManyToOneInspector.cs b/src/FluentNHibernate/Conventions/Inspections/KeyManyToOneInspector.cs index 2aa3c0f2b..e668973fa 100644 --- a/src/FluentNHibernate/Conventions/Inspections/KeyManyToOneInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/KeyManyToOneInspector.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class KeyManyToOneInspector : IKeyManyToOneInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); - private readonly KeyManyToOneMapping mapping; + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly KeyManyToOneMapping mapping; public KeyManyToOneInspector(KeyManyToOneMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/KeyPropertyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/KeyPropertyInspector.cs index 430cc35d2..0c56c85ed 100644 --- a/src/FluentNHibernate/Conventions/Inspections/KeyPropertyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/KeyPropertyInspector.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class KeyPropertyInspector(KeyPropertyMapping mapping) : IKeyPropertyInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/ManyToManyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ManyToManyInspector.cs index 23d38921c..d04f9a53c 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ManyToManyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ManyToManyInspector.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class ManyToManyInspector : IManyToManyInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); - private readonly ManyToManyMapping mapping; + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly ManyToManyMapping mapping; public ManyToManyInspector(ManyToManyMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/ManyToOneInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ManyToOneInspector.cs index 4b40bd196..e3046a58b 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ManyToOneInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ManyToOneInspector.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class ManyToOneInspector : IManyToOneInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly ManyToOneMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly ManyToOneMapping mapping; public ManyToOneInspector(ManyToOneMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/MetaValueInspector.cs b/src/FluentNHibernate/Conventions/Inspections/MetaValueInspector.cs index dc15b7781..627d5c7c3 100644 --- a/src/FluentNHibernate/Conventions/Inspections/MetaValueInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/MetaValueInspector.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class MetaValueInspector(MetaValueMapping mapping) : IMetaValueInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/NotFound.cs b/src/FluentNHibernate/Conventions/Inspections/NotFound.cs index 5c3d6211d..182a942f5 100644 --- a/src/FluentNHibernate/Conventions/Inspections/NotFound.cs +++ b/src/FluentNHibernate/Conventions/Inspections/NotFound.cs @@ -8,9 +8,9 @@ public class NotFound : IEquatable public static readonly NotFound Ignore = new NotFound("ignore"); public static readonly NotFound Exception = new NotFound("exception"); - private readonly string value; + readonly string value; - private NotFound(string value) + NotFound(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/OnDelete.cs b/src/FluentNHibernate/Conventions/Inspections/OnDelete.cs index fcd14e513..f538ecb94 100644 --- a/src/FluentNHibernate/Conventions/Inspections/OnDelete.cs +++ b/src/FluentNHibernate/Conventions/Inspections/OnDelete.cs @@ -8,9 +8,9 @@ public class OnDelete : IEquatable public static readonly OnDelete Cascade = new OnDelete("cascade"); public static readonly OnDelete NoAction = new OnDelete("noaction"); - private readonly string value; + readonly string value; - private OnDelete(string value) + OnDelete(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/OneToManyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/OneToManyInspector.cs index 608df20b7..5c27166c0 100644 --- a/src/FluentNHibernate/Conventions/Inspections/OneToManyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/OneToManyInspector.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class OneToManyInspector(OneToManyMapping mapping) : IOneToManyInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/OneToOneInspector.cs b/src/FluentNHibernate/Conventions/Inspections/OneToOneInspector.cs index 35e7b6f5f..90595017e 100644 --- a/src/FluentNHibernate/Conventions/Inspections/OneToOneInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/OneToOneInspector.cs @@ -6,8 +6,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class OneToOneInspector : IOneToOneInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly OneToOneMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly OneToOneMapping mapping; public OneToOneInspector(OneToOneMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/OptimisticLock.cs b/src/FluentNHibernate/Conventions/Inspections/OptimisticLock.cs index edcc4e2ef..a414aa20d 100644 --- a/src/FluentNHibernate/Conventions/Inspections/OptimisticLock.cs +++ b/src/FluentNHibernate/Conventions/Inspections/OptimisticLock.cs @@ -10,9 +10,9 @@ public class OptimisticLock : IEquatable public static readonly OptimisticLock Dirty = new OptimisticLock("dirty"); public static readonly OptimisticLock All = new OptimisticLock("all"); - private readonly string value; + readonly string value; - private OptimisticLock(string value) + OptimisticLock(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/ParentInspector.cs b/src/FluentNHibernate/Conventions/Inspections/ParentInspector.cs index fab5c1e72..00743e61b 100644 --- a/src/FluentNHibernate/Conventions/Inspections/ParentInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/ParentInspector.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class ParentInspector(ParentMapping mapping) : IParentInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); public Type EntityType => mapping.ContainingEntityType; diff --git a/src/FluentNHibernate/Conventions/Inspections/Polymorphism.cs b/src/FluentNHibernate/Conventions/Inspections/Polymorphism.cs index e41ee9b60..4612916bf 100644 --- a/src/FluentNHibernate/Conventions/Inspections/Polymorphism.cs +++ b/src/FluentNHibernate/Conventions/Inspections/Polymorphism.cs @@ -8,9 +8,9 @@ public class Polymorphism : IEquatable public static readonly Polymorphism Implicit = new Polymorphism("implicit"); public static readonly Polymorphism Explicit = new Polymorphism("explicit"); - private readonly string value; + readonly string value; - private Polymorphism(string value) + Polymorphism(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/Prefix.cs b/src/FluentNHibernate/Conventions/Inspections/Prefix.cs index 35e3b917e..434ba625f 100644 --- a/src/FluentNHibernate/Conventions/Inspections/Prefix.cs +++ b/src/FluentNHibernate/Conventions/Inspections/Prefix.cs @@ -2,7 +2,7 @@ namespace FluentNHibernate.Conventions.Inspections; public class Prefix { - private readonly string value; + readonly string value; protected Prefix(string value) { diff --git a/src/FluentNHibernate/Conventions/Inspections/PropertyInspector.cs b/src/FluentNHibernate/Conventions/Inspections/PropertyInspector.cs index f53a32824..9fe51e453 100644 --- a/src/FluentNHibernate/Conventions/Inspections/PropertyInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/PropertyInspector.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class PropertyInspector : ColumnBasedInspector, IPropertyInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly PropertyMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly PropertyMapping mapping; public PropertyInspector(PropertyMapping mapping) : base(mapping.Columns) diff --git a/src/FluentNHibernate/Conventions/Inspections/SchemaAction.cs b/src/FluentNHibernate/Conventions/Inspections/SchemaAction.cs index 97f3582d0..3f84f789f 100644 --- a/src/FluentNHibernate/Conventions/Inspections/SchemaAction.cs +++ b/src/FluentNHibernate/Conventions/Inspections/SchemaAction.cs @@ -11,10 +11,10 @@ public class SchemaAction : IEquatable public static readonly SchemaAction Update = new SchemaAction("update"); public static readonly SchemaAction Validate = new SchemaAction("validate"); public static readonly SchemaAction All = new SchemaAction("all"); - - private readonly string value; - private SchemaAction(string value) + readonly string value; + + SchemaAction(string value) { this.value = value; } diff --git a/src/FluentNHibernate/Conventions/Inspections/SubclassInspector.cs b/src/FluentNHibernate/Conventions/Inspections/SubclassInspector.cs index b01e4b9bb..fefe490f0 100644 --- a/src/FluentNHibernate/Conventions/Inspections/SubclassInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/SubclassInspector.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class SubclassInspector : ISubclassInspector { - private readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); - private readonly SubclassMapping mapping; + readonly InspectorModelMapper mappedProperties = new InspectorModelMapper(); + readonly SubclassMapping mapping; public SubclassInspector(SubclassMapping mapping) { diff --git a/src/FluentNHibernate/Conventions/Inspections/VersionInspector.cs b/src/FluentNHibernate/Conventions/Inspections/VersionInspector.cs index 666d8d88f..d4215b43c 100644 --- a/src/FluentNHibernate/Conventions/Inspections/VersionInspector.cs +++ b/src/FluentNHibernate/Conventions/Inspections/VersionInspector.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Inspections; public class VersionInspector : ColumnBasedInspector, IVersionInspector { - private readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); - private readonly VersionMapping mapping; + readonly InspectorModelMapper propertyMappings = new InspectorModelMapper(); + readonly VersionMapping mapping; public VersionInspector(VersionMapping mapping) : base(mapping.Columns) diff --git a/src/FluentNHibernate/Conventions/Instances/AnyInstance.cs b/src/FluentNHibernate/Conventions/Instances/AnyInstance.cs index 866ec2be0..23851f16d 100644 --- a/src/FluentNHibernate/Conventions/Instances/AnyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/AnyInstance.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Conventions.Instances; public class AnyInstance(AnyMapping mapping) : AnyInspector(mapping), IAnyInstance { - private readonly AnyMapping mapping = mapping; + readonly AnyMapping mapping = mapping; public new IAccessInstance Access { diff --git a/src/FluentNHibernate/Conventions/Instances/ClassInstance.cs b/src/FluentNHibernate/Conventions/Instances/ClassInstance.cs index 83b0b43d9..5043a8d11 100644 --- a/src/FluentNHibernate/Conventions/Instances/ClassInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ClassInstance.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Instances; public class ClassInstance(ClassMapping mapping) : ClassInspector(mapping), IClassInstance { - private readonly ClassMapping mapping = mapping; - private bool nextBool = true; + readonly ClassMapping mapping = mapping; + bool nextBool = true; [DebuggerBrowsable(DebuggerBrowsableState.Never)] public IClassInstance Not diff --git a/src/FluentNHibernate/Conventions/Instances/CollectionCascadeInstance.cs b/src/FluentNHibernate/Conventions/Instances/CollectionCascadeInstance.cs index 63f460086..73e37a43a 100644 --- a/src/FluentNHibernate/Conventions/Instances/CollectionCascadeInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/CollectionCascadeInstance.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.Conventions.Instances; public class CollectionCascadeInstance(Action setter) : CascadeInstance(setter), ICollectionCascadeInstance { - private readonly Action setter = setter; + readonly Action setter = setter; public void AllDeleteOrphan() { diff --git a/src/FluentNHibernate/Conventions/Instances/ColumnInstance.cs b/src/FluentNHibernate/Conventions/Instances/ColumnInstance.cs index 6ca9b46a0..1a150275c 100644 --- a/src/FluentNHibernate/Conventions/Instances/ColumnInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ColumnInstance.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Instances; public class ColumnInstance(Type parentType, ColumnMapping mapping) : ColumnInspector(parentType, mapping), IColumnInstance { - private readonly ColumnMapping mapping = mapping; + readonly ColumnMapping mapping = mapping; public new void Length(int length) { diff --git a/src/FluentNHibernate/Conventions/Instances/ComponentInstance.cs b/src/FluentNHibernate/Conventions/Instances/ComponentInstance.cs index 9feecec0e..d80e830ed 100644 --- a/src/FluentNHibernate/Conventions/Instances/ComponentInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ComponentInstance.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Conventions.Instances; public class ComponentInstance(ComponentMapping mapping) : ComponentInspector(mapping), IComponentInstance { - private bool nextBool = true; + bool nextBool = true; [DebuggerBrowsable(DebuggerBrowsableState.Never)] public IComponentInstance Not diff --git a/src/FluentNHibernate/Conventions/Instances/CompositeIdentityInstance.cs b/src/FluentNHibernate/Conventions/Instances/CompositeIdentityInstance.cs index cfb5db72d..97ddff9d8 100644 --- a/src/FluentNHibernate/Conventions/Instances/CompositeIdentityInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/CompositeIdentityInstance.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Instances; public class CompositeIdentityInstance(CompositeIdMapping mapping) : CompositeIdentityInspector(mapping), ICompositeIdentityInstance { - private readonly CompositeIdMapping mapping = mapping; - private bool nextBool = true; + readonly CompositeIdMapping mapping = mapping; + bool nextBool = true; public new void UnsavedValue(string unsavedValue) diff --git a/src/FluentNHibernate/Conventions/Instances/DynamicComponentInstance.cs b/src/FluentNHibernate/Conventions/Instances/DynamicComponentInstance.cs index c237d7885..aa10ca423 100644 --- a/src/FluentNHibernate/Conventions/Instances/DynamicComponentInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/DynamicComponentInstance.cs @@ -10,7 +10,7 @@ namespace FluentNHibernate.Conventions.Instances; public class DynamicComponentInstance(ComponentMapping mapping) : DynamicComponentInspector(mapping), IDynamicComponentInstance { - private bool nextBool = true; + bool nextBool = true; [DebuggerBrowsable(DebuggerBrowsableState.Never)] public IDynamicComponentInstance Not diff --git a/src/FluentNHibernate/Conventions/Instances/ElementInstance.cs b/src/FluentNHibernate/Conventions/Instances/ElementInstance.cs index abf0638ce..ee0ec4f8c 100644 --- a/src/FluentNHibernate/Conventions/Instances/ElementInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ElementInstance.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Conventions.Instances; public class ElementInstance(ElementMapping mapping) : ElementInspector(mapping), IElementInstance { - private readonly ElementMapping mapping = mapping; + readonly ElementMapping mapping = mapping; public void Column(string columnName) { diff --git a/src/FluentNHibernate/Conventions/Instances/GeneratorInstance.cs b/src/FluentNHibernate/Conventions/Instances/GeneratorInstance.cs index 990f89270..eeff85622 100644 --- a/src/FluentNHibernate/Conventions/Instances/GeneratorInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/GeneratorInstance.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Conventions.Instances; public class GeneratorInstance(GeneratorMapping mapping, Type type) : GeneratorInspector(mapping), IGeneratorInstance { - private readonly GeneratorBuilder builder = new(mapping, type, Layer.Conventions); + readonly GeneratorBuilder builder = new(mapping, type, Layer.Conventions); /// /// generates identifiers of any integral type that are unique only when no other diff --git a/src/FluentNHibernate/Conventions/Instances/HibernateMappingInstance.cs b/src/FluentNHibernate/Conventions/Instances/HibernateMappingInstance.cs index 213e05040..99283c5d2 100644 --- a/src/FluentNHibernate/Conventions/Instances/HibernateMappingInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/HibernateMappingInstance.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Conventions.Instances; public class HibernateMappingInstance(HibernateMapping mapping) : HibernateMappingInspector(mapping), IHibernateMappingInstance { - private readonly HibernateMapping mapping = mapping; - private bool nextBool = true; + readonly HibernateMapping mapping = mapping; + bool nextBool = true; public new void Catalog(string catalog) { diff --git a/src/FluentNHibernate/Conventions/Instances/IdentityInstance.cs b/src/FluentNHibernate/Conventions/Instances/IdentityInstance.cs index b1713096d..3d5464feb 100644 --- a/src/FluentNHibernate/Conventions/Instances/IdentityInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/IdentityInstance.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Instances; public class IdentityInstance(IdMapping mapping) : IdentityInspector(mapping), IIdentityInstance { - private readonly IdMapping mapping = mapping; - private bool nextBool = true; + readonly IdMapping mapping = mapping; + bool nextBool = true; public void Column(string columnName) { diff --git a/src/FluentNHibernate/Conventions/Instances/IndexInstance.cs b/src/FluentNHibernate/Conventions/Instances/IndexInstance.cs index 49d901381..de47610fb 100644 --- a/src/FluentNHibernate/Conventions/Instances/IndexInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/IndexInstance.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Instances; public class IndexInstance(IndexMapping mapping) : IndexInspector(mapping), IIndexInstance { - private readonly IndexMapping mapping = mapping; + readonly IndexMapping mapping = mapping; /// /// Adds a column to the index if columns have not yet been specified diff --git a/src/FluentNHibernate/Conventions/Instances/IndexManyToManyInstance.cs b/src/FluentNHibernate/Conventions/Instances/IndexManyToManyInstance.cs index 9b5af2242..e4d077106 100644 --- a/src/FluentNHibernate/Conventions/Instances/IndexManyToManyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/IndexManyToManyInstance.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Conventions.Instances; public class IndexManyToManyInstance(IndexManyToManyMapping mapping) : IndexManyToManyInspector(mapping), IIndexManyToManyInstance { - private readonly IndexManyToManyMapping mapping = mapping; + readonly IndexManyToManyMapping mapping = mapping; /// /// Adds a column to the index if columns have not yet been specified diff --git a/src/FluentNHibernate/Conventions/Instances/JoinedSubclassInstance.cs b/src/FluentNHibernate/Conventions/Instances/JoinedSubclassInstance.cs index 95abf2e19..bb255ee22 100644 --- a/src/FluentNHibernate/Conventions/Instances/JoinedSubclassInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/JoinedSubclassInstance.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Instances; public class JoinedSubclassInstance(SubclassMapping mapping) : JoinedSubclassInspector(mapping), IJoinedSubclassInstance { - private readonly SubclassMapping mapping = mapping; - private bool nextBool = true; + readonly SubclassMapping mapping = mapping; + bool nextBool = true; public new IKeyInstance Key { diff --git a/src/FluentNHibernate/Conventions/Instances/KeyInstance.cs b/src/FluentNHibernate/Conventions/Instances/KeyInstance.cs index a676bdd6d..7d3305601 100644 --- a/src/FluentNHibernate/Conventions/Instances/KeyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/KeyInstance.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Instances; public class KeyInstance(KeyMapping mapping) : KeyInspector(mapping), IKeyInstance { - private readonly KeyMapping mapping = mapping; + readonly KeyMapping mapping = mapping; public void Column(string columnName) { diff --git a/src/FluentNHibernate/Conventions/Instances/KeyManyToOneInstance.cs b/src/FluentNHibernate/Conventions/Instances/KeyManyToOneInstance.cs index 81a84826f..a88357cc0 100644 --- a/src/FluentNHibernate/Conventions/Instances/KeyManyToOneInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/KeyManyToOneInstance.cs @@ -6,8 +6,8 @@ namespace FluentNHibernate.Conventions.Instances; public class KeyManyToOneInstance(KeyManyToOneMapping mapping) : KeyManyToOneInspector(mapping), IKeyManyToOneInstance { - private readonly KeyManyToOneMapping mapping = mapping; - private bool nextBool = true; + readonly KeyManyToOneMapping mapping = mapping; + bool nextBool = true; public new IAccessInstance Access { diff --git a/src/FluentNHibernate/Conventions/Instances/KeyPropertyInstance.cs b/src/FluentNHibernate/Conventions/Instances/KeyPropertyInstance.cs index 5002e8fcf..32e78686c 100644 --- a/src/FluentNHibernate/Conventions/Instances/KeyPropertyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/KeyPropertyInstance.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Conventions.Instances; public class KeyPropertyInstance(KeyPropertyMapping mapping) : KeyPropertyInspector(mapping), IKeyPropertyInstance { - private readonly KeyPropertyMapping mapping = mapping; + readonly KeyPropertyMapping mapping = mapping; public new IAccessInstance Access { diff --git a/src/FluentNHibernate/Conventions/Instances/ManyToManyCollectionInstance.cs b/src/FluentNHibernate/Conventions/Instances/ManyToManyCollectionInstance.cs index 4263136c9..3ce0fe341 100644 --- a/src/FluentNHibernate/Conventions/Instances/ManyToManyCollectionInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ManyToManyCollectionInstance.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Instances; public class ManyToManyCollectionInstance : CollectionInstance, IManyToManyCollectionInstance { - private readonly CollectionMapping mapping; + readonly CollectionMapping mapping; public ManyToManyCollectionInstance(CollectionMapping mapping) : base(mapping) diff --git a/src/FluentNHibernate/Conventions/Instances/ManyToManyInstance.cs b/src/FluentNHibernate/Conventions/Instances/ManyToManyInstance.cs index 4f4a3bc1d..d5e1752e9 100644 --- a/src/FluentNHibernate/Conventions/Instances/ManyToManyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ManyToManyInstance.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.Conventions.Instances; public class ManyToManyInstance(ManyToManyMapping mapping) : ManyToManyInspector(mapping), IManyToManyInstance { - private readonly ManyToManyMapping mapping = mapping; + readonly ManyToManyMapping mapping = mapping; public void Column(string columnName) { diff --git a/src/FluentNHibernate/Conventions/Instances/ManyToOneInstance.cs b/src/FluentNHibernate/Conventions/Instances/ManyToOneInstance.cs index 149287f1d..ec1929ff7 100644 --- a/src/FluentNHibernate/Conventions/Instances/ManyToOneInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/ManyToOneInstance.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Instances; public class ManyToOneInstance(ManyToOneMapping mapping) : ManyToOneInspector(mapping), IManyToOneInstance { - private readonly ManyToOneMapping mapping = mapping; - private bool nextBool = true; + readonly ManyToOneMapping mapping = mapping; + bool nextBool = true; public void Column(string columnName) { diff --git a/src/FluentNHibernate/Conventions/Instances/OneToManyCollectionInstance.cs b/src/FluentNHibernate/Conventions/Instances/OneToManyCollectionInstance.cs index fafa8dbaf..ef556624d 100644 --- a/src/FluentNHibernate/Conventions/Instances/OneToManyCollectionInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/OneToManyCollectionInstance.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Instances; public class OneToManyCollectionInstance : CollectionInstance, IOneToManyCollectionInstance { - private readonly CollectionMapping mapping; + readonly CollectionMapping mapping; public OneToManyCollectionInstance(CollectionMapping mapping) : base(mapping) diff --git a/src/FluentNHibernate/Conventions/Instances/OneToManyInstance.cs b/src/FluentNHibernate/Conventions/Instances/OneToManyInstance.cs index ff4003057..f52febede 100644 --- a/src/FluentNHibernate/Conventions/Instances/OneToManyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/OneToManyInstance.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Conventions.Instances; public class OneToManyInstance(OneToManyMapping mapping) : OneToManyInspector(mapping), IOneToManyInstance { - private readonly OneToManyMapping mapping = mapping; + readonly OneToManyMapping mapping = mapping; public new INotFoundInstance NotFound { diff --git a/src/FluentNHibernate/Conventions/Instances/OneToOneInstance.cs b/src/FluentNHibernate/Conventions/Instances/OneToOneInstance.cs index 41ab3cf53..1f801a407 100644 --- a/src/FluentNHibernate/Conventions/Instances/OneToOneInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/OneToOneInstance.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Instances; public class OneToOneInstance(OneToOneMapping mapping) : OneToOneInspector(mapping), IOneToOneInstance { - private readonly OneToOneMapping mapping = mapping; - private bool nextBool = true; + readonly OneToOneMapping mapping = mapping; + bool nextBool = true; public new IAccessInstance Access { diff --git a/src/FluentNHibernate/Conventions/Instances/PropertyInstance.cs b/src/FluentNHibernate/Conventions/Instances/PropertyInstance.cs index b4c167f5d..518d98240 100644 --- a/src/FluentNHibernate/Conventions/Instances/PropertyInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/PropertyInstance.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Conventions.Instances; public class PropertyInstance(PropertyMapping mapping) : PropertyInspector(mapping), IPropertyInstance { - private readonly PropertyMapping mapping = mapping; - private bool nextBool = true; + readonly PropertyMapping mapping = mapping; + bool nextBool = true; const int layer = Layer.Conventions; /// @@ -192,7 +192,7 @@ public void Column(string columnName) column.Set(x => x.Check, layer, constraint); } - private void AddColumnsForCompositeUserType(string columnPrefix) + void AddColumnsForCompositeUserType(string columnPrefix) { var inst = (ICompositeUserType)Activator.CreateInstance(mapping.Type.GetUnderlyingSystemType()); diff --git a/src/FluentNHibernate/Conventions/Instances/SubclassInstance.cs b/src/FluentNHibernate/Conventions/Instances/SubclassInstance.cs index 615f26166..5c71e2c3d 100644 --- a/src/FluentNHibernate/Conventions/Instances/SubclassInstance.cs +++ b/src/FluentNHibernate/Conventions/Instances/SubclassInstance.cs @@ -8,8 +8,8 @@ namespace FluentNHibernate.Conventions.Instances; public class SubclassInstance(SubclassMapping mapping) : SubclassInspector(mapping), ISubclassInstance { - private readonly SubclassMapping mapping = mapping; - private bool nextBool = true; + readonly SubclassMapping mapping = mapping; + bool nextBool = true; [DebuggerBrowsable(DebuggerBrowsableState.Never)] public ISubclassInstance Not diff --git a/src/FluentNHibernate/Conventions/ProxyConvention.cs b/src/FluentNHibernate/Conventions/ProxyConvention.cs index 04c74c350..5e7a1504b 100644 --- a/src/FluentNHibernate/Conventions/ProxyConvention.cs +++ b/src/FluentNHibernate/Conventions/ProxyConvention.cs @@ -77,14 +77,14 @@ public void Apply(IOneToOneInstance instance) } } - private Type GetProxyType(Type persistentType) + Type GetProxyType(Type persistentType) { return !persistentType.IsAbstract ? mapPersistentTypeToProxyInterfaceType(persistentType) : null; } - private Type GetPersistentType(Type proxyType) + Type GetPersistentType(Type proxyType) { return proxyType.IsInterface ? mapProxyInterfaceTypeToPersistentType(proxyType) diff --git a/src/FluentNHibernate/Driver/MsSQLiteDriver.cs b/src/FluentNHibernate/Driver/MsSQLiteDriver.cs index d1d297c05..2af0b0cfe 100644 --- a/src/FluentNHibernate/Driver/MsSQLiteDriver.cs +++ b/src/FluentNHibernate/Driver/MsSQLiteDriver.cs @@ -45,7 +45,7 @@ public override DbConnection CreateConnection() return connection; } - private static void Connection_StateChange(object sender, StateChangeEventArgs e) + static void Connection_StateChange(object sender, StateChangeEventArgs e) { if ((e.OriginalState == ConnectionState.Broken || e.OriginalState == ConnectionState.Closed || e.OriginalState == ConnectionState.Connecting) && e.CurrentState == ConnectionState.Open) diff --git a/src/FluentNHibernate/Infrastructure/Container.cs b/src/FluentNHibernate/Infrastructure/Container.cs index e6cea968d..bbed4f58b 100644 --- a/src/FluentNHibernate/Infrastructure/Container.cs +++ b/src/FluentNHibernate/Infrastructure/Container.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Infrastructure; public class Container { - private readonly IDictionary> registeredTypes = new Dictionary>(); + readonly IDictionary> registeredTypes = new Dictionary>(); public void Register(Func instantiateFunc) { diff --git a/src/FluentNHibernate/Infrastructure/NetStandardSerialization.cs b/src/FluentNHibernate/Infrastructure/NetStandardSerialization.cs index 3545ad1d9..6e371e785 100644 --- a/src/FluentNHibernate/Infrastructure/NetStandardSerialization.cs +++ b/src/FluentNHibernate/Infrastructure/NetStandardSerialization.cs @@ -35,9 +35,9 @@ public object SetObjectData( [Serializable] internal sealed class TypeReference : IObjectReference { - private readonly string AssemblyName; + readonly string AssemblyName; - private readonly string FullName; + readonly string FullName; public TypeReference(Type type) { @@ -72,16 +72,16 @@ public object SetObjectData( public bool Handles(Type type, StreamingContext context) => typeof(MemberInfo).IsAssignableFrom(type); [Serializable] - private sealed class MemberInfoReference : IObjectReference + sealed class MemberInfoReference : IObjectReference { - private readonly Type DeclaringType = null; - private readonly string Name = null; - private readonly MemberTypes MemberType = default(MemberTypes); - private readonly BindingFlags BindingAttr = default(BindingFlags); - private readonly Type[] GenericParameters = null; - private readonly Type[] Parameters = null; - - private static BindingFlags GetBindingAttr(MemberInfo member) + readonly Type DeclaringType = null; + readonly string Name = null; + readonly MemberTypes MemberType = default(MemberTypes); + readonly BindingFlags BindingAttr = default(BindingFlags); + readonly Type[] GenericParameters = null; + readonly Type[] Parameters = null; + + static BindingFlags GetBindingAttr(MemberInfo member) { if (member is null) throw new ArgumentNullException(nameof(member)); var bindingFlags = default(BindingFlags); @@ -120,7 +120,7 @@ public static void GetObjectData(MemberInfo member, SerializationInfo info, Stre } } - private bool MatchMethodSignature(MethodBase method) + bool MatchMethodSignature(MethodBase method) { Debug.Assert(method.Name == Name); var gpa = method.GetGenericArguments(); @@ -171,8 +171,8 @@ public object GetRealObject(StreamingContext context) [Obsolete("This API supports obsolete formatter-based serialization and will be removed in a future version")] public sealed class SurrogateSelector : ISurrogateSelector { - private readonly ISurrogateProvider _typeSerializationProvider = new TypeSerializationSurrogate(); - private readonly ISurrogateProvider _memberInfoSerializationProvider = new MemberInfoSerializationSurrogate(); + readonly ISurrogateProvider _typeSerializationProvider = new TypeSerializationSurrogate(); + readonly ISurrogateProvider _memberInfoSerializationProvider = new MemberInfoSerializationSurrogate(); void ISurrogateSelector.ChainSelector(ISurrogateSelector selector) => throw new NotImplementedException(); diff --git a/src/FluentNHibernate/Mapping/Access.cs b/src/FluentNHibernate/Mapping/Access.cs index 178edc412..0e1c37338 100644 --- a/src/FluentNHibernate/Mapping/Access.cs +++ b/src/FluentNHibernate/Mapping/Access.cs @@ -83,14 +83,14 @@ public static Access Using() return Using(typeof(T)); } - private readonly string value; + readonly string value; - private Access(string value) + Access(string value) { this.value = value; } - private Access(string value, NamingStrategy strategy) + Access(string value, NamingStrategy strategy) { this.value = value + "." + strategy; } diff --git a/src/FluentNHibernate/Mapping/BaseAccessStrategyBuilder.cs b/src/FluentNHibernate/Mapping/BaseAccessStrategyBuilder.cs index 4d613296e..fca1034bf 100644 --- a/src/FluentNHibernate/Mapping/BaseAccessStrategyBuilder.cs +++ b/src/FluentNHibernate/Mapping/BaseAccessStrategyBuilder.cs @@ -7,11 +7,11 @@ namespace FluentNHibernate.Mapping; /// public class AccessStrategyBuilder { - private const string InvalidPrefixCamelCaseFieldM = "m is not a valid prefix for a CamelCase Field."; - private const string InvalidPrefixCamelCaseFieldMUnderscore = "m_ is not a valid prefix for a CamelCase Field."; - private const string InvalidPrefixLowerCaseFieldM = "m is not a valid prefix for a LowerCase Field."; - private const string InvalidPrefixLowerCaseFieldMUnderscore = "m_ is not a valid prefix for a LowerCase Field."; - private const string InvalidPrefixPascalCaseFieldNone = "None is not a valid prefix for a PascalCase Field."; + const string InvalidPrefixCamelCaseFieldM = "m is not a valid prefix for a CamelCase Field."; + const string InvalidPrefixCamelCaseFieldMUnderscore = "m_ is not a valid prefix for a CamelCase Field."; + const string InvalidPrefixLowerCaseFieldM = "m is not a valid prefix for a LowerCase Field."; + const string InvalidPrefixLowerCaseFieldMUnderscore = "m_ is not a valid prefix for a LowerCase Field."; + const string InvalidPrefixPascalCaseFieldNone = "None is not a valid prefix for a PascalCase Field."; internal Action setValue; diff --git a/src/FluentNHibernate/Mapping/ClassMap.cs b/src/FluentNHibernate/Mapping/ClassMap.cs index bce9f884d..a662c1cdc 100644 --- a/src/FluentNHibernate/Mapping/ClassMap.cs +++ b/src/FluentNHibernate/Mapping/ClassMap.cs @@ -453,7 +453,7 @@ public void Persister() where TPersister : IEntityPersister /// Specifies a persister to be used with this entity /// /// Persister type - private void Persister(Type type) + void Persister(Type type) { Persister(type.AssemblyQualifiedName); } diff --git a/src/FluentNHibernate/Mapping/ClasslikeMapBase.cs b/src/FluentNHibernate/Mapping/ClasslikeMapBase.cs index 8bda127d2..4f9b87065 100644 --- a/src/FluentNHibernate/Mapping/ClasslikeMapBase.cs +++ b/src/FluentNHibernate/Mapping/ClasslikeMapBase.cs @@ -307,7 +307,7 @@ public void Component(IComponentMappingProvider componentProvider) providers.Components.Add(componentProvider); } - private OneToManyPart MapHasMany(Expression> expression) + OneToManyPart MapHasMany(Expression> expression) { return HasMany(expression.ToMember()); } @@ -354,7 +354,7 @@ public OneToManyPart HasMany(Expression> memberE return MapHasMany(memberExpression); } - private ManyToManyPart MapHasManyToMany(Expression> expression) + ManyToManyPart MapHasManyToMany(Expression> expression) { return HasManyToMany(expression.ToMember()); } diff --git a/src/FluentNHibernate/Mapping/ColumnMappingCollection.cs b/src/FluentNHibernate/Mapping/ColumnMappingCollection.cs index c92034dea..85a2e0848 100644 --- a/src/FluentNHibernate/Mapping/ColumnMappingCollection.cs +++ b/src/FluentNHibernate/Mapping/ColumnMappingCollection.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.Mapping; public class ColumnMappingCollection(TParent parent) : IEnumerable { - private readonly IList columns = new List(); + readonly IList columns = new List(); public TParent Add(string name) { diff --git a/src/FluentNHibernate/Mapping/ColumnPart.cs b/src/FluentNHibernate/Mapping/ColumnPart.cs index 29726d916..7323ad511 100644 --- a/src/FluentNHibernate/Mapping/ColumnPart.cs +++ b/src/FluentNHibernate/Mapping/ColumnPart.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Mapping; public class ColumnPart(ColumnMapping columnMapping) { - private bool nextBool = true; + bool nextBool = true; /// /// Inverts the next boolean diff --git a/src/FluentNHibernate/Mapping/ComponentPart.cs b/src/FluentNHibernate/Mapping/ComponentPart.cs index ca38efc40..ba95ab242 100644 --- a/src/FluentNHibernate/Mapping/ComponentPart.cs +++ b/src/FluentNHibernate/Mapping/ComponentPart.cs @@ -7,15 +7,15 @@ namespace FluentNHibernate.Mapping; public class ComponentPart : ComponentPartBase>, IComponentMappingProvider { - private readonly Type entity; - private readonly AttributeStore attributes; - private string columnPrefix; + readonly Type entity; + readonly AttributeStore attributes; + string columnPrefix; public ComponentPart(Type entity, Member property) : this(entity, property, new AttributeStore()) {} - private ComponentPart(Type entity, Member property, AttributeStore attributes) + ComponentPart(Type entity, Member property, AttributeStore attributes) : base(attributes, property) { this.attributes = attributes; diff --git a/src/FluentNHibernate/Mapping/DiscriminatorValue.cs b/src/FluentNHibernate/Mapping/DiscriminatorValue.cs index 160afa775..0a7b79c83 100644 --- a/src/FluentNHibernate/Mapping/DiscriminatorValue.cs +++ b/src/FluentNHibernate/Mapping/DiscriminatorValue.cs @@ -15,9 +15,9 @@ public class DiscriminatorValue /// public static readonly DiscriminatorValue NotNull = new DiscriminatorValue("not null"); - private readonly string outputValue; + readonly string outputValue; - private DiscriminatorValue(string outputValue) + DiscriminatorValue(string outputValue) { this.outputValue = outputValue; } diff --git a/src/FluentNHibernate/Mapping/FilterDefinition.cs b/src/FluentNHibernate/Mapping/FilterDefinition.cs index 8b940c46e..d0fd3a180 100644 --- a/src/FluentNHibernate/Mapping/FilterDefinition.cs +++ b/src/FluentNHibernate/Mapping/FilterDefinition.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Mapping; public abstract class FilterDefinition : IFilterDefinition { - private string filterCondition; - private readonly IDictionary parameters = new Dictionary(); + string filterCondition; + readonly IDictionary parameters = new Dictionary(); public string Name { get; private set; } diff --git a/src/FluentNHibernate/Mapping/GeneratorBuilder.cs b/src/FluentNHibernate/Mapping/GeneratorBuilder.cs index ac2b9bd74..c2cd7bf3a 100644 --- a/src/FluentNHibernate/Mapping/GeneratorBuilder.cs +++ b/src/FluentNHibernate/Mapping/GeneratorBuilder.cs @@ -4,34 +4,34 @@ namespace FluentNHibernate.Mapping; -internal class GeneratorBuilder(GeneratorMapping mapping, Type identityType, int layer) +class GeneratorBuilder(GeneratorMapping mapping, Type identityType, int layer) { - private void SetGenerator(string generator) + void SetGenerator(string generator) { mapping.Set(x => x.Class, layer, generator); } - private void AddGeneratorParam(string name, string value) + void AddGeneratorParam(string name, string value) { mapping.Params.Add(name, value); } - private void EnsureIntegralIdenityType() + void EnsureIntegralIdenityType() { if (!IsIntegralType(identityType)) throw new InvalidOperationException("Identity type must be integral (int, long, uint, ulong)"); } - private void EnsureGuidIdentityType() + void EnsureGuidIdentityType() { if (identityType != typeof(Guid) && identityType != typeof(Guid?)) throw new InvalidOperationException("Identity type must be Guid"); } - private void EnsureStringIdentityType() + void EnsureStringIdentityType() { if (identityType != typeof(string)) throw new InvalidOperationException("Identity type must be string"); } - private static bool IsIntegralType(Type t) + static bool IsIntegralType(Type t) { // do we think we'll encounter more? return t == typeof(int) || t == typeof(int?) diff --git a/src/FluentNHibernate/Mapping/IdentityGenerationStrategyBuilder.cs b/src/FluentNHibernate/Mapping/IdentityGenerationStrategyBuilder.cs index 6475c31ee..6a7c4ee65 100644 --- a/src/FluentNHibernate/Mapping/IdentityGenerationStrategyBuilder.cs +++ b/src/FluentNHibernate/Mapping/IdentityGenerationStrategyBuilder.cs @@ -7,10 +7,10 @@ namespace FluentNHibernate.Mapping; public class IdentityGenerationStrategyBuilder { - private readonly TParent parent; - private readonly Type entity; - private readonly GeneratorMapping mapping = new GeneratorMapping(); - private readonly GeneratorBuilder builder; + readonly TParent parent; + readonly Type entity; + readonly GeneratorMapping mapping = new GeneratorMapping(); + readonly GeneratorBuilder builder; public IdentityGenerationStrategyBuilder(TParent parent, Type identityType, Type entity) { diff --git a/src/FluentNHibernate/Mapping/KeyManyToOnePart.cs b/src/FluentNHibernate/Mapping/KeyManyToOnePart.cs index 63eb206af..0917a9b08 100644 --- a/src/FluentNHibernate/Mapping/KeyManyToOnePart.cs +++ b/src/FluentNHibernate/Mapping/KeyManyToOnePart.cs @@ -7,8 +7,8 @@ namespace FluentNHibernate.Mapping; public class KeyManyToOnePart { - private readonly KeyManyToOneMapping mapping; - private bool nextBool = true; + readonly KeyManyToOneMapping mapping; + bool nextBool = true; public KeyManyToOnePart(KeyManyToOneMapping mapping) { diff --git a/src/FluentNHibernate/Mapping/KeyPropertyPart.cs b/src/FluentNHibernate/Mapping/KeyPropertyPart.cs index 72fb2c1ce..2a9a54c3e 100644 --- a/src/FluentNHibernate/Mapping/KeyPropertyPart.cs +++ b/src/FluentNHibernate/Mapping/KeyPropertyPart.cs @@ -5,7 +5,7 @@ namespace FluentNHibernate.Mapping; public class KeyPropertyPart { - private readonly KeyPropertyMapping mapping; + readonly KeyPropertyMapping mapping; public KeyPropertyPart(KeyPropertyMapping mapping) { diff --git a/src/FluentNHibernate/Mapping/ManyToManyPart.cs b/src/FluentNHibernate/Mapping/ManyToManyPart.cs index 9782b8efd..e67b9940a 100644 --- a/src/FluentNHibernate/Mapping/ManyToManyPart.cs +++ b/src/FluentNHibernate/Mapping/ManyToManyPart.cs @@ -11,12 +11,12 @@ namespace FluentNHibernate.Mapping; public class ManyToManyPart : ToManyBase, TChild> { - private readonly IList childFilters = new List(); - private IndexManyToManyPart manyToManyIndex; - private IndexPart index; - private readonly Type childType; - private Type valueType; - private bool isTernary; + readonly IList childFilters = new List(); + IndexManyToManyPart manyToManyIndex; + IndexPart index; + readonly Type childType; + Type valueType; + bool isTernary; public ManyToManyPart(Type entity, Member property) : this(entity, property, property.PropertyType) @@ -74,13 +74,13 @@ public ManyToManyPart ChildPropertyRef(string childPropertyRef) public FetchTypeExpression> FetchType { get; } - private void EnsureDictionary() + void EnsureDictionary() { if (!typeof(IDictionary).IsAssignableFrom(childType)) throw new ArgumentException(member.Name + " must be of type IDictionary to be used in a non-generic ternary association. Type was: " + childType); } - private void EnsureGenericDictionary() + void EnsureGenericDictionary() { if (!(childType.IsGenericType && childType.GetGenericTypeDefinition() == typeof(IDictionary<,>))) throw new ArgumentException(member.Name + " must be of type IDictionary<> to be used in a ternary assocation. Type was: " + childType); diff --git a/src/FluentNHibernate/Mapping/Member.cs b/src/FluentNHibernate/Mapping/Member.cs index 20ed08280..3b83a9418 100644 --- a/src/FluentNHibernate/Mapping/Member.cs +++ b/src/FluentNHibernate/Mapping/Member.cs @@ -59,7 +59,7 @@ public override int GetHashCode() } [Serializable] -internal class MethodMember(MethodInfo member) : Member +class MethodMember(MethodInfo member) : Member { Member backingField; @@ -137,7 +137,7 @@ public override string ToString() } [Serializable] -internal class FieldMember(FieldInfo member) : Member +class FieldMember(FieldInfo member) : Member { public override void SetValue(object target, object value) { @@ -190,7 +190,7 @@ public override string ToString() } [Serializable] -internal class PropertyMember : Member +class PropertyMember : Member { readonly PropertyInfo member; Member backingField; diff --git a/src/FluentNHibernate/Mapping/OneToManyPart.cs b/src/FluentNHibernate/Mapping/OneToManyPart.cs index d8abf2a73..2dd99376a 100644 --- a/src/FluentNHibernate/Mapping/OneToManyPart.cs +++ b/src/FluentNHibernate/Mapping/OneToManyPart.cs @@ -10,11 +10,11 @@ namespace FluentNHibernate.Mapping; public class OneToManyPart : ToManyBase, TChild> { - private readonly Type entity; - private IndexManyToManyPart manyToManyIndex; - private readonly Type childType; - private Type valueType; - private bool isTernary; + readonly Type entity; + IndexManyToManyPart manyToManyIndex; + readonly Type childType; + Type valueType; + bool isTernary; public OneToManyPart(Type entity, Member property) : this(entity, property, property.PropertyType) diff --git a/src/FluentNHibernate/Mapping/OptimisticLockBuilder.cs b/src/FluentNHibernate/Mapping/OptimisticLockBuilder.cs index 4b1b1e342..a2593b172 100644 --- a/src/FluentNHibernate/Mapping/OptimisticLockBuilder.cs +++ b/src/FluentNHibernate/Mapping/OptimisticLockBuilder.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.Mapping; public class OptimisticLockBuilder { - private readonly Action setter; + readonly Action setter; protected OptimisticLockBuilder(Action setter) { diff --git a/src/FluentNHibernate/Mapping/Prefix.cs b/src/FluentNHibernate/Mapping/Prefix.cs index edef37fda..15706f0c6 100644 --- a/src/FluentNHibernate/Mapping/Prefix.cs +++ b/src/FluentNHibernate/Mapping/Prefix.cs @@ -10,7 +10,7 @@ public class Prefix public static readonly Prefix m = new Prefix("-m"); public static readonly Prefix mUnderscore = new Prefix("-m-underscore"); - private Prefix(string value) + Prefix(string value) { this.Value = value; } diff --git a/src/FluentNHibernate/Mapping/Providers/IndeterminateSubclassMappingProviderCollection.cs b/src/FluentNHibernate/Mapping/Providers/IndeterminateSubclassMappingProviderCollection.cs index f8dcdbb59..a03b7c58d 100644 --- a/src/FluentNHibernate/Mapping/Providers/IndeterminateSubclassMappingProviderCollection.cs +++ b/src/FluentNHibernate/Mapping/Providers/IndeterminateSubclassMappingProviderCollection.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.Mapping.Providers; /// public class IndeterminateSubclassMappingProviderCollection : IIndeterminateSubclassMappingProviderCollection { - private readonly List providers = new List(); - private readonly HashSet mappedTypes = new HashSet(); + readonly List providers = new List(); + readonly HashSet mappedTypes = new HashSet(); public IEnumerator GetEnumerator() { diff --git a/src/FluentNHibernate/Mapping/SubClassPart.cs b/src/FluentNHibernate/Mapping/SubClassPart.cs index a9f0950cf..73f50789f 100644 --- a/src/FluentNHibernate/Mapping/SubClassPart.cs +++ b/src/FluentNHibernate/Mapping/SubClassPart.cs @@ -11,12 +11,12 @@ namespace FluentNHibernate.Mapping; [Obsolete("REMOVE ME")] public class SubClassPart : ClasslikeMapBase, ISubclassMappingProvider { - private readonly DiscriminatorPart parent; - private readonly object discriminatorValue; - private readonly MappingProviderStore providers; - private readonly AttributeStore attributes = new AttributeStore(); - private readonly List subclassMappings = new List(); - private bool nextBool = true; + readonly DiscriminatorPart parent; + readonly object discriminatorValue; + readonly MappingProviderStore providers; + readonly AttributeStore attributes = new AttributeStore(); + readonly List subclassMappings = new List(); + bool nextBool = true; public SubClassPart(DiscriminatorPart parent, object discriminatorValue) : this(parent, discriminatorValue, new MappingProviderStore()) diff --git a/src/FluentNHibernate/MappingModel/ClassBased/ComponentMappingBase.cs b/src/FluentNHibernate/MappingModel/ClassBased/ComponentMappingBase.cs index b9b4a8c33..0adfe8a4b 100644 --- a/src/FluentNHibernate/MappingModel/ClassBased/ComponentMappingBase.cs +++ b/src/FluentNHibernate/MappingModel/ClassBased/ComponentMappingBase.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.ClassBased; [Serializable] public abstract class ComponentMappingBase(AttributeStore attributes) : ClassMappingBase(attributes) { - private readonly AttributeStore attributes = attributes; + readonly AttributeStore attributes = attributes; protected ComponentMappingBase() : this(new AttributeStore()) diff --git a/src/FluentNHibernate/MappingModel/ClassBased/ComponentType.cs b/src/FluentNHibernate/MappingModel/ClassBased/ComponentType.cs index 0d970b308..ed8585155 100644 --- a/src/FluentNHibernate/MappingModel/ClassBased/ComponentType.cs +++ b/src/FluentNHibernate/MappingModel/ClassBased/ComponentType.cs @@ -10,7 +10,7 @@ public class ComponentType : IEquatable readonly string elementName; - private ComponentType(string elementName) + ComponentType(string elementName) { this.elementName = elementName; } diff --git a/src/FluentNHibernate/MappingModel/ClassBased/ReferenceComponentMapping.cs b/src/FluentNHibernate/MappingModel/ClassBased/ReferenceComponentMapping.cs index e6d5a3056..f4b22f38c 100644 --- a/src/FluentNHibernate/MappingModel/ClassBased/ReferenceComponentMapping.cs +++ b/src/FluentNHibernate/MappingModel/ClassBased/ReferenceComponentMapping.cs @@ -14,10 +14,10 @@ public class ReferenceComponentMapping(ComponentType componentType, Member prope : IComponentMapping, IEquatable { public ComponentType ComponentType { get; set; } = componentType; - private readonly Member property = property; - private readonly Type componentType = componentEntityType; - private ExternalComponentMapping mergedComponent; - private Type containingEntityType = containingEntityType; + readonly Member property = property; + readonly Type componentType = componentEntityType; + ExternalComponentMapping mergedComponent; + Type containingEntityType = containingEntityType; public void AcceptVisitor(IMappingModelVisitor visitor) { diff --git a/src/FluentNHibernate/MappingModel/ClassBased/SubclassType.cs b/src/FluentNHibernate/MappingModel/ClassBased/SubclassType.cs index 1b37b3313..24e84d2b9 100644 --- a/src/FluentNHibernate/MappingModel/ClassBased/SubclassType.cs +++ b/src/FluentNHibernate/MappingModel/ClassBased/SubclassType.cs @@ -11,7 +11,7 @@ public class SubclassType: IEquatable readonly string elementName; - private SubclassType(string elementName) + SubclassType(string elementName) { this.elementName = elementName; } diff --git a/src/FluentNHibernate/MappingModel/Identity/CompositeIdMapping.cs b/src/FluentNHibernate/MappingModel/Identity/CompositeIdMapping.cs index 1c7327702..940bd3658 100644 --- a/src/FluentNHibernate/MappingModel/Identity/CompositeIdMapping.cs +++ b/src/FluentNHibernate/MappingModel/Identity/CompositeIdMapping.cs @@ -9,8 +9,8 @@ namespace FluentNHibernate.MappingModel.Identity; [Serializable] public class CompositeIdMapping(AttributeStore attributes) : MappingBase, IIdentityMapping, IEquatable { - private readonly AttributeStore attributes = attributes; - private readonly IList keys = new List(); + readonly AttributeStore attributes = attributes; + readonly IList keys = new List(); public CompositeIdMapping() : this(new AttributeStore()) diff --git a/src/FluentNHibernate/MappingModel/JoinMapping.cs b/src/FluentNHibernate/MappingModel/JoinMapping.cs index 4e5a64f93..bccdb1e2b 100644 --- a/src/FluentNHibernate/MappingModel/JoinMapping.cs +++ b/src/FluentNHibernate/MappingModel/JoinMapping.cs @@ -11,9 +11,9 @@ namespace FluentNHibernate.MappingModel; [Serializable] public class JoinMapping(AttributeStore attributes) : IMapping, IEquatable { - private readonly AttributeStore attributes = attributes; + readonly AttributeStore attributes = attributes; - private readonly MappedMembers mappedMembers = new(); + readonly MappedMembers mappedMembers = new(); public JoinMapping() : this(new AttributeStore()) diff --git a/src/FluentNHibernate/MappingModel/MappedMembers.cs b/src/FluentNHibernate/MappingModel/MappedMembers.cs index 8ec4b2182..3b57b368f 100644 --- a/src/FluentNHibernate/MappingModel/MappedMembers.cs +++ b/src/FluentNHibernate/MappingModel/MappedMembers.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel; [Serializable] -internal class MappedMembers : IMapping, IHasMappedMembers, IEquatable +class MappedMembers : IMapping, IHasMappedMembers, IEquatable { public enum MappingType { Property, @@ -21,7 +21,7 @@ public enum MappingType { StoredProcedure, } - private readonly List> orderedMappings = new(); + readonly List> orderedMappings = new(); public IEnumerable Properties => orderedMappings.Where(x => x.Item1 == MappingType.Property).Select(x => x.Item2).Cast(); @@ -205,11 +205,11 @@ public override int GetHashCode() { return orderedMappings.GetHashCode(); } - private void AddMapping(TMapping mapping, MappingType mappingType) where TMapping : IMapping { + void AddMapping(TMapping mapping, MappingType mappingType) where TMapping : IMapping { orderedMappings.Add(Tuple.Create(mappingType, (IMapping)mapping)); } - private void AddOrReplaceMapping(TMapping mapping, MappingType mappingType, Predicate matchPredicate) { + void AddOrReplaceMapping(TMapping mapping, MappingType mappingType, Predicate matchPredicate) { var newMapping = Tuple.Create(mappingType, (IMapping)mapping); var index = orderedMappings.FindIndex(x => x.Item1 == mappingType && matchPredicate((TMapping)x.Item2)); if (index >= 0) diff --git a/src/FluentNHibernate/MappingModel/MetaValueMapping.cs b/src/FluentNHibernate/MappingModel/MetaValueMapping.cs index 3f774d00a..a287ab9ac 100644 --- a/src/FluentNHibernate/MappingModel/MetaValueMapping.cs +++ b/src/FluentNHibernate/MappingModel/MetaValueMapping.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel; [Serializable] public class MetaValueMapping : MappingBase, IEquatable { - private readonly AttributeStore attributes; + readonly AttributeStore attributes; public MetaValueMapping() : this(new AttributeStore()) diff --git a/src/FluentNHibernate/MappingModel/NaturalIdMapping.cs b/src/FluentNHibernate/MappingModel/NaturalIdMapping.cs index 28abe09b4..28c3f663c 100644 --- a/src/FluentNHibernate/MappingModel/NaturalIdMapping.cs +++ b/src/FluentNHibernate/MappingModel/NaturalIdMapping.cs @@ -7,9 +7,9 @@ namespace FluentNHibernate.MappingModel; [Serializable] public class NaturalIdMapping(AttributeStore attributes) : MappingBase { - private readonly AttributeStore attributes = attributes; - private readonly IList properties = new List(); - private readonly IList manyToOnes = new List(); + readonly AttributeStore attributes = attributes; + readonly IList properties = new List(); + readonly IList manyToOnes = new List(); public NaturalIdMapping() : this(new AttributeStore()) { } diff --git a/src/FluentNHibernate/MappingModel/OneToOneMapping.cs b/src/FluentNHibernate/MappingModel/OneToOneMapping.cs index efc31af29..826d82e0e 100644 --- a/src/FluentNHibernate/MappingModel/OneToOneMapping.cs +++ b/src/FluentNHibernate/MappingModel/OneToOneMapping.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel; [Serializable] public class OneToOneMapping(AttributeStore attributes) : MappingBase, IEquatable { - private readonly AttributeStore attributes = attributes; + readonly AttributeStore attributes = attributes; public OneToOneMapping() : this(new AttributeStore()) diff --git a/src/FluentNHibernate/MappingModel/Output/BaseXmlComponentWriter.cs b/src/FluentNHibernate/MappingModel/Output/BaseXmlComponentWriter.cs index 286c153d6..9f86bc6f8 100644 --- a/src/FluentNHibernate/MappingModel/Output/BaseXmlComponentWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/BaseXmlComponentWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public abstract class BaseXmlComponentWriter(IXmlWriterServiceLocator serviceLocator) : XmlClassWriterBase(serviceLocator) { - private readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; + readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; protected XmlDocument WriteComponent(string element, IComponentMapping mapping) { diff --git a/src/FluentNHibernate/MappingModel/Output/MappingXmlSerializer.cs b/src/FluentNHibernate/MappingModel/Output/MappingXmlSerializer.cs index 4b91597be..e6607bcbf 100644 --- a/src/FluentNHibernate/MappingModel/Output/MappingXmlSerializer.cs +++ b/src/FluentNHibernate/MappingModel/Output/MappingXmlSerializer.cs @@ -9,7 +9,7 @@ public XmlDocument Serialize(HibernateMapping mapping) return BuildXml(mapping); } - private static XmlDocument BuildXml(HibernateMapping rootMapping) + static XmlDocument BuildXml(HibernateMapping rootMapping) { var xmlWriter = XmlWriterFactory.CreateHibernateMappingWriter(); diff --git a/src/FluentNHibernate/MappingModel/Output/Sorting/XmlClasslikeNodeSorter.cs b/src/FluentNHibernate/MappingModel/Output/Sorting/XmlClasslikeNodeSorter.cs index a42c862b4..f53feff87 100644 --- a/src/FluentNHibernate/MappingModel/Output/Sorting/XmlClasslikeNodeSorter.cs +++ b/src/FluentNHibernate/MappingModel/Output/Sorting/XmlClasslikeNodeSorter.cs @@ -66,7 +66,7 @@ protected override void SortChildren(XmlNode node) new XmlCollectionNodeSorter().Sort(node); } - private bool IsCollection(string name) + bool IsCollection(string name) { return name == "bag" || name == "set" || name == "list" || name == "map" || name == "array" || name == "primitive-array"; diff --git a/src/FluentNHibernate/MappingModel/Output/XmlAnyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlAnyWriter.cs index c121a4859..67c414946 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlAnyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlAnyWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlAnyWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(AnyMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlCacheWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlCacheWriter.cs index 03c581d60..0597d9443 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlCacheWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlCacheWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlCacheWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(CacheMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlClassWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlClassWriter.cs index 148a67973..cea79b40e 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlClassWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlClassWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlClassWriter(IXmlWriterServiceLocator serviceLocator) : XmlClassWriterBase(serviceLocator), IXmlWriter { - private readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; + readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; public XmlDocument Write(ClassMapping mapping) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlCollectionRelationshipWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlCollectionRelationshipWriter.cs index 57faede31..cf6dc350d 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlCollectionRelationshipWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlCollectionRelationshipWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlCollectionRelationshipWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ICollectionRelationshipMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlCollectionWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlCollectionWriter.cs index dd962a4db..7f469f1c9 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlCollectionWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlCollectionWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlCollectionWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; Collection collection; public XmlDocument Write(CollectionMapping mappingModel) diff --git a/src/FluentNHibernate/MappingModel/Output/XmlColumnWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlColumnWriter.cs index 80ee797cb..60e3bcfb3 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlColumnWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlColumnWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlColumnWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ColumnMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlComponentWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlComponentWriter.cs index 064b3f6ab..0d00747fc 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlComponentWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlComponentWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlReferenceComponentWriter(IXmlWriterServiceLocator serviceLocator) : BaseXmlComponentWriter(serviceLocator), IXmlWriter { - private IXmlWriter innerWriter = serviceLocator.GetWriter(); + IXmlWriter innerWriter = serviceLocator.GetWriter(); public XmlDocument Write(ReferenceComponentMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlCompositeIdWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlCompositeIdWriter.cs index 8dba3a78a..f65a9e436 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlCompositeIdWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlCompositeIdWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlCompositeIdWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(CompositeIdMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlDiscriminatorWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlDiscriminatorWriter.cs index ef7be25fd..325e43fdb 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlDiscriminatorWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlDiscriminatorWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlDiscriminatorWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(DiscriminatorMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlElementWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlElementWriter.cs index 82067fc65..06a4016b5 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlElementWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlElementWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlElementWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ElementMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlFilterDefinitionWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlFilterDefinitionWriter.cs index d067ad744..a2deffe85 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlFilterDefinitionWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlFilterDefinitionWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlFilterDefinitionWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(FilterDefinitionMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlFilterWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlFilterWriter.cs index c0ed712d2..97d79fa38 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlFilterWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlFilterWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlFilterWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(FilterMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlGeneratorWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlGeneratorWriter.cs index cc3fa72b3..ce199ad39 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlGeneratorWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlGeneratorWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlGeneratorWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(GeneratorMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlHibernateMappingWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlHibernateMappingWriter.cs index 3fa7ed940..c0f6cfc41 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlHibernateMappingWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlHibernateMappingWriter.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlHibernateMappingWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(HibernateMapping mapping) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlIIndexWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlIIndexWriter.cs index 8f5243476..ce931494f 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlIIndexWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlIIndexWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlIIndexWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(IIndexMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlIdWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlIdWriter.cs index 2daa66a84..d2326d5e0 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlIdWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlIdWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlIdWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(IdMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlIdentityBasedWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlIdentityBasedWriter.cs index e9b4422fc..d98c15fa0 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlIdentityBasedWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlIdentityBasedWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlIdentityBasedWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(IIdentityMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlImportWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlImportWriter.cs index 9d6777254..a85afe66d 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlImportWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlImportWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlImportWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ImportMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlIndexManyToManyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlIndexManyToManyWriter.cs index b2e4fbbb4..e1f690f62 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlIndexManyToManyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlIndexManyToManyWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlIndexManyToManyWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(IndexManyToManyMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlIndexWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlIndexWriter.cs index 287ba69f4..c04be11a1 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlIndexWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlIndexWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlIndexWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(IndexMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlJoinWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlJoinWriter.cs index d8f35757a..c112106df 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlJoinWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlJoinWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlJoinWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(JoinMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlKeyManyToOneWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlKeyManyToOneWriter.cs index 40f2a919c..2a0499c71 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlKeyManyToOneWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlKeyManyToOneWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlKeyManyToOneWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(KeyManyToOneMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlKeyPropertyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlKeyPropertyWriter.cs index 85d567ecc..4b8b59082 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlKeyPropertyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlKeyPropertyWriter.cs @@ -9,7 +9,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlKeyPropertyWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(KeyPropertyMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlKeyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlKeyWriter.cs index cf15fa400..cda18a7ad 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlKeyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlKeyWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlKeyWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(KeyMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlManyToManyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlManyToManyWriter.cs index 90ce78051..118798a2a 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlManyToManyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlManyToManyWriter.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlManyToManyWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ManyToManyMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlManyToOneWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlManyToOneWriter.cs index 43875981f..30d3cf49d 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlManyToOneWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlManyToOneWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlManyToOneWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ManyToOneMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlMapWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlMapWriter.cs index a2ff656c3..0c1c71eee 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlMapWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlMapWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlMapWriter(IXmlWriterServiceLocator serviceLocator) : BaseXmlCollectionWriter(serviceLocator), IXmlWriter { - private readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; + readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; public XmlDocument Write(CollectionMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlMetaValueWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlMetaValueWriter.cs index 241a669f7..e812c12a3 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlMetaValueWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlMetaValueWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlMetaValueWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(MetaValueMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlNaturalIdWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlNaturalIdWriter.cs index c10470816..4035854b4 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlNaturalIdWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlNaturalIdWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlNaturalIdWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(NaturalIdMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlOneToManyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlOneToManyWriter.cs index 76fbbe7ae..03b427afd 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlOneToManyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlOneToManyWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlOneToManyWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(OneToManyMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlOneToOneWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlOneToOneWriter.cs index 25d9bd89c..1e224a498 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlOneToOneWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlOneToOneWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlOneToOneWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(OneToOneMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlParentWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlParentWriter.cs index a8f05ee17..49608a0aa 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlParentWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlParentWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlParentWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(ParentMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlPropertyWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlPropertyWriter.cs index 31a03e12c..b79089ffc 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlPropertyWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlPropertyWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlPropertyWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(PropertyMapping property) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlStoredProcedureWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlStoredProcedureWriter.cs index 1d547e2bb..75ebc075d 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlStoredProcedureWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlStoredProcedureWriter.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlStoredProcedureWriter(IXmlWriterServiceLocator serviceLocator) : XmlClassWriterBase(serviceLocator), IXmlWriter { - private readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; + readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; public XmlDocument Write(StoredProcedureMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlSubclassWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlSubclassWriter.cs index 72e62ed34..538b65eef 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlSubclassWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlSubclassWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlSubclassWriter(IXmlWriterServiceLocator serviceLocator) : XmlClassWriterBase(serviceLocator), IXmlWriter { - private readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; + readonly IXmlWriterServiceLocator serviceLocator = serviceLocator; public XmlDocument Write(SubclassMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlTuplizerWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlTuplizerWriter.cs index 78e32c1cd..b79d92b58 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlTuplizerWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlTuplizerWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlTuplizerWriter : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(TuplizerMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlVersionWriter.cs b/src/FluentNHibernate/MappingModel/Output/XmlVersionWriter.cs index 01f138fac..74c046565 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlVersionWriter.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlVersionWriter.cs @@ -7,7 +7,7 @@ namespace FluentNHibernate.MappingModel.Output; public class XmlVersionWriter(IXmlWriterServiceLocator serviceLocator) : NullMappingModelVisitor, IXmlWriter { - private XmlDocument document; + XmlDocument document; public XmlDocument Write(VersionMapping mappingModel) { diff --git a/src/FluentNHibernate/MappingModel/Output/XmlWriterContainer.cs b/src/FluentNHibernate/MappingModel/Output/XmlWriterContainer.cs index e910485ee..a931b1624 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlWriterContainer.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlWriterContainer.cs @@ -110,7 +110,7 @@ public XmlWriterContainer() new XmlTuplizerWriter()); } - private void RegisterIdWriters() + void RegisterIdWriters() { RegisterWriter(c => new XmlIdentityBasedWriter(c.Resolve())); @@ -131,7 +131,7 @@ private void RegisterIdWriters() new XmlKeyManyToOneWriter(c.Resolve())); } - private void RegisterComponentWriters() + void RegisterComponentWriters() { RegisterWriter(c => new XmlComponentWriter(c.Resolve())); @@ -140,7 +140,7 @@ private void RegisterComponentWriters() new XmlReferenceComponentWriter(c.Resolve())); } - private void RegisterWriter(Func instantiate) + void RegisterWriter(Func instantiate) { Register>(instantiate); } diff --git a/src/FluentNHibernate/MappingModel/Output/XmlWriterFactory.cs b/src/FluentNHibernate/MappingModel/Output/XmlWriterFactory.cs index 06cfe7ce6..1d77544d0 100644 --- a/src/FluentNHibernate/MappingModel/Output/XmlWriterFactory.cs +++ b/src/FluentNHibernate/MappingModel/Output/XmlWriterFactory.cs @@ -4,7 +4,7 @@ namespace FluentNHibernate.MappingModel.Output; public static class XmlWriterFactory { - private static readonly Container Container = new XmlWriterContainer(); + static readonly Container Container = new XmlWriterContainer(); public static IXmlWriter CreateHibernateMappingWriter() { diff --git a/src/FluentNHibernate/MappingModel/ParentMapping.cs b/src/FluentNHibernate/MappingModel/ParentMapping.cs index 1d27d6751..6247e078b 100644 --- a/src/FluentNHibernate/MappingModel/ParentMapping.cs +++ b/src/FluentNHibernate/MappingModel/ParentMapping.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel; [Serializable] public class ParentMapping : MappingBase, IEquatable { - private readonly AttributeStore attributes; + readonly AttributeStore attributes; public ParentMapping() : this(new AttributeStore()) diff --git a/src/FluentNHibernate/MappingModel/StoredProcedureMapping.cs b/src/FluentNHibernate/MappingModel/StoredProcedureMapping.cs index 47e35d02d..725e9ba8b 100644 --- a/src/FluentNHibernate/MappingModel/StoredProcedureMapping.cs +++ b/src/FluentNHibernate/MappingModel/StoredProcedureMapping.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.MappingModel; [Serializable] public class StoredProcedureMapping : MappingBase, IEquatable { - private readonly AttributeStore attributes; + readonly AttributeStore attributes; public StoredProcedureMapping() : this("sql-insert", "") { diff --git a/src/FluentNHibernate/MappingModel/TypeReference.cs b/src/FluentNHibernate/MappingModel/TypeReference.cs index dde09cc77..874c32344 100644 --- a/src/FluentNHibernate/MappingModel/TypeReference.cs +++ b/src/FluentNHibernate/MappingModel/TypeReference.cs @@ -10,7 +10,7 @@ public class TypeReference: IEquatable { public static readonly TypeReference Empty = new TypeReference("nop"); - private readonly Type innerType; + readonly Type innerType; public TypeReference(string name) { diff --git a/src/FluentNHibernate/Testing/PersistenceSpecificationExtensions.cs b/src/FluentNHibernate/Testing/PersistenceSpecificationExtensions.cs index ee75478c6..14d474018 100644 --- a/src/FluentNHibernate/Testing/PersistenceSpecificationExtensions.cs +++ b/src/FluentNHibernate/Testing/PersistenceSpecificationExtensions.cs @@ -494,7 +494,7 @@ public static PersistenceSpecification CheckEnumerable(this Persist return spec.CheckList(expression, itemsToAdd, addAction); } - private class FuncEqualityComparer(IEnumerable> comparisons) : EqualityComparer + class FuncEqualityComparer(IEnumerable> comparisons) : EqualityComparer { public override bool Equals(T x, T y) { diff --git a/src/FluentNHibernate/Testing/SingleConnectionSessionSourceForSQLiteInMemoryTesting.cs b/src/FluentNHibernate/Testing/SingleConnectionSessionSourceForSQLiteInMemoryTesting.cs index aa3c878f1..48fafe74f 100644 --- a/src/FluentNHibernate/Testing/SingleConnectionSessionSourceForSQLiteInMemoryTesting.cs +++ b/src/FluentNHibernate/Testing/SingleConnectionSessionSourceForSQLiteInMemoryTesting.cs @@ -6,7 +6,7 @@ namespace FluentNHibernate.Testing; public class SingleConnectionSessionSourceForSQLiteInMemoryTesting : SessionSource { - private ISession session; + ISession session; public SingleConnectionSessionSourceForSQLiteInMemoryTesting(IDictionary properties, PersistenceModel model) : base(properties, model) { diff --git a/src/FluentNHibernate/Utils/ExpressionToSql.cs b/src/FluentNHibernate/Utils/ExpressionToSql.cs index b70ddddd7..98a0627ee 100644 --- a/src/FluentNHibernate/Utils/ExpressionToSql.cs +++ b/src/FluentNHibernate/Utils/ExpressionToSql.cs @@ -40,7 +40,7 @@ public static string Convert(Expression> expression) throw new InvalidOperationException("Unable to convert expression to SQL"); } - private static string Convert(Expression> expression, MemberExpression body) + static string Convert(Expression> expression, MemberExpression body) { // TODO: should really do something about conventions and overridden names here var member = body.Member; @@ -59,12 +59,12 @@ private static string Convert(Expression> expression, MemberE /// Gets the value of a method call. /// /// Method call expression - private static string Convert(MethodCallExpression body) + static string Convert(MethodCallExpression body) { return Convert(body.Method.Invoke(body.Object, null)); } - private static string Convert(Expression> expression, UnaryExpression body) + static string Convert(Expression> expression, UnaryExpression body) { if (body.Operand is ConstantExpression constant) @@ -79,7 +79,7 @@ private static string Convert(Expression> expression, UnaryEx throw new InvalidOperationException("Unable to convert expression to SQL"); } - private static string Convert(ConstantExpression expression) + static string Convert(ConstantExpression expression) { if (expression.Type.IsEnum) return Convert((int)expression.Value); @@ -87,7 +87,7 @@ private static string Convert(ConstantExpression expression) return Convert(expression.Value); } - private static Expression> CreateExpression(Expression body) + static Expression> CreateExpression(Expression body) { var expression = body; var parameter = Expression.Parameter(typeof(T), "x"); @@ -98,7 +98,7 @@ private static Expression> CreateExpression(Expression body) return (Expression>)Expression.Lambda(typeof(Func), expression, parameter); } - private static string Convert(BinaryExpression expression) + static string Convert(BinaryExpression expression) { var left = Convert(CreateExpression(expression.Left)); var right = Convert(CreateExpression(expression.Right)); @@ -130,7 +130,7 @@ private static string Convert(BinaryExpression expression) return left + " " + op + " " + right; } - private static string Convert(object value) + static string Convert(object value) { if (value is string) return "'" + value + "'"; diff --git a/src/FluentNHibernate/Utils/ObservableDictionary.cs b/src/FluentNHibernate/Utils/ObservableDictionary.cs index 26646b562..2d18f8f2e 100644 --- a/src/FluentNHibernate/Utils/ObservableDictionary.cs +++ b/src/FluentNHibernate/Utils/ObservableDictionary.cs @@ -8,10 +8,10 @@ namespace FluentNHibernate.Utils; public class ObservableDictionary : IDictionary, INotifyCollectionChanged, INotifyPropertyChanged { - private const string CountString = "Count"; - private const string IndexerName = "Item[]"; - private const string KeysName = "Keys"; - private const string ValuesName = "Values"; + const string CountString = "Count"; + const string IndexerName = "Item[]"; + const string KeysName = "Keys"; + const string ValuesName = "Values"; protected IDictionary Dictionary { get; private set; } @@ -155,7 +155,7 @@ public void AddRange(IDictionary items) { } } - private void Insert(TKey key, TValue value, bool add) { + void Insert(TKey key, TValue value, bool add) { if (key is null) throw new ArgumentNullException(nameof(key)); TValue item; @@ -174,7 +174,7 @@ private void Insert(TKey key, TValue value, bool add) { } } - private void OnPropertyChanged() { + void OnPropertyChanged() { OnPropertyChanged(CountString); OnPropertyChanged(IndexerName); OnPropertyChanged(KeysName); @@ -185,22 +185,22 @@ protected virtual void OnPropertyChanged(string propertyName) { PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); } - private void OnCollectionChanged() { + void OnCollectionChanged() { OnPropertyChanged(); CollectionChanged?.Invoke(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); } - private void OnCollectionChanged(NotifyCollectionChangedAction action, KeyValuePair changedItem) { + void OnCollectionChanged(NotifyCollectionChangedAction action, KeyValuePair changedItem) { OnPropertyChanged(); CollectionChanged?.Invoke(this, new NotifyCollectionChangedEventArgs(action, changedItem, 0)); } - private void OnCollectionChanged(NotifyCollectionChangedAction action, KeyValuePair newItem, KeyValuePair oldItem) { + void OnCollectionChanged(NotifyCollectionChangedAction action, KeyValuePair newItem, KeyValuePair oldItem) { OnPropertyChanged(); CollectionChanged?.Invoke(this, new NotifyCollectionChangedEventArgs(action, newItem, oldItem, 0)); } - private void OnCollectionChanged(NotifyCollectionChangedAction action, IList newItems) { + void OnCollectionChanged(NotifyCollectionChangedAction action, IList newItems) { OnPropertyChanged(); CollectionChanged?.Invoke(this, new NotifyCollectionChangedEventArgs(action, newItems, 0)); } diff --git a/src/FluentNHibernate/Utils/Reflection/PropertyChain.cs b/src/FluentNHibernate/Utils/Reflection/PropertyChain.cs index ad0a4bf9b..adb7d4863 100644 --- a/src/FluentNHibernate/Utils/Reflection/PropertyChain.cs +++ b/src/FluentNHibernate/Utils/Reflection/PropertyChain.cs @@ -6,8 +6,8 @@ namespace FluentNHibernate.Utils; public class PropertyChain : Accessor { - private readonly Member[] _chain; - private readonly SingleMember innerMember; + readonly Member[] _chain; + readonly SingleMember innerMember; public PropertyChain(Member[] members) { @@ -79,7 +79,7 @@ public string Name #endregion - private object findInnerMostTarget(object target) + object findInnerMostTarget(object target) { foreach (var info in _chain) { diff --git a/src/FluentNHibernate/Utils/Reflection/ReflectionHelper.cs b/src/FluentNHibernate/Utils/Reflection/ReflectionHelper.cs index d51012547..fe362b064 100644 --- a/src/FluentNHibernate/Utils/Reflection/ReflectionHelper.cs +++ b/src/FluentNHibernate/Utils/Reflection/ReflectionHelper.cs @@ -37,17 +37,17 @@ public static Accessor GetAccessor(Expression> expressi return getAccessor(memberExpression); } - private static bool IsIndexedPropertyAccess(Expression expression) + static bool IsIndexedPropertyAccess(Expression expression) { return IsMethodExpression(expression) && expression.ToString().Contains("get_Item"); } - private static bool IsMethodExpression(Expression expression) + static bool IsMethodExpression(Expression expression) { return expression is MethodCallExpression || (expression is UnaryExpression && IsMethodExpression((expression as UnaryExpression).Operand)); } - private static Member GetMember(Expression expression) + static Member GetMember(Expression expression) { if (IsIndexedPropertyAccess(expression)) return GetDynamicComponentProperty(expression).ToMember(); @@ -59,7 +59,7 @@ private static Member GetMember(Expression expression) return memberExpression.Member.ToMember(); } - private static PropertyInfo GetDynamicComponentProperty(Expression expression) + static PropertyInfo GetDynamicComponentProperty(Expression expression) { Type desiredConversionType = null; MethodCallExpression methodCallExpression = null; @@ -87,12 +87,12 @@ private static PropertyInfo GetDynamicComponentProperty(Expression expression) return new DummyPropertyInfo((string)constExpression.Value, desiredConversionType); } - private static MemberExpression GetMemberExpression(Expression expression) + static MemberExpression GetMemberExpression(Expression expression) { return GetMemberExpression(expression, true); } - private static MemberExpression GetMemberExpression(Expression expression, bool enforceCheck) + static MemberExpression GetMemberExpression(Expression expression, bool enforceCheck) { MemberExpression memberExpression = null; if (expression.NodeType == ExpressionType.Convert) @@ -113,7 +113,7 @@ private static MemberExpression GetMemberExpression(Expression expression, bool return memberExpression; } - private static Accessor getAccessor(MemberExpression memberExpression) + static Accessor getAccessor(MemberExpression memberExpression) { var list = new List(); diff --git a/src/FluentNHibernate/Visitors/ComponentColumnPrefixVisitor.cs b/src/FluentNHibernate/Visitors/ComponentColumnPrefixVisitor.cs index b379ee982..29190f9a9 100644 --- a/src/FluentNHibernate/Visitors/ComponentColumnPrefixVisitor.cs +++ b/src/FluentNHibernate/Visitors/ComponentColumnPrefixVisitor.cs @@ -8,7 +8,7 @@ namespace FluentNHibernate.Visitors; public class ComponentColumnPrefixVisitor : DefaultMappingModelVisitor { - private Stack prefixes = new Stack(); + Stack prefixes = new Stack(); public override void Visit(IComponentMapping mapping) { @@ -23,12 +23,12 @@ public override void ProcessColumn(ColumnMapping columnMapping) columnMapping.Set(x => x.Name, Layer.UserSupplied, GetPrefix() + columnMapping.Name); } - private string GetPrefix() + string GetPrefix() { return string.Join("", prefixes.Reverse().ToArray()); } - private void StorePrefix(IComponentMapping mapping) + void StorePrefix(IComponentMapping mapping) { var prefix = mapping.HasColumnPrefix ? mapping.ColumnPrefix.Replace("{property}", mapping.Member.Name) @@ -37,7 +37,7 @@ private void StorePrefix(IComponentMapping mapping) prefixes.Push(prefix); } - private void ResetPrefix() + void ResetPrefix() { if (prefixes.Count > 0) prefixes.Pop(); diff --git a/src/FluentNHibernate/Visitors/SeparateSubclassVisitor.cs b/src/FluentNHibernate/Visitors/SeparateSubclassVisitor.cs index 53f52ebc9..4bd04ac00 100644 --- a/src/FluentNHibernate/Visitors/SeparateSubclassVisitor.cs +++ b/src/FluentNHibernate/Visitors/SeparateSubclassVisitor.cs @@ -30,7 +30,7 @@ public override void ProcessSubclass(SubclassMapping mapping) base.ProcessSubclass(mapping); } - private IEnumerable FindClosestSubclasses(Type type) + IEnumerable FindClosestSubclasses(Type type) { var extendsSubclasses = subclassProviders .Where(x => x.Extends == type); @@ -46,7 +46,7 @@ private IEnumerable FindClosestSubclasses return subclasses[lowestDistance].Concat(extendsSubclasses); } - private SubclassType GetSubclassType(ClassMapping mapping) + SubclassType GetSubclassType(ClassMapping mapping) { if (mapping.IsUnionSubclass) { @@ -59,7 +59,7 @@ private SubclassType GetSubclassType(ClassMapping mapping) return SubclassType.Subclass; } - private bool IsMapped(Type type, IIndeterminateSubclassMappingProviderCollection providers) + bool IsMapped(Type type, IIndeterminateSubclassMappingProviderCollection providers) { return providers.IsTypeMapped(type); } @@ -76,7 +76,7 @@ private bool IsMapped(Type type, IIndeterminateSubclassMappingProviderCollection /// Starting point, parent type. /// List of subclasses /// Dictionary key'd by the distance from the parentType. - private IDictionary> SortByDistanceFrom(Type parentType, IEnumerable subProviders) + IDictionary> SortByDistanceFrom(Type parentType, IEnumerable subProviders) { var arranged = new Dictionary>(); @@ -108,7 +108,7 @@ private IDictionary> SortByDis /// /// /// - private bool DistanceFromParentInterface(Type parentType, Type evalType, ref int level) + bool DistanceFromParentInterface(Type parentType, Type evalType, ref int level) { if (!evalType.HasInterface(parentType)) return false; @@ -132,7 +132,7 @@ private bool DistanceFromParentInterface(Type parentType, Type evalType, ref int /// /// /// - private bool DistanceFromParentBase(Type parentType, Type evalType, ref int level) + bool DistanceFromParentBase(Type parentType, Type evalType, ref int level) { var evalImplementsParent = false; if (evalType == parentType)