[hibernate-dev] PropertyFactory and invocation of PropertyAccessStrategyResolver

Gunnar Morling gunnar at hibernate.org
Wed Feb 10 17:45:36 EST 2016


Hey,

In ORM's PropertyFactory#getGetter() line 317 I see that
mappingProperty.getClass() is passed to
resolvePropertyAccessStrategy() [1]. I.e. the type
org.hibernate.mapping.Property or similar will be passed here.

Is this actually correct? It seems
mappingProperty.getPersistentClass().getMappedClass() should be passed
instead; As per the parameter docs it's "The java class of the entity"
and the usage in PropertyAccessStrategyResolverStandardImpl confirms
that.

Thanks,

--Gunnar

[https://github.com/hibernate/hibernate-orm/blob/master/hibernate-core/src/main/java/org/hibernate/tuple/PropertyFactory.java#L317]


More information about the hibernate-dev mailing list