org.hibernate.sql.ordering.antlr.Factory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-core Show documentation
Show all versions of hibernate-core Show documentation
JPMS Module-Info's for a few of the Jakarta Libraries just until they add them in themselves
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or .
*/
package org.hibernate.sql.ordering.org.hibernate.relocated.org.hibernate.relocated.antlr;
import org.hibernate.relocated.org.hibernate.relocated.antlr.ASTFactory;
/**
* Acts as a {@link ASTFactory} for injecting our specific AST node classes into the Antlr generated trees.
*
* @author Steve Ebersole
*/
public class Factory extends ASTFactory implements OrderByTemplateTokenTypes {
@Override
public Class getASTNodeType(int i) {
switch ( i ) {
case ORDER_BY:
return OrderByFragment.class;
case SORT_SPEC:
return SortSpecification.class;
case ORDER_SPEC:
return OrderingSpecification.class;
case COLLATE:
return CollationSpecification.class;
case SORT_KEY:
return SortKey.class;
default:
return NodeSupport.class;
}
}
}