ModSQL
Interface Query

All Known Implementing Classes:
Drop, Insert, Select, Create, Update, Delete

interface Query

Interface for the various SQL query classes.

Author:
chris.studholme@utoronto.ca

Method Summary
 void close()
          Close the query and free all resources in use.
 int execute()
          Execute optimized query.
 void optimize()
          Optimize the query before executing it.
 String toString(boolean with_brackets)
          Return human readable version of optimized query.
 

Method Detail

optimize

public void optimize()
              throws SQLException
Optimize the query before executing it.
Throws:
SQLException - if an error occurs

toString

public String toString(boolean with_brackets)
Return human readable version of optimized query.
Parameters:
with_brackets - bracket query expression
Returns:
human-readable text version of query

execute

public int execute()
            throws SQLException
Execute optimized query.
Returns:
update count; -1 if update count is not applicable
Throws:
SQLException - if an error occurs

close

public void close()
           throws SQLException
Close the query and free all resources in use.
Throws:
SQLException - if an error occurs