Class MySQLDriver
- All Implemented Interfaces:
Driver<MySQLConnectOptions>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanacceptsOptions(SqlConnectOptions options) createConnectionFactory(Vertx vertx, NetClientOptions transportOptions) Create a connection factory to the givendatabase.downcast(SqlConnectOptions connectOptions) Downcast the connect options to the specific driver options.protected PoolnewPool(io.vertx.core.internal.VertxInternal vertx, Handler<SqlConnection> connectHandler, Supplier<Future<MySQLConnectOptions>> databases, PoolOptions poolOptions, NetClientOptions transportOptions, io.vertx.core.internal.CloseFuture closeFuture) parseConnectionUri(String uri) io.vertx.sqlclient.internal.SqlConnectionInternalwrapConnection(io.vertx.core.internal.ContextInternal context, ConnectionFactory<MySQLConnectOptions> factory, Connection connection) Wrap a givenconnectioninto aSqlConnectionInternal.Methods inherited from class DriverBase
newPoolMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Driver
appendQueryPlaceholder, createPool
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
MySQLDriver
public MySQLDriver()
-
-
Method Details
-
downcast
Description copied from interface:DriverDowncast the connect options to the specific driver options.- Parameters:
connectOptions- the options to downcast- Returns:
- the downcasted options
-
newPool
protected Pool newPool(io.vertx.core.internal.VertxInternal vertx, Handler<SqlConnection> connectHandler, Supplier<Future<MySQLConnectOptions>> databases, PoolOptions poolOptions, NetClientOptions transportOptions, io.vertx.core.internal.CloseFuture closeFuture) - Overrides:
newPoolin classDriverBase<MySQLConnectOptions>
-
parseConnectionUri
- Returns:
trueif the driver accepts theconnectOptions,falseotherwise
-
acceptsOptions
- Returns:
- true if the driver accepts the
connectOptions, false otherwise
-
createConnectionFactory
public ConnectionFactory<MySQLConnectOptions> createConnectionFactory(Vertx vertx, NetClientOptions transportOptions) Description copied from class:DriverBaseCreate a connection factory to the givendatabase.- Specified by:
createConnectionFactoryin classDriverBase<MySQLConnectOptions>- Parameters:
vertx- the Vertx instancetransportOptions- the options to configure the TCP client- Returns:
- the connection factory
-
wrapConnection
public io.vertx.sqlclient.internal.SqlConnectionInternal wrapConnection(io.vertx.core.internal.ContextInternal context, ConnectionFactory<MySQLConnectOptions> factory, Connection connection) Description copied from class:DriverBaseWrap a givenconnectioninto aSqlConnectionInternal. The default implementation wraps with a genericSqlConnectionBase.- Overrides:
wrapConnectionin classDriverBase<MySQLConnectOptions>- Parameters:
context- the connection contextfactory- the connection factoryconnection- the connection to wrap- Returns:
- the wrapped connection
-