File tree Expand file tree Collapse file tree 3 files changed +6
-17
lines changed
hibernate-core/src/main/java/org/hibernate Expand file tree Collapse file tree 3 files changed +6
-17
lines changed Original file line number Diff line number Diff line change @@ -182,14 +182,14 @@ private void visitEmbeddedAttributeMapping(
182
182
if ( attribute .isPluralAttributeMapping () ) {
183
183
addCollectionKey (
184
184
attribute .asPluralAttributeMapping (),
185
- descriptor .getValue ( object , i ),
185
+ attribute .getValue ( object ),
186
186
persistenceContext
187
187
);
188
188
}
189
189
else if ( attribute .isEmbeddedAttributeMapping () ) {
190
190
visitEmbeddedAttributeMapping (
191
191
attribute .asEmbeddedAttributeMapping (),
192
- descriptor .getValue ( object , i ),
192
+ attribute .getValue ( object ),
193
193
persistenceContext
194
194
);
195
195
}
Original file line number Diff line number Diff line change @@ -412,7 +412,7 @@ public EntityHolder claimEntityHolderIfPossible(
412
412
}
413
413
414
414
@ Override
415
- public @ Nullable EntityHolderImpl getEntityHolder (EntityKey key ) {
415
+ public EntityHolderImpl getEntityHolder (EntityKey key ) {
416
416
return entitiesByKey == null ? null : entitiesByKey .get ( key );
417
417
}
418
418
@@ -525,7 +525,7 @@ public Object removeEntity(EntityKey key) {
525
525
}
526
526
527
527
@ Override
528
- public @ Nullable EntityHolderImpl removeEntityHolder (EntityKey key ) {
528
+ public EntityHolderImpl removeEntityHolder (EntityKey key ) {
529
529
final EntityHolderImpl holder ;
530
530
if ( entitiesByKey != null ) {
531
531
holder = entitiesByKey .remove ( key );
@@ -1316,7 +1316,7 @@ public int getNumberOfManagedEntities() {
1316
1316
*/
1317
1317
@ Override
1318
1318
@ Deprecated
1319
- public @ Nullable Map <PersistentCollection <?>,CollectionEntry > getCollectionEntries () {
1319
+ public Map <PersistentCollection <?>,CollectionEntry > getCollectionEntries () {
1320
1320
return collectionEntries ;
1321
1321
}
1322
1322
Original file line number Diff line number Diff line change @@ -398,18 +398,7 @@ else if ( component instanceof Object[] ) {
398
398
return ((Object []) component )[i ];
399
399
}
400
400
else {
401
- final EmbeddableMappingType embeddableMappingType = embeddableTypeDescriptor ();
402
- if ( embeddableMappingType .isPolymorphic () ) {
403
- final EmbeddableMappingType .ConcreteEmbeddableType concreteEmbeddableType = embeddableMappingType .findSubtypeBySubclass (
404
- component .getClass ().getName ()
405
- );
406
- return concreteEmbeddableType .declaresAttribute ( i )
407
- ? embeddableMappingType .getValue ( component , i )
408
- : null ;
409
- }
410
- else {
411
- return embeddableMappingType .getValue ( component , i );
412
- }
401
+ return embeddableTypeDescriptor ().getValue ( component , i );
413
402
}
414
403
}
415
404
You can’t perform that action at this time.
0 commit comments