File tree Expand file tree Collapse file tree 4 files changed +1
-22
lines changed
hibernate-core/src/main/java/org/hibernate Expand file tree Collapse file tree 4 files changed +1
-22
lines changed Original file line number Diff line number Diff line change 1919import org .hibernate .graph .RootGraph ;
2020import org .hibernate .jpa .spi .JpaCompliance ;
2121import org .hibernate .metamodel .MappingMetamodel ;
22- import org .hibernate .service .ServiceRegistry ;
2322import org .hibernate .type .descriptor .java .EnumJavaType ;
2423import org .hibernate .type .descriptor .java .JavaType ;
25- import org .hibernate .type .spi .TypeConfiguration ;
2624
2725/**
2826 * Extensions to the JPA-defined {@linkplain Metamodel metamodel} of
3634@ Incubating
3735public interface JpaMetamodel extends Metamodel {
3836
39- // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
40- // Context
41-
42- /**
43- * todo (6.0) : should we expose JpaMetamodel from TypeConfiguration?
44- */
45- TypeConfiguration getTypeConfiguration ();
46-
47- ServiceRegistry getServiceRegistry ();
48-
49-
5037 // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5138 // Extended features
5239
Original file line number Diff line number Diff line change @@ -112,12 +112,10 @@ public JpaMetamodelImpl(
112112 this .classLoaderService = serviceRegistry .getService ( ClassLoaderService .class );
113113 }
114114
115- @ Override
116115 public TypeConfiguration getTypeConfiguration () {
117116 return typeConfiguration ;
118117 }
119118
120- @ Override
121119 public ServiceRegistry getServiceRegistry () {
122120 return serviceRegistry ;
123121 }
Original file line number Diff line number Diff line change @@ -3685,7 +3685,6 @@ public Object visitAdditionExpression(HqlParser.AdditionExpressionContext ctx) {
36853685 operator ,
36863686 left ,
36873687 right ,
3688- creationContext .getJpaMetamodel (),
36893688 creationContext .getNodeBuilder ()
36903689 );
36913690 }
@@ -3713,7 +3712,6 @@ public Object visitMultiplicationExpression(HqlParser.MultiplicationExpressionCo
37133712 operator ,
37143713 left ,
37153714 right ,
3716- creationContext .getJpaMetamodel (),
37173715 creationContext .getNodeBuilder ()
37183716 );
37193717 }
@@ -5779,15 +5777,13 @@ else if ( lhsExpressible.getRelationalJavaType() instanceof StringJavaType
57795777 BinaryArithmeticOperator .SUBTRACT ,
57805778 end ,
57815779 start ,
5782- creationContext .getJpaMetamodel (),
57835780 creationContext .getNodeBuilder ()
57845781 ),
57855782 new SqmLiteral <>(
57865783 1 ,
57875784 creationContext .getNodeBuilder ().getIntegerType (),
57885785 creationContext .getNodeBuilder ()
57895786 ),
5790- creationContext .getJpaMetamodel (),
57915787 creationContext .getNodeBuilder ()
57925788 )
57935789 ),
Original file line number Diff line number Diff line change 44 */
55package org .hibernate .query .sqm .tree .expression ;
66
7- import org .hibernate .metamodel .model .domain .JpaMetamodel ;
87import org .hibernate .query .sqm .BinaryArithmeticOperator ;
98import org .hibernate .query .sqm .NodeBuilder ;
109import org .hibernate .query .sqm .SemanticQueryWalker ;
@@ -29,11 +28,10 @@ public SqmBinaryArithmetic(
2928 BinaryArithmeticOperator operator ,
3029 SqmExpression <?> lhsOperand ,
3130 SqmExpression <?> rhsOperand ,
32- JpaMetamodel domainModel ,
3331 NodeBuilder nodeBuilder ) {
3432 //noinspection unchecked
3533 super (
36- (SqmBindableType <T >) domainModel .getTypeConfiguration ().resolveArithmeticType (
34+ (SqmBindableType <T >) nodeBuilder .getTypeConfiguration ().resolveArithmeticType (
3735 lhsOperand .getExpressible (),
3836 rhsOperand .getExpressible (),
3937 operator
You can’t perform that action at this time.
0 commit comments