edu.indiana.dde.mylead.dai
Class MyLeadQueryImpl

java.lang.Object
  extended by uk.org.ogsadai.engine.Activity
      extended by uk.org.ogsadai.activity.sql.SQLActivity
          extended by edu.indiana.dde.mylead.dai.MyLeadActivity
              extended by edu.indiana.dde.mylead.dai.MyLeadQueryActivity
                  extended by edu.indiana.dde.mylead.dai.MyLeadQueryImpl

public class MyLeadQueryImpl
extends MyLeadQueryActivity

Handles myLEAD Query Elements from a Grid Data Service Document.


Nested Class Summary
 
Nested classes/interfaces inherited from class uk.org.ogsadai.activity.sql.SQLActivity
uk.org.ogsadai.activity.sql.SQLActivity.ParameterInput, uk.org.ogsadai.activity.sql.SQLActivity.StreamInput, uk.org.ogsadai.activity.sql.SQLActivity.ValueInput
 
Field Summary
static int QRYCHAIN_CHILDOF
           
static int QRYCHAIN_CONTAINS
           
static int QRYCHAIN_NONE
           
static int QRYCHAIN_PARENTOF
           
static int QRYCHAIN_WITHIN
           
static int QRYSET_AND
           
static int QRYSET_OR
           
 
Fields inherited from class edu.indiana.dde.mylead.dai.MyLeadQueryActivity
CFILTER_ATTR, CFILTER_ELEMENT, CFILTER_FULL, CFILTER_GUID_VAL, CFILTER_GUIDONLY, CFILTER_NONE, CFILTER_SCHEMA_VAL, CFILTER_SIZE, HFILTER_CHILDREN, HFILTER_CHILDREN_VAL, HFILTER_SET, HFILTER_SUBTREE, HFILTER_SUBTREE_VAL, HFILTER_TARGET, HFILTER_TARGET_VAL, mCFilter, mCFilterType, mChildFilter, mExclAttr, mExclNode, mFilterNodes, mGuidCnt, mGuids, mHFilter, mHFilterType, mLimit, mOffset, mParentFilter, mQueryNode, mTargetNode
 
Fields inherited from class edu.indiana.dde.mylead.dai.MyLeadActivity
AUTHORITY_ADDATTR, AUTHORITY_CREATE, AUTHORITY_DEL_REPLICA, AUTHORITY_DEL_USER, AUTHORITY_DELETEATTR, AUTHORITY_UPDATE, mActivityName, mDn, MYLEAD_DB, MYLEAD_WRITER_REPLICA, MYLEAD_WRITER_TBL, startTime
 
Fields inherited from class uk.org.ogsadai.activity.sql.SQLActivity
CREATE_DATABASE, DROP_DATABASE, EXPRESSION, mAllInput, mConnection, mConnectionManager, mCredentials, mExpression, mExpressionInput, mInputStreams, mIsTransaction, mNameToInput, mOpenConnection, mOutput, mStatement, RESULT_STREAM, SQL_PARAMETERS, STORED_PROCEDURE, WEB_ROW_SET_STREAM
 
Fields inherited from class uk.org.ogsadai.engine.Activity
mContext, mExternalInputs, mExternalOutputs, mInternalInputs, mInternalOutputs
 
Constructor Summary
MyLeadQueryImpl(org.w3c.dom.Element element)
          Constructor
 
Method Summary
protected  boolean getResult()
          This method does the actual processing of the query.
 
Methods inherited from class edu.indiana.dde.mylead.dai.MyLeadQueryActivity
fillGlobalId, fillResults, processBlock
 
Methods inherited from class edu.indiana.dde.mylead.dai.MyLeadActivity
checkAuthorization, dumpLog, endProcessing, finalize, getObjectId, getParameter, getWhiteboardId, markTime, queryTimestamp, startProcessing
 
Methods inherited from class uk.org.ogsadai.activity.sql.SQLActivity
initialise, loadNextExpression, parseCommand, parseResultStream, parseSQLParameters, prepareStatement, setupInputStreamNames
 
Methods inherited from class uk.org.ogsadai.engine.Activity
cleanUp, connectsTo, getActivityConfiguration, getName, getObservableStatus, getProperties, getStatus, hasActivityConfiguration, hasProperties, processFirst, setCompleted, setError
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

QRYCHAIN_NONE

public static final int QRYCHAIN_NONE
See Also:
Constant Field Values

QRYCHAIN_CONTAINS

public static final int QRYCHAIN_CONTAINS
See Also:
Constant Field Values

QRYCHAIN_PARENTOF

public static final int QRYCHAIN_PARENTOF
See Also:
Constant Field Values

QRYCHAIN_WITHIN

public static final int QRYCHAIN_WITHIN
See Also:
Constant Field Values

QRYCHAIN_CHILDOF

public static final int QRYCHAIN_CHILDOF
See Also:
Constant Field Values

QRYSET_OR

public static final int QRYSET_OR
See Also:
Constant Field Values

QRYSET_AND

public static final int QRYSET_AND
See Also:
Constant Field Values
Constructor Detail

MyLeadQueryImpl

public MyLeadQueryImpl(org.w3c.dom.Element element)
                throws uk.org.ogsadai.common.exception.engine.activity.ActivityUserException,
                       uk.org.ogsadai.common.exception.engine.activity.ActivitySystemException
Constructor

Parameters:
element - Element containing Statement conforming to schema for this activity. It is assumed schema checks have been carried out.
Throws:
uk.org.ogsadai.common.exception.engine.activity.ActivitySystemException - If there is a problem constructing the activity due to an implementation error or OGSA-DAI confguration problem.
uk.org.ogsadai.common.exception.engine.activity.ActivityUserException - If there is a problem constructing the activity due to a user mistake such as an invalid setting.
Method Detail

getResult

protected boolean getResult()
                     throws java.sql.SQLException,
                            uk.org.ogsadai.common.exception.engine.activity.ActivitySystemException,
                            uk.org.ogsadai.common.exception.engine.activity.ActivityUserException
This method does the actual processing of the query. If it encounters any error in executing or in the data (e.g., the user does not exist) then an OGSA-DAI ActivityUserException is thrown and the processBlock method outputs the error message returned to the user.

Overrides:
getResult in class uk.org.ogsadai.activity.sql.SQLActivity
Returns:
boolean indicating if getResult completed. Although the return value is not used in this activity's process block method, it has to return a boolean since this method returns a boolean in the SQLActivity as defined in OGSA-DAI.
Throws:
SQLException, - ActivitySystemException, ActivityUserException
java.sql.SQLException
uk.org.ogsadai.common.exception.engine.activity.ActivitySystemException
uk.org.ogsadai.common.exception.engine.activity.ActivityUserException