Package org.hibernate.engine.query
Class ParamLocationRecognizer
java.lang.Object
org.hibernate.engine.query.ParamLocationRecognizer
- All Implemented Interfaces:
ParameterParser.Recognizer
Implements a parameter parser recognizer specifically for the purpose
of journaling parameter locations.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the map of named parameter locations.Returns the list of ordinal parameter locations.voidjpaPositionalParameter(String name, int position) voidnamedParameter(String name, int position) voidordinalParameter(int position) voidother(char character) voidoutParameter(int position) static ParamLocationRecognizerparseLocations(String query) Convenience method for creating a param location recognizer and initiating the parse.
-
Constructor Details
-
ParamLocationRecognizer
public ParamLocationRecognizer()
-
-
Method Details
-
parseLocations
Convenience method for creating a param location recognizer and initiating the parse.- Parameters:
query- The query to be parsed for parameter locations.- Returns:
- The generated recognizer, with journaled location info.
-
getNamedParameterDescriptionMap
Returns the map of named parameter locations. The map is keyed by parameter name; the corresponding value is a (@link NamedParameterDescription}.- Returns:
- The map of named parameter locations.
-
getOrdinalParameterLocationList
Returns the list of ordinal parameter locations. The list elements are Integers, representing the location for that given ordinal. ThusgetOrdinalParameterLocationList().elementAt(n) represents the location for the nth parameter.- Returns:
- The list of ordinal parameter locations.
-
ordinalParameter
public void ordinalParameter(int position) - Specified by:
ordinalParameterin interfaceParameterParser.Recognizer
-
namedParameter
- Specified by:
namedParameterin interfaceParameterParser.Recognizer
-
jpaPositionalParameter
- Specified by:
jpaPositionalParameterin interfaceParameterParser.Recognizer
-
other
public void other(char character) - Specified by:
otherin interfaceParameterParser.Recognizer
-
outParameter
public void outParameter(int position) - Specified by:
outParameterin interfaceParameterParser.Recognizer
-