Class CommitQuery

java.lang.Object
com.j_spaces.jdbc.CommitQuery
All Implemented Interfaces:
Query

public class CommitQuery extends Object implements Query
This class handles the COMMIT or ROLLBACK logic. basically it just calls commit or rollback on the given transaction if it exists.
Author:
Michael Mitrani, 2Train4, 2004
  • Constructor Details

    • CommitQuery

      public CommitQuery(boolean isCommit)
      Parameters:
      isCommit - - true for COMMIT, false for ROLLBACK
  • Method Details

    • isCommit

      public boolean isCommit()
    • isRollback

      public boolean isRollback()
    • getSession

      public QuerySession getSession()
    • setSession

      public void setSession(QuerySession session)
      Specified by:
      setSession in interface Query
    • executeOnSpace

      public ResponsePacket executeOnSpace(ISpaceProxy space, Transaction txn) throws SQLException
      Description copied from interface: Query
      Will execute this query on the space and return a ResponsePacket
      Specified by:
      executeOnSpace in interface Query
      Throws:
      SQLException
    • validateQuery

      public void validateQuery(ISpaceProxy space) throws SQLException
      Description copied from interface: Query
      Each query should have its own specific validations. this is the place to do them. if some validation fail, an SQLException will be thrown.
      Specified by:
      validateQuery in interface Query
      Throws:
      SQLException
    • build

      public void build() throws SQLException
      Specified by:
      build in interface Query
      Throws:
      SQLException
    • isPrepared

      public boolean isPrepared()
      Specified by:
      isPrepared in interface Query
      Returns:
      isPrepared is this a PreparedStatment or not.
    • setSecurityInterceptor

      public void setSecurityInterceptor(SecurityInterceptor securityInterceptor)
      Specified by:
      setSecurityInterceptor in interface Query
    • isForceUnderTransaction

      public boolean isForceUnderTransaction()
      Description copied from interface: Query
      Gets whether this query is forced to be executed under transaction.
      Specified by:
      isForceUnderTransaction in interface Query
    • containsSubQueries

      public boolean containsSubQueries()
      Description copied from interface: Query
      Gets whether this query contains sub queries.
      Specified by:
      containsSubQueries in interface Query