org.teiid.connector.api
Interface Execution

All Known Subinterfaces:
ProcedureExecution, ResultSetExecution, UpdateExecution
All Known Implementing Classes:
BasicExecution

public interface Execution

An execution represents the state and lifecycle for a particular command execution. The methods provided on this interface define standard lifecycle methods. When execution completes, the close() will be called. If execution must be aborted, due to user or administrator action, the cancel() will be called.


Method Summary
 void cancel()
          Cancels the execution abnormally.
 void close()
          Terminates the execution normally.
 void execute()
          Execute the associated command.
 

Method Detail

close

void close()
           throws ConnectorException
Terminates the execution normally.

Throws:
ConnectorException

cancel

void cancel()
            throws ConnectorException
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.

Throws:
ConnectorException

execute

void execute()
             throws ConnectorException
Execute the associated command. Results will be retrieved through a specific sub-interface call.

Throws:
ConnectorException


Copyright © 2009. All Rights Reserved.