gov.nih.nci.cagrid.sdkquery4.processor
Class SDK4QueryProcessor

java.lang.Object
  extended by gov.nih.nci.cagrid.data.cql.CQLQueryProcessor
      extended by gov.nih.nci.cagrid.sdkquery4.processor.SDK4QueryProcessor

public class SDK4QueryProcessor
extends CQLQueryProcessor

SDK4QueryProcessor Processes CQL against a caCORE SDK 4.0 data source

Version:
$Id: SDK4QueryProcessor.java,v 1.14 2008/01/18 18:20:22 dervin Exp $
Author:
David Ervin

Field Summary
static java.lang.String DEFAULT_CASE_INSENSITIVE_QUERYING
           
static java.lang.String DEFAULT_USE_GRID_IDENTITY_LOGIN
           
static java.lang.String DEFAULT_USE_LOCAL_API
           
static java.lang.String DEFAULT_USE_LOGIN
           
static java.lang.String PROPERTY_APPLICATION_NAME
           
static java.lang.String PROPERTY_CASE_INSENSITIVE_QUERYING
           
static java.lang.String PROPERTY_DOMAIN_TYPES_INFO_FILENAME
           
static java.lang.String PROPERTY_HOST_NAME
           
static java.lang.String PROPERTY_HOST_PORT
           
static java.lang.String PROPERTY_ORM_JAR_NAME
           
static java.lang.String PROPERTY_STATIC_LOGIN_PASSWORD
           
static java.lang.String PROPERTY_STATIC_LOGIN_USERNAME
           
static java.lang.String PROPERTY_USE_GRID_IDENTITY_LOGIN
           
static java.lang.String PROPERTY_USE_LOCAL_API
           
static java.lang.String PROPERTY_USE_LOGIN
           
 
Constructor Summary
SDK4QueryProcessor()
           
 
Method Summary
 java.lang.String getConfigurationUiClassname()
          Get the classname of the configuration user interface for this CQL Query Processor.
 java.util.Set<java.lang.String> getPropertiesFromEtc()
          Get a set of property names whose values should be file names prepended with the location of the service's etc directory.
 java.util.Properties getRequiredParameters()
          Get a Properties object of parameters the query processor will require on initialization.
 void initialize(java.util.Properties parameters, java.io.InputStream wsdd)
          Overriden to add initialization of the inheritance manager
 CQLQueryResults processQuery(CQLQuery cqlQuery)
          Processes the CQL Query
protected  java.util.List queryCoreService(CQLQuery query)
           
 
Methods inherited from class gov.nih.nci.cagrid.data.cql.CQLQueryProcessor
getConfiguredParameters, getConfiguredWsddStream
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROPERTY_APPLICATION_NAME

public static final java.lang.String PROPERTY_APPLICATION_NAME
See Also:
Constant Field Values

PROPERTY_USE_LOCAL_API

public static final java.lang.String PROPERTY_USE_LOCAL_API
See Also:
Constant Field Values

PROPERTY_ORM_JAR_NAME

public static final java.lang.String PROPERTY_ORM_JAR_NAME
See Also:
Constant Field Values

PROPERTY_HOST_NAME

public static final java.lang.String PROPERTY_HOST_NAME
See Also:
Constant Field Values

PROPERTY_HOST_PORT

public static final java.lang.String PROPERTY_HOST_PORT
See Also:
Constant Field Values

PROPERTY_CASE_INSENSITIVE_QUERYING

public static final java.lang.String PROPERTY_CASE_INSENSITIVE_QUERYING
See Also:
Constant Field Values

PROPERTY_DOMAIN_TYPES_INFO_FILENAME

public static final java.lang.String PROPERTY_DOMAIN_TYPES_INFO_FILENAME
See Also:
Constant Field Values

PROPERTY_USE_LOGIN

public static final java.lang.String PROPERTY_USE_LOGIN
See Also:
Constant Field Values

PROPERTY_USE_GRID_IDENTITY_LOGIN

