Package org.hibernate.query.hql.internal
Class StandardHqlTranslator
- java.lang.Object
-
- org.hibernate.query.hql.internal.StandardHqlTranslator
-
- All Implemented Interfaces:
HqlTranslator
public class StandardHqlTranslator extends Object implements HqlTranslator
Standard implementation ofHqlTranslator
.
-
-
Constructor Summary
Constructors Constructor Description StandardHqlTranslator(SqmCreationContext sqmCreationContext, SqmCreationOptions sqmCreationOptions)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static String
prettifyAntlrError(Object offendingSymbol, int line, int charPositionInLine, String message, org.antlr.v4.runtime.RecognitionException e, String hql, boolean includeLocation)
ANTLR's error messages are surprisingly bad, so try to make them a bit better.<R> SqmStatement<R>
translate(String query, Class<R> expectedResultType)
Performs the interpretation of a HQL/JPQL query string to SQM.
-
-
-
Constructor Detail
-
StandardHqlTranslator
public StandardHqlTranslator(SqmCreationContext sqmCreationContext, SqmCreationOptions sqmCreationOptions)
-
-
Method Detail
-
translate
public <R> SqmStatement<R> translate(String query, Class<R> expectedResultType)
Description copied from interface:HqlTranslator
Performs the interpretation of a HQL/JPQL query string to SQM.- Specified by:
translate
in interfaceHqlTranslator
- Parameters:
query
- The HQL/JPQL query string to interpretexpectedResultType
- The type specified when creating the query- Returns:
- The semantic representation of the incoming query.
-
-