org.mariadb.jdbc.internal.protocol

## Interface Protocol

All Known Implementing Classes:
  AbstractConnectProtocol, AbstractQueryProtocol, AuroraProtocol, MasterProtocol, MastersSlavesProtocol

    public interface Protocol

### Method Summary

All Methods Instance Methods Abstract Methods
`void` `cancelCurrentQuery()`
`boolean` `checkIfMaster()`
`void` `close()`
`void` `closeExplicit()`
`void` `connect()`
`void` `connectWithoutProxy()`
`void` `executePreparedQuery(PrepareResult prepareResult, ExecutionResult executionResult, String sql, ParameterHolder[] parameters, MariaDbType[] parameterTypeHeader, int resultSetScrollType)`
`void` `executePreparedQueryAfterFailover(PrepareResult oldPrepareResult, ExecutionResult executionResult, String sql, ParameterHolder[] parameters, MariaDbType[] parameterTypeHeader, int resultSetScrollType)`
`void` `executeQueries(ExecutionResult executionResult, List<String> queries, int resultSetScrollType)`
`void` `executeQueries(ExecutionResult executionResult, List<String> queryParts, List<ParameterHolder[]> parameterList, int resultSetScrollType, boolean isRewritable)`
`void` `executeQueriesRewrite(ExecutionResult executionResult, List<String> queries, int resultSetScrollType, boolean isRewritable, int rewriteOffset)`
`void` `executeQuery(ExecutionResult executionResult, String sql, int resultSetScrollType)`
`void` `executeQuery(String sql)`
`void` `forceReleasePrepareStatement(int statementId)`
`MariaSelectResultSet` `getActiveStreamingResult()`
`boolean` `getAutocommit()`
`Calendar` `getCalendar()`
`String` `getDatabase()`
`int` `getDataTypeMappingFlags()`
`String` `getHost()`
`HostAddress` `getHostAddress()`
`ReentrantLock` `getLock()`
`int` `getMajorServerVersion()`
`int` `getMaxRows()`
`int` `getMinorServerVersion()`
`void` `getMoreResults(ExecutionResult executionResult)`
`Options` `getOptions()`
`String` `getPassword()`
`boolean` `getPinGlobalTxToPhysicalConnection()`
`int` `getPort()`
`FailoverProxy` `getProxy()`
`boolean` `getReadonly()`
`void` `getResult(ExecutionResult executionResult, int resultSetScrollType, boolean binaryProtocol)`
`String` `getServerData(String code)`
`long` `getServerThreadId()`
`String` `getServerVersion()`
`int` `getTimeout()`
`int` `getTransactionIsolationLevel()`
`UrlParser` `getUrlParser()`
`String` `getUsername()`
`boolean` `hasMoreResults()`
`boolean` `hasWarnings()`
`boolean` `inTransaction()`
`boolean` `isClosed()`
`boolean` `isConnected()`
`boolean` `isExplicitClosed()`
`boolean` `isMasterConnection()`
`boolean` `mustBeMasterConnection()`
`boolean` `noBackslashEscapes()`
`boolean` `ping()`
`PrepareResult` `prepare(String sql, boolean forceNew)`
`PrepareStatementCache` `prepareStatementCache()`
`void` `prolog(ExecutionResult executionResult, int maxRows, boolean hasProxy, MariaDbConnection connection, Statement statement)`
`void` `prologProxy(PrepareResult prepareResult, ExecutionResult executionResult, int maxRows, boolean hasProxy, MariaDbConnection connection, Statement statement)`
`void` `releasePrepareStatement(PrepareResult prepareResult, String sql)`
`void` `rollback()`
`void` `setActiveStreamingResult(MariaSelectResultSet mariaSelectResultSet)`
`void` `setCatalog(String database)`
`void` `setHasWarnings(boolean hasWarnings)`
`void` `setHostAddress(HostAddress hostAddress)`
`void` `setHostFailedWithoutProxy()`
`void` `setInternalMaxRows(int max)`
`void` `setLocalInfileInputStream(InputStream inputStream)`
`void` `setMaxRows(int max)`
`void` `setMoreResults(boolean moreResults, boolean moreResultsTypeBinary)`
`void` `setProxy(FailoverProxy proxy)`
`void` `setReadonly(boolean readOnly)`
`void` `setTimeout(int timeout)`
`void` `setTransactionIsolation(int level)`
`boolean` `shouldReconnectWithoutProxy()`
`void` `skip()`
`boolean` `versionGreaterOrEqual(int major, int minor, int patch)`

