org.wso2.carbon.dataservices.sql.driver

## Class TExcelConnection

- java.lang.Object
- - org.wso2.carbon.dataservices.sql.driver.TConnection
  - - org.wso2.carbon.dataservices.sql.driver.TExcelConnection

- All Implemented Interfaces:
    AutoCloseable, Connection, Wrapper

      public class TExcelConnection
      extends TConnection

- - ### Field Summary

    - ### Fields inherited from interface java.sql.Connection

      `TRANSACTION_NONE, TRANSACTION_READ_COMMITTED, TRANSACTION_READ_UNCOMMITTED, TRANSACTION_REPEATABLE_READ, TRANSACTION_SERIALIZABLE`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TExcelConnection(Properties props)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `beginExcelTransaction()` Begin transaction method for Excel connections, This will reread the workbook and acquire the lock as well.
    `void` | `close()`
    `void` | `commit()`
    `Statement` | `createStatement()`
    `Statement` | `createStatement(String sql)`
    `org.apache.poi.ss.usermodel.Workbook` | `getWorkbook()`
    `CallableStatement` | `prepareCall(String sql)`
    `CallableStatement` | `prepareCall(String sql, int resultSetType, int resultSetConcurrency)`
    `CallableStatement` | `prepareCall(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability)`
    `PreparedStatement` | `prepareStatement(String sql)`
    `PreparedStatement` | `prepareStatement(String sql, int autoGeneratedKeys)`
    `PreparedStatement` | `prepareStatement(String sql, int[] columnIndexes)`
    `PreparedStatement` | `prepareStatement(String sql, int resultSetType, int resultSetConcurrency)`
    `PreparedStatement` | `prepareStatement(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability)`
    `PreparedStatement` | `prepareStatement(String sql, String[] columnNames)`
    `void` | `rollback()`

    - ### Methods inherited from class org.wso2.carbon.dataservices.sql.driver.TConnection

      `abort, clearWarnings, createArrayOf, createBlob, createClob, createNClob, createSQLXML, createStatement, createStatement, createStruct, getAutoCommit, getCatalog, getClientInfo, getClientInfo, getHoldability, getMaxColumns, getMetaData, getNetworkTimeout, getPassword, getPath, getSchema, getTransactionIsolation, getType, getTypeMap, getUsername, getWarnings, hasHeader, isClosed, isReadOnly, isValid, isWrapperFor, nativeSQL, releaseSavepoint, rollback, setAutoCommit, setCatalog, setClientInfo, setClientInfo, setHoldability, setNetworkTimeout, setReadOnly, setSavepoint, setSavepoint, setSchema, setTransactionIsolation, setTypeMap, unwrap`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### TExcelConnection

          public TExcelConnection(Properties props)
                           throws SQLException

      Throws:
        `SQLException`

  - ### Method Detail

    - #### getWorkbook

          public org.apache.poi.ss.usermodel.Workbook getWorkbook()

    - #### createStatement

          public Statement createStatement(String sql)
                                    throws SQLException

      Throws:
        `SQLException`

    - #### createStatement

          public Statement createStatement()
                                    throws SQLException

      Throws:
        `SQLException`

    - #### prepareStatement

          public PreparedStatement prepareStatement(String sql)
                                             throws SQLException

      Throws:
        `SQLException`

    - #### prepareCall

          public CallableStatement prepareCall(String sql)
                                        throws SQLException

      Throws:
        `SQLException`

    - #### prepareStatement

          public PreparedStatement prepareStatement(String sql,
                                                    int resultSetType,
                                                    int resultSetConcurrency)
                                             throws SQLException

      Throws:
        `SQLException`

    - #### prepareCall

          public CallableStatement prepareCall(String sql,
                                               int resultSetType,
                                               int resultSetConcurrency)
                                        throws SQLException

      Throws:
        `SQLException`

    - #### prepareStatement

          public PreparedStatement prepareStatement(String sql,
                                                    int resultSetType,
                                                    int resultSetConcurrency,
                                                    int resultSetHoldability)
                                             throws SQLException

      Throws:
        `SQLException`

    - #### prepareCall

          public CallableStatement prepareCall(String sql,
                                               int resultSetType,
                                               int resultSetConcurrency,
                                               int resultSetHoldability)
                                        throws SQLException

      Throws:
        `SQLException`

    - #### prepareStatement

          public PreparedStatement prepareStatement(String sql,
                                                    int autoGeneratedKeys)
                                             throws SQLException

      Throws:
        `SQLException`

    - #### prepareStatement

          public PreparedStatement prepareStatement(String sql,
                                                    int[] columnIndexes)
                                             throws SQLException

      Throws:
        `SQLException`

    - #### prepareStatement

          public PreparedStatement prepareStatement(String sql,
                                                    String[] columnNames)
                                             throws SQLException

      Throws:
        `SQLException`

    - #### beginExcelTransaction

          public void beginExcelTransaction()
                                     throws SQLException

      Begin transaction method for Excel connections, This will reread the workbook and acquire the lock as well.
      Throws:
        `SQLException`

    - #### commit

          public void commit()
                      throws SQLException

      Specified by:
        `commit` in interface `Connection`
      Overrides:
        `commit` in class `TConnection`
      Throws:
        `SQLException`

    - #### rollback

          public void rollback()
                        throws SQLException

      Specified by:
        `rollback` in interface `Connection`
      Overrides:
        `rollback` in class `TConnection`
      Throws:
        `SQLException`

    - #### close

          public void close()
                     throws SQLException

      Specified by:
        `close` in interface `AutoCloseable`
      Specified by:
        `close` in interface `Connection`
      Overrides:
        `close` in class `TConnection`
      Throws:
        `SQLException`

Copyright © 2019 WSO2. All rights reserved.