Class HQLAnalyzer
java.lang.Object
org.hibernate.tool.ide.completion.HQLAnalyzer
The HQLAnalyzer can answer certain questions about a HQL String.
- Author:
- leon, max.andersen@jboss.com
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetEntityNamePrefix(char[] chars, int position) Returns reference name found from position and backwards in the array.protected SimpleHQLLexergetLexer(char[] chars) protected SimpleHQLLexergetLexer(char[] chars, int end) getSubQueries(char[] query, int position) getVisibleEntityNames(char[] chars, int position) getVisibleSubQueries(char[] chars, int position) booleanshouldShowEntityNames(char[] chars, int cursorPosition) booleanshouldShowEntityNames(String query, int cursorPosition) Returns true if the position is at a location where an entityname makes sense.
-
Constructor Details
-
HQLAnalyzer
public HQLAnalyzer()
-
-
Method Details
-
getLexer
-
getLexer
-
shouldShowEntityNames
Returns true if the position is at a location where an entityname makes sense. e.g. "from Pr| where x"- Parameters:
query-cursorPosition-- Returns:
-
shouldShowEntityNames
public boolean shouldShowEntityNames(char[] chars, int cursorPosition) -
getVisibleSubQueries
-
getVisibleEntityNames
-
getSubQueries
-
getEntityNamePrefix
Returns reference name found from position and backwards in the array.
-