### Method Detail

#### prepare

    PrepareResult prepare(String sql,
                          boolean forceNew)
                   throws QueryException

Throws:
  `QueryException`

#### getAutocommit

    boolean getAutocommit()

#### noBackslashEscapes

    boolean noBackslashEscapes()

#### connect

    void connect()
          throws QueryException

Throws:
  `QueryException`

#### getUrlParser

    UrlParser getUrlParser()

#### inTransaction

    boolean inTransaction()

#### getProxy

    FailoverProxy getProxy()

#### setProxy

    void setProxy(FailoverProxy proxy)

#### getOptions

    Options getOptions()

#### hasMoreResults

    boolean hasMoreResults()

#### close

    void close()

#### closeExplicit

    void closeExplicit()

#### isClosed

    boolean isClosed()

#### setCatalog

    void setCatalog(String database)
             throws QueryException

Throws:
  `QueryException`

#### getServerVersion

    String getServerVersion()

#### isConnected

    boolean isConnected()

#### getReadonly

    boolean getReadonly()

#### setReadonly

    void setReadonly(boolean readOnly)
              throws QueryException

Throws:
  `QueryException`

#### isMasterConnection

    boolean isMasterConnection()

#### mustBeMasterConnection

    boolean mustBeMasterConnection()

#### getHostAddress

    HostAddress getHostAddress()

#### setHostAddress

    void setHostAddress(HostAddress hostAddress)

#### getHost

    String getHost()

#### getPort

    int getPort()

#### rollback

    void rollback()

#### getDatabase

    String getDatabase()

#### getUsername

    String getUsername()

#### getPassword

    String getPassword()

#### ping

    boolean ping()
          throws QueryException

Throws:
  `QueryException`

#### executeQuery

    void executeQuery(String sql)
               throws QueryException

Throws:
  `QueryException`

#### executeQuery

    void executeQuery(ExecutionResult executionResult,
                      String sql,
                      int resultSetScrollType)
               throws QueryException

Throws:
  `QueryException`

#### executeQueries

    void executeQueries(ExecutionResult executionResult,
                        List<String> queries,
                        int resultSetScrollType)
                 throws QueryException

Throws:
  `QueryException`

#### executeQueries

    void executeQueries(ExecutionResult executionResult,
                        List<String> queryParts,
                        List<ParameterHolder[]> parameterList,
                        int resultSetScrollType,
                        boolean isRewritable)
                 throws QueryException

Throws:
  `QueryException`

#### executeQueriesRewrite

    void executeQueriesRewrite(ExecutionResult executionResult,
                               List<String> queries,
                               int resultSetScrollType,
                               boolean isRewritable,
                               int rewriteOffset)
                        throws QueryException

Throws:
  `QueryException`

#### getResult

    void getResult(ExecutionResult executionResult,
                   int resultSetScrollType,
                   boolean binaryProtocol)
            throws QueryException

Throws:
  `QueryException`

#### cancelCurrentQuery

    void cancelCurrentQuery()
                     throws QueryException,
                            IOException

Throws:
  `QueryException`
  `IOException`

#### skip

    void skip()
       throws SQLException,
              QueryException

Throws:
  `SQLException`
  `QueryException`

#### checkIfMaster

    boolean checkIfMaster()
                   throws QueryException

Throws:
  `QueryException`

