gov.nih.nci.cagrid.data.cql.cacore
Class CQL2HQL

java.lang.Object
  extended by gov.nih.nci.cagrid.data.cql.cacore.CQL2HQL

public class CQL2HQL
extends java.lang.Object

CQL2HQL Translates a CQL query to Hibernate v3 HQL

Version:
$Id$
Author:
David W. Ervin

Field Summary
static java.lang.String TARGET_ALIAS
           
 
Constructor Summary
CQL2HQL()
           
 
Method Summary
static java.lang.String translate(CQLQuery query, boolean eliminateSubclasses, boolean caseInsensitive)
          Translates a CQL query into an HQL string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TARGET_ALIAS

public static final java.lang.String TARGET_ALIAS
See Also:
Constant Field Values
Constructor Detail

CQL2HQL

public CQL2HQL()
Method Detail

translate

public static java.lang.String translate(CQLQuery query,
                                         boolean eliminateSubclasses,
                                         boolean caseInsensitive)
                                  throws QueryProcessingException
Translates a CQL query into an HQL string. This translation process assumes the CQL Query has passed validation. Processing of invalid CQL may or may not procede with undefined results.

Parameters:
query - The CQL Query to translate into HQL
eliminateSubclasses - A flag indicating that the query should be formulated to avoid returning subclass instances of the targeted class.
caseInsensitive - A flag indicating that the query should be made case insensitive by converting all values to lowercase.
Returns:
An HQL query
Throws:
QueryProcessingException