Author: steve.ebersole(a)jboss.com
Date: 2009-04-28 12:22:50 -0400 (Tue, 28 Apr 2009)
New Revision: 16470
Added:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/resolve/
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/resolve/TestHQLResolver.java
Removed:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/resolve/TestHQLResolver.java
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Address.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Animal.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Cat.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Classification.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/ClassificationType.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Dog.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/DomesticAnimal.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Human.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Joiner.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Lizard.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Mammal.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Mappings.hbm.xml
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Name.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/PettingZoo.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Reptile.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/StateProvince.java
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Zoo.java
Log:
reorg grammars; primary investigation of unified FUNCTION rewriting; code cleanup; basic
mapped order-by rendering
Copied: core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain (from
rev 16468, core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain)
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Address.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Address.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Address.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* Implementation of Address.
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Animal.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Animal.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Animal.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
import java.util.Set;
import java.util.HashSet;
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Cat.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Cat.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Cat.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Classification.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Classification.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Classification.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
import java.io.Serializable;
import java.util.HashMap;
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/ClassificationType.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/ClassificationType.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/ClassificationType.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
import org.hibernate.usertype.EnhancedUserType;
import org.hibernate.HibernateException;
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Dog.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Dog.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Dog.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/DomesticAnimal.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/DomesticAnimal.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/DomesticAnimal.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Human.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Human.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Human.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
import java.math.BigDecimal;
import java.math.BigInteger;
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Joiner.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Joiner.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Joiner.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* Implementation of Joiner.
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Lizard.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Lizard.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Lizard.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Mammal.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Mammal.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Mammal.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
import java.util.Date;
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Mappings.hbm.xml
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Mappings.hbm.xml 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Mappings.hbm.xml 2009-04-28
16:22:50 UTC (rev 16470)
@@ -24,7 +24,7 @@
-->
<!DOCTYPE hibernate-mapping SYSTEM
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" >
-<hibernate-mapping package="org.hibernate.sql.ast.phase.hql.domain"
default-access="field">
+<hibernate-mapping package="org.hibernate.sql.ast.origin.hql.domain"
default-access="field">
<class name="Animal">
<id name="id">
@@ -126,7 +126,7 @@
</id>
<discriminator column="zooType" type="character"/>
<property name="name" type="string"/>
- <property name="classification"
type="org.hibernate.sql.ast.phase.hql.domain.ClassificationType"/>
+ <property name="classification"
type="org.hibernate.sql.ast.origin.hql.domain.ClassificationType"/>
<map name="mammals">
<key column="mammalZoo_id"/>
<index type="string" column="name"/>
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Name.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Name.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Name.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/PettingZoo.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/PettingZoo.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/PettingZoo.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Reptile.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Reptile.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Reptile.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* @author Gavin King
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/StateProvince.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/StateProvince.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/StateProvince.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
/**
* Implementation of StateProvince.
Modified:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Zoo.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/domain/Zoo.java 2009-04-28
16:14:13 UTC (rev 16468)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/domain/Zoo.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -21,7 +21,7 @@
* 51 Franklin Street, Fifth Floor
* Boston, MA 02110-1301 USA
*/
-package org.hibernate.sql.ast.phase.hql.domain;
+package org.hibernate.sql.ast.origin.hql.domain;
import java.util.Map;
Copied:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/resolve/TestHQLResolver.java
(from rev 16468,
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/resolve/TestHQLResolver.java)
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/resolve/TestHQLResolver.java
(rev 0)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/resolve/TestHQLResolver.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -0,0 +1,90 @@
+package org.hibernate.sql.ast.origin.hql.resolve;
+
+import junit.framework.TestCase;
+
+import org.antlr.runtime.ANTLRStringStream;
+import org.antlr.runtime.CommonTokenStream;
+import org.antlr.runtime.RecognitionException;
+import org.antlr.runtime.tree.CommonTreeNodeStream;
+import org.antlr.runtime.tree.Tree;
+import org.hibernate.cfg.Configuration;
+import org.hibernate.cfg.Environment;
+import org.hibernate.dialect.HSQLDialect;
+import org.hibernate.engine.SessionFactoryImplementor;
+import org.hibernate.hql.classic.ClassicQueryTranslatorFactory;
+import org.hibernate.sql.ast.origin.hql.resolve.HQLResolver;
+import org.hibernate.sql.ast.origin.hql.parse.HQLParser;
+import org.hibernate.sql.ast.origin.hql.parse.HQLLexer;
+
+public class TestHQLResolver extends TestCase {
+
+ private SessionFactoryImplementor sessionFactory;
+ private CommonTokenStream tokens;
+
+ protected void setUp() throws Exception {
+ super.setUp();
+ sessionFactory = ( SessionFactoryImplementor ) new Configuration()
+ .setProperty( Environment.HBM2DDL_AUTO, "none" )
+ .setProperty( Environment.DIALECT, HSQLDialect.class.getName() )
+ .setProperty( Environment.QUERY_TRANSLATOR,
+ ClassicQueryTranslatorFactory.class.getName() )
+ .addResource(
+ "org/hibernate/sql/ast/phase/hql/domain/Mappings.hbm.xml" )
+ .buildSessionFactory();
+ }
+
+ protected void tearDown() throws Exception {
+ if ( sessionFactory != null ) {
+ sessionFactory.close();
+ }
+ super.tearDown();
+ }
+
+ public void testBasicStructure() throws RecognitionException {
+ Tree queryTree = normalize( "from Animal" );
+ }
+
+ public void testBasicSelectStructure() throws Throwable {
+ Tree queryTree = normalize( "from Zoo z where z.mammals['dog'].id =
?" );
+ }
+
+ public Tree normalize( String hql ) throws RecognitionException {
+ return normalize( hql, getSessionFactoryImplementor() );
+ }
+
+ protected SessionFactoryImplementor getSessionFactoryImplementor() {
+ return sessionFactory;
+ }
+
+ public Tree normalize( String hql, SessionFactoryImplementor sessionFactory )
+ throws RecognitionException {
+ Tree result = parse( hql );
+
+ CommonTreeNodeStream nodes = new CommonTreeNodeStream( result );
+ nodes.setTokenStream( tokens );
+
+ HQLResolver resololution = new HQLResolver( nodes, sessionFactory );
+
+ System.out.println( resololution.getTreePrinter().renderAsString(
+ result, "Parser Result" ) );
+
+ Tree resolvedTree = ( Tree ) resololution.statement().getTree();
+
+ System.out.println( resololution.getTreePrinter().renderAsString(
+ resolvedTree, "Resolution Result" ) );
+ return resolvedTree;
+ }
+
+ public Tree parse( String input ) throws RecognitionException {
+ HQLParser parser = buildHQLParser( input );
+ return ( Tree ) parser.statement().getTree();
+ }
+
+ private HQLParser buildHQLParser( String input ) {
+ ANTLRStringStream charStream = new ANTLRStringStream( input );
+ HQLLexer hqlLexer = new HQLLexer( charStream );
+ tokens = new CommonTokenStream( hqlLexer );
+ HQLParser parser = new HQLParser( tokens );
+ return parser;
+ }
+}
Property changes on:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/origin/hql/resolve/TestHQLResolver.java
___________________________________________________________________
Name: svn:eol-style
+ native
Deleted:
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/resolve/TestHQLResolver.java
===================================================================
---
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/resolve/TestHQLResolver.java 2009-04-28
16:16:35 UTC (rev 16469)
+++
core/branches/antlr3/src/test/java/org/hibernate/sql/ast/phase/hql/resolve/TestHQLResolver.java 2009-04-28
16:22:50 UTC (rev 16470)
@@ -1,90 +0,0 @@
-package org.hibernate.sql.ast.phase.hql.resolve;
-
-import junit.framework.TestCase;
-
-import org.antlr.runtime.ANTLRStringStream;
-import org.antlr.runtime.CommonTokenStream;
-import org.antlr.runtime.RecognitionException;
-import org.antlr.runtime.tree.CommonTreeNodeStream;
-import org.antlr.runtime.tree.Tree;
-import org.hibernate.cfg.Configuration;
-import org.hibernate.cfg.Environment;
-import org.hibernate.dialect.HSQLDialect;
-import org.hibernate.engine.SessionFactoryImplementor;
-import org.hibernate.hql.classic.ClassicQueryTranslatorFactory;
-import org.hibernate.sql.ast.origin.hql.resolve.HQLResolver;
-import org.hibernate.sql.ast.origin.hql.parse.HQLParser;
-import org.hibernate.sql.ast.origin.hql.parse.HQLLexer;
-
-public class TestHQLResolver extends TestCase {
-
- private SessionFactoryImplementor sessionFactory;
- private CommonTokenStream tokens;
-
- protected void setUp() throws Exception {
- super.setUp();
- sessionFactory = ( SessionFactoryImplementor ) new Configuration()
- .setProperty( Environment.HBM2DDL_AUTO, "none" )
- .setProperty( Environment.DIALECT, HSQLDialect.class.getName() )
- .setProperty( Environment.QUERY_TRANSLATOR,
- ClassicQueryTranslatorFactory.class.getName() )
- .addResource(
- "org/hibernate/sql/ast/phase/hql/domain/Mappings.hbm.xml" )
- .buildSessionFactory();
- }
-
- protected void tearDown() throws Exception {
- if ( sessionFactory != null ) {
- sessionFactory.close();
- }
- super.tearDown();
- }
-
- public void testBasicStructure() throws RecognitionException {
- Tree queryTree = normalize( "from Animal" );
- }
-
- public void testBasicSelectStructure() throws Throwable {
- Tree queryTree = normalize( "from Zoo z where z.mammals['dog'].id =
?" );
- }
-
- public Tree normalize( String hql ) throws RecognitionException {
- return normalize( hql, getSessionFactoryImplementor() );
- }
-
- protected SessionFactoryImplementor getSessionFactoryImplementor() {
- return sessionFactory;
- }
-
- public Tree normalize( String hql, SessionFactoryImplementor sessionFactory )
- throws RecognitionException {
- Tree result = parse( hql );
-
- CommonTreeNodeStream nodes = new CommonTreeNodeStream( result );
- nodes.setTokenStream( tokens );
-
- HQLResolver resololution = new HQLResolver( nodes, sessionFactory );
-
- System.out.println( resololution.getTreePrinter().renderAsString(
- result, "Parser Result" ) );
-
- Tree resolvedTree = ( Tree ) resololution.statement().getTree();
-
- System.out.println( resololution.getTreePrinter().renderAsString(
- resolvedTree, "Resolution Result" ) );
- return resolvedTree;
- }
-
- public Tree parse( String input ) throws RecognitionException {
- HQLParser parser = buildHQLParser( input );
- return ( Tree ) parser.statement().getTree();
- }
-
- private HQLParser buildHQLParser( String input ) {
- ANTLRStringStream charStream = new ANTLRStringStream( input );
- HQLLexer hqlLexer = new HQLLexer( charStream );
- tokens = new CommonTokenStream( hqlLexer );
- HQLParser parser = new HQLParser( tokens );
- return parser;
- }
-}