#### hasWarnings

    boolean hasWarnings()

#### getDataTypeMappingFlags

    int getDataTypeMappingFlags()

#### setInternalMaxRows

    void setInternalMaxRows(int max)

#### getMaxRows

    int getMaxRows()

#### setMaxRows

    void setMaxRows(int max)
             throws QueryException

Throws:
  `QueryException`

#### getMajorServerVersion

    int getMajorServerVersion()

#### getMinorServerVersion

    int getMinorServerVersion()

#### versionGreaterOrEqual

    boolean versionGreaterOrEqual(int major,
                                  int minor,
                                  int patch)

#### setLocalInfileInputStream

    void setLocalInfileInputStream(InputStream inputStream)

#### getTimeout

    int getTimeout()
            throws SocketException

Throws:
  `SocketException`

#### setTimeout

    void setTimeout(int timeout)
             throws SocketException

Throws:
  `SocketException`

#### getPinGlobalTxToPhysicalConnection

    boolean getPinGlobalTxToPhysicalConnection()

#### getServerThreadId

    long getServerThreadId()

#### setTransactionIsolation

    void setTransactionIsolation(int level)
                          throws QueryException

Throws:
  `QueryException`

#### getTransactionIsolationLevel

    int getTransactionIsolationLevel()

#### isExplicitClosed

    boolean isExplicitClosed()

#### connectWithoutProxy

    void connectWithoutProxy()
                      throws QueryException

Throws:
  `QueryException`

#### shouldReconnectWithoutProxy

    boolean shouldReconnectWithoutProxy()

#### setHostFailedWithoutProxy

    void setHostFailedWithoutProxy()

#### executePreparedQuery

    void executePreparedQuery(PrepareResult prepareResult,
                              ExecutionResult executionResult,
                              String sql,
                              ParameterHolder[] parameters,
                              MariaDbType[] parameterTypeHeader,
                              int resultSetScrollType)
                       throws QueryException

Throws:
  `QueryException`

#### executePreparedQueryAfterFailover

    void executePreparedQueryAfterFailover(PrepareResult oldPrepareResult,
                                           ExecutionResult executionResult,
                                           String sql,
                                           ParameterHolder[] parameters,
                                           MariaDbType[] parameterTypeHeader,
                                           int resultSetScrollType)
                                    throws QueryException

Throws:
  `QueryException`

#### releasePrepareStatement

    void releasePrepareStatement(PrepareResult prepareResult,
                                 String sql)
                          throws QueryException

Throws:
  `QueryException`

#### forceReleasePrepareStatement

    void forceReleasePrepareStatement(int statementId)
                               throws QueryException

Throws:
  `QueryException`

#### prepareStatementCache

    PrepareStatementCache prepareStatementCache()

#### getServerData

    String getServerData(String code)

#### getCalendar

    Calendar getCalendar()

#### prolog

    void prolog(ExecutionResult executionResult,
                int maxRows,
                boolean hasProxy,
                MariaDbConnection connection,
                Statement statement)
         throws SQLException

Throws:
  `SQLException`

#### prologProxy

    void prologProxy(PrepareResult prepareResult,
                     ExecutionResult executionResult,
                     int maxRows,
                     boolean hasProxy,
                     MariaDbConnection connection,
                     Statement statement)
              throws SQLException

Throws:
  `SQLException`

#### getActiveStreamingResult

    MariaSelectResultSet getActiveStreamingResult()

#### setActiveStreamingResult

    void setActiveStreamingResult(MariaSelectResultSet mariaSelectResultSet)

#### getLock

    ReentrantLock getLock()

#### getMoreResults

    void getMoreResults(ExecutionResult executionResult)
                 throws QueryException

Throws:
  `QueryException`

#### setMoreResults

    void setMoreResults(boolean moreResults,
                        boolean moreResultsTypeBinary)

#### setHasWarnings

    void setHasWarnings(boolean hasWarnings)