public static final java.lang.String PROPERTY_USE_GRID_IDENTITY_LOGIN
See Also:
Constant Field Values

PROPERTY_STATIC_LOGIN_USERNAME

public static final java.lang.String PROPERTY_STATIC_LOGIN_USERNAME
See Also:
Constant Field Values

PROPERTY_STATIC_LOGIN_PASSWORD

public static final java.lang.String PROPERTY_STATIC_LOGIN_PASSWORD
See Also:
Constant Field Values

DEFAULT_USE_LOCAL_API

public static final java.lang.String DEFAULT_USE_LOCAL_API

DEFAULT_CASE_INSENSITIVE_QUERYING

public static final java.lang.String DEFAULT_CASE_INSENSITIVE_QUERYING

DEFAULT_USE_LOGIN

public static final java.lang.String DEFAULT_USE_LOGIN

DEFAULT_USE_GRID_IDENTITY_LOGIN

public static final java.lang.String DEFAULT_USE_GRID_IDENTITY_LOGIN
Constructor Detail

SDK4QueryProcessor

public SDK4QueryProcessor()
Method Detail

initialize

public void initialize(java.util.Properties parameters,
                       java.io.InputStream wsdd)
                throws InitializationException
Overriden to add initialization of the inheritance manager

Overrides:
initialize in class CQLQueryProcessor
Parameters:
parameters - The parameters as configured by the user. The set of keys must contain all of the keys contained in the Properties object returned by getRequiredParamters(). The values in the parameters will be either the user defined value or the default value from getRequiredParameters().
wsdd - The input stream which contains the wsdd configuration for the data service. This stream may be important to locating type mappings for serializing and deserializing beans.
Throws:
InitializationException

processQuery

public CQLQueryResults processQuery(CQLQuery cqlQuery)
                             throws MalformedQueryException,
                                    QueryProcessingException
Description copied from class: CQLQueryProcessor
Processes the CQL Query

Specified by:
processQuery in class CQLQueryProcessor
Returns:
The results of processing a CQL query
Throws:
MalformedQueryException - Should be thrown when the query itself does not conform to the CQL standard or attempts to perform queries outside of the exposed domain model
QueryProcessingException - Thrown for all exceptions in query processing not related to the query being malformed

getRequiredParameters

public java.util.Properties getRequiredParameters()
Description copied from class: CQLQueryProcessor
Get a Properties object of parameters the query processor will require on initialization. Subclasses can override this method to return a map describing paramters their implementation needs. The keys are the names of parameters the query processor requires, the values are the defaults for those properties. The default value of a property may be an empty string if it is an optional paramter. The keys MUST be valid java variable names. They MUST NOT contain spaces or punctuation. They may begin with an uppercase character.

Overrides:
getRequiredParameters in class CQLQueryProcessor
Returns:
The required properties for the query processor with their default values

getPropertiesFromEtc

public java.util.Set<java.lang.String> getPropertiesFromEtc()
Description copied from class: CQLQueryProcessor
Get a set of property names whose values should be file names prepended with the location of the service's etc directory. Potential uses include locating config files, storing logs, etc. Subclasses can override this method to return a Set of Strings which are the names of property keys from the getRequiredParameters() method.

Overrides:
getPropertiesFromEtc in class CQLQueryProcessor
Returns:
The set of property names

getConfigurationUiClassname

public java.lang.String getConfigurationUiClassname()
Description copied from class: CQLQueryProcessor
Get the classname of the configuration user interface for this CQL Query Processor. This class should exist in the same JAR as the query processor, as well as any (non-java / caGrid) classes it depends on. This class MUST implement the abstract base class gov.nih.nci.cagrid.data.cql.ui.CQLQueryProcessorConfigUI

Overrides:
getConfigurationUiClassname in class CQLQueryProcessor
Returns:
The class name of the configuration user interface, or null if no UI is provided

queryCoreService

protected java.util.List queryCoreService(CQLQuery query)
                                   throws MalformedQueryException,
                                          QueryProcessingException
Throws:
MalformedQueryException
QueryProcessingException