com.metamatrix.connector.ldap
Class LDAPSyncQueryExecution

java.lang.Object
  extended by org.teiid.connector.basic.BasicExecution
      extended by com.metamatrix.connector.ldap.LDAPSyncQueryExecution
All Implemented Interfaces:
Execution, ResultSetExecution

public class LDAPSyncQueryExecution
extends BasicExecution
implements ResultSetExecution

LDAPSyncQueryExecution is responsible for executing an LDAP search corresponding to a read-only "select" query from MetaMatrix.


Constructor Summary
LDAPSyncQueryExecution(IQuery query, ExecutionContext ctx, RuntimeMetadata rm, ConnectorLogger logger, javax.naming.ldap.InitialLdapContext ldapCtx, java.util.Properties props)
          Constructor
 
Method Summary
 void cancel()
          Cancels the execution abnormally.
 void close()
          Terminates the execution normally.
 void execute()
          method to execute the supplied query
 java.util.List next()
          Fetch the next batch of data from the LDAP searchEnumerationr result.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LDAPSyncQueryExecution

public LDAPSyncQueryExecution(IQuery query,
                              ExecutionContext ctx,
                              RuntimeMetadata rm,
                              ConnectorLogger logger,
                              javax.naming.ldap.InitialLdapContext ldapCtx,
                              java.util.Properties props)
                       throws ConnectorException
Constructor

Parameters:
executionMode - the execution mode.
ctx - the execution context.
rm - the runtimeMetadata
logger - the ConnectorLogger
ldapCtx - the LDAP Context
Throws:
ConnectorException
Method Detail

execute

public void execute()
             throws ConnectorException
method to execute the supplied query

Specified by:
execute in interface Execution
Parameters:
query - the query object.
maxBatchSize - the max batch size.
Throws:
ConnectorException

cancel

public void cancel()
            throws ConnectorException
Description copied from interface: Execution
Cancels the execution abnormally. This will happen via a different thread from the one performing the execution, so should be expected to happen in a multi-threaded scenario.

Specified by:
cancel in interface Execution
Throws:
ConnectorException

close

public void close()
           throws ConnectorException
Description copied from interface: Execution
Terminates the execution normally.

Specified by:
close in interface Execution
Throws:
ConnectorException

next

public java.util.List next()
                    throws ConnectorException
Fetch the next batch of data from the LDAP searchEnumerationr result.

Specified by:
next in interface ResultSetExecution
Returns:
the next Batch of results.
Throws:
ConnectorException


Copyright © 2009. All Rights Reserved.