This is an automated email from the ASF dual-hosted git repository.

borinquenkid pushed a commit to branch 8.0.x-hibernate7
in repository https://gitbox.apache.org/repos/asf/grails-core.git

commit adcc7954b0a32485f2c28d5c9b9b4b858002c655
Author: Walter Duque de Estrada <[email protected]>
AuthorDate: Tue Feb 24 08:18:16 2026 -0600

    clean up GrailsPropertyBinder
---
 .../domainbinding/binder/GrailsDomainBinder.java   | 11 ++++------
 .../domainbinding/binder/GrailsPropertyBinder.java | 17 ++-------------
 .../cfg/domainbinding/CollectionBinderSpec.groovy  | 12 +++++------
 .../domainbinding/GrailsPropertyBinderSpec.groovy  | 24 +++++++++++-----------
 .../secondpass/ListSecondPassBinderSpec.groovy     | 12 +++++------
 .../secondpass/MapSecondPassBinderSpec.groovy      | 12 +++++------
 6 files changed, 36 insertions(+), 52 deletions(-)

diff --git 
a/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsDomainBinder.java
 
b/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsDomainBinder.java
index dfd3fad2a6..01d379f1aa 100644
--- 
a/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsDomainBinder.java
+++ 
b/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsDomainBinder.java
@@ -163,16 +163,13 @@ public class GrailsDomainBinder implements 
AdditionalMappingContributor, TypeCon
 
     GrailsPropertyBinder grailsPropertyBinder =
         new GrailsPropertyBinder(
-            metadataBuildingContext,
-            namingStrategy,
-            enumTypeBinder,
+                enumTypeBinder,
             componentBinder,
             collectionBinder,
             simpleValueBinder,
-            columnNameForPropertyAndPathFetcher,
-            oneToOneBinder,
-            manyToOneBinder,
-            propertyFromValueCreator);
+                oneToOneBinder,
+            manyToOneBinder
+        );
     componentBinder.setGrailsPropertyBinder(grailsPropertyBinder);
     CompositeIdBinder compositeIdBinder =
         new CompositeIdBinder(
diff --git 
a/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsPropertyBinder.java
 
b/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsPropertyBinder.java
index 36d16f2f84..a22e752407 100644
--- 
a/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsPropertyBinder.java
+++ 
b/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/domainbinding/binder/GrailsPropertyBinder.java
@@ -20,16 +20,13 @@ package org.grails.orm.hibernate.cfg.domainbinding.binder;
 
 import jakarta.annotation.Nonnull;
 import org.grails.datastore.mapping.model.types.Association;
-import org.grails.orm.hibernate.cfg.PersistentEntityNamingStrategy;
 import 
org.grails.orm.hibernate.cfg.domainbinding.hibernate.GrailsHibernatePersistentProperty;
 import 
org.grails.orm.hibernate.cfg.domainbinding.hibernate.HibernateEmbeddedProperty;
 import 
org.grails.orm.hibernate.cfg.domainbinding.hibernate.HibernateManyToOneProperty;
 import 
org.grails.orm.hibernate.cfg.domainbinding.hibernate.HibernateOneToOneProperty;
 import 
org.grails.orm.hibernate.cfg.domainbinding.hibernate.HibernateToManyProperty;
-import 
org.grails.orm.hibernate.cfg.domainbinding.util.ColumnNameForPropertyAndPathFetcher;
-import 
org.grails.orm.hibernate.cfg.domainbinding.util.PropertyFromValueCreator;
+
 import org.hibernate.boot.spi.InFlightMetadataCollector;
-import org.hibernate.boot.spi.MetadataBuildingContext;
 import org.hibernate.mapping.PersistentClass;
 import org.hibernate.mapping.Table;
 import org.hibernate.mapping.Value;
@@ -40,36 +37,26 @@ public class GrailsPropertyBinder {
 
   private static final Logger LOG = 
LoggerFactory.getLogger(GrailsPropertyBinder.class);
 
-  private final MetadataBuildingContext metadataBuildingContext;
   private final EnumTypeBinder enumTypeBinder;
   private final ComponentBinder componentBinder;
   private final CollectionBinder collectionBinder;
   private final SimpleValueBinder simpleValueBinder;
-  private final ColumnNameForPropertyAndPathFetcher 
columnNameForPropertyAndPathFetcher;
   private final OneToOneBinder oneToOneBinder;
   private final ManyToOneBinder manyToOneBinder;
-  private final PropertyFromValueCreator propertyFromValueCreator;
 
   public GrailsPropertyBinder(
-      MetadataBuildingContext metadataBuildingContext,
-      PersistentEntityNamingStrategy namingStrategy,
       EnumTypeBinder enumTypeBinder,
       ComponentBinder componentBinder,
       CollectionBinder collectionBinder,
       SimpleValueBinder simpleValueBinder,
-      ColumnNameForPropertyAndPathFetcher columnNameForPropertyAndPathFetcher,
       OneToOneBinder oneToOneBinder,
-      ManyToOneBinder manyToOneBinder,
-      PropertyFromValueCreator propertyFromValueCreator) {
-    this.metadataBuildingContext = metadataBuildingContext;
+      ManyToOneBinder manyToOneBinder) {
     this.enumTypeBinder = enumTypeBinder;
     this.componentBinder = componentBinder;
     this.collectionBinder = collectionBinder;
     this.simpleValueBinder = simpleValueBinder;
-    this.columnNameForPropertyAndPathFetcher = 
columnNameForPropertyAndPathFetcher;
     this.oneToOneBinder = oneToOneBinder;
     this.manyToOneBinder = manyToOneBinder;
-    this.propertyFromValueCreator = propertyFromValueCreator;
   }
 
   public Value bindProperty(
diff --git 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/CollectionBinderSpec.groovy
 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/CollectionBinderSpec.groovy
index 175f9b7e05..785603456f 100644
--- 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/CollectionBinderSpec.groovy
+++ 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/CollectionBinderSpec.groovy
@@ -93,16 +93,16 @@ class CollectionBinderSpec extends 
HibernateGormDatastoreSpec {
         )
 
         GrailsPropertyBinder propertyBinder = new GrailsPropertyBinder(
-                metadataBuildingContext,
-                namingStrategy,
+
+
                 enumTypeBinderToUse,
                 componentBinder,
                 collectionBinder,
-                simpleValueBinder,
-                columnNameForPropertyAndPathFetcher,
+                simpleValueBinder
+                ,
                 oneToOneBinder,
-                manyToOneBinder,
-                propertyFromValueCreator
+                manyToOneBinder
+
         )
         CompositeIdBinder compositeIdBinder = new 
CompositeIdBinder(metadataBuildingContext, componentBinder, componentUpdater, 
propertyBinder)
         PropertyBinder propertyBinderHelper = new PropertyBinder()
diff --git 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/GrailsPropertyBinderSpec.groovy
 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/GrailsPropertyBinderSpec.groovy
index 60cb5c805f..d624f999bd 100644
--- 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/GrailsPropertyBinderSpec.groovy
+++ 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/GrailsPropertyBinderSpec.groovy
@@ -151,16 +151,16 @@ class GrailsPropertyBinderSpec extends 
HibernateGormDatastoreSpec {
                 componentUpdater
         )
         GrailsPropertyBinder propertyBinder = new GrailsPropertyBinder(
-                metadataBuildingContext,
-                namingStrategy,
+
+
                 enumTypeBinderToUse,
                 componentBinder,
                 collectionBinder,
-                simpleValueBinder,
-                columnNameForPropertyAndPathFetcher,
+                simpleValueBinder
+                ,
                 oneToOneBinder,
-                manyToOneBinder,
-                propertyFromValueCreator
+                manyToOneBinder
+
         )
         componentBinder.setGrailsPropertyBinder(propertyBinder)
         CompositeIdBinder compositeIdBinder = new 
CompositeIdBinder(metadataBuildingContext, componentBinder, componentUpdater, 
propertyBinder);
@@ -503,16 +503,16 @@ class GrailsPropertyBinderSpec extends 
HibernateGormDatastoreSpec {
 
         // Instantiate GrailsPropertyBinder using the protected constructor 
with necessary mocks
         def propertyBinder = new GrailsPropertyBinder(
-                metadataBuildingContext,
-                namingStrategy,
+
+
                 enumTypeBinder,
                 componentBinder,
                 collectionBinder,
-                simpleValueBinder,
-                columnNameForPropertyAndPathFetcher,
+                simpleValueBinder
+                ,
                 oneToOneBinder,
-                manyToOneBinder,
-                propertyFromValueCreator
+                manyToOneBinder
+
         )
 
         def mappings = Mock(org.hibernate.boot.spi.InFlightMetadataCollector)
diff --git 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/ListSecondPassBinderSpec.groovy
 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/ListSecondPassBinderSpec.groovy
index 9660078251..633db309d6 100644
--- 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/ListSecondPassBinderSpec.groovy
+++ 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/ListSecondPassBinderSpec.groovy
@@ -92,16 +92,16 @@ class ListSecondPassBinderSpec extends 
HibernateGormDatastoreSpec {
         )
 
         GrailsPropertyBinder propertyBinder = new GrailsPropertyBinder(
-                metadataBuildingContext,
-                namingStrategy,
+
+
                 enumTypeBinderToUse,
                 componentBinder,
                 collectionBinder,
-                simpleValueBinder,
-                columnNameForPropertyAndPathFetcher,
+                simpleValueBinder
+                ,
                 oneToOneBinder,
-                manyToOneBinder,
-                propertyFromValueCreator
+                manyToOneBinder
+
         )
         CompositeIdBinder compositeIdBinder = new 
CompositeIdBinder(metadataBuildingContext, componentBinder, componentUpdater, 
propertyBinder)
         PropertyBinder propertyBinderHelper = new PropertyBinder()
diff --git 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/MapSecondPassBinderSpec.groovy
 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/MapSecondPassBinderSpec.groovy
index b21654289e..3f9eed99ee 100644
--- 
a/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/MapSecondPassBinderSpec.groovy
+++ 
b/grails-data-hibernate7/core/src/test/groovy/org/grails/orm/hibernate/cfg/domainbinding/secondpass/MapSecondPassBinderSpec.groovy
@@ -92,16 +92,16 @@ class MapSecondPassBinderSpec extends 
HibernateGormDatastoreSpec {
         )
 
         GrailsPropertyBinder propertyBinder = new GrailsPropertyBinder(
-                metadataBuildingContext,
-                namingStrategy,
+
+
                 enumTypeBinderToUse,
                 componentBinder,
                 collectionBinder,
-                simpleValueBinder,
-                columnNameForPropertyAndPathFetcher,
+                simpleValueBinder
+                ,
                 oneToOneBinder,
-                manyToOneBinder,
-                propertyFromValueCreator
+                manyToOneBinder
+
         )
         CompositeIdBinder compositeIdBinder = new 
CompositeIdBinder(metadataBuildingContext, componentBinder, componentUpdater, 
propertyBinder)
         PropertyBinder propertyBinderHelper = new PropertyBinder()

Reply via email to