Modifier and Type | Field and Description |
---|---|
static MSSQLDriver |
INSTANCE |
Constructor and Description |
---|
MSSQLDriver() |
Modifier and Type | Method and Description |
---|---|
boolean |
acceptsOptions(SqlConnectOptions options) |
int |
appendQueryPlaceholder(StringBuilder queryBuilder,
int index,
int current)
Append a parameter placeholder in the
query . |
ConnectionFactory |
createConnectionFactory(Vertx vertx,
SqlConnectOptions database)
Create a connection factory to the given
database . |
ConnectionFactory |
createConnectionFactory(Vertx vertx,
java.util.function.Supplier<? extends Future<? extends SqlConnectOptions>> database)
Create a connection factory to the given
database . |
Pool |
newPool(Vertx vertx,
java.util.function.Supplier<? extends Future<? extends SqlConnectOptions>> databases,
PoolOptions options,
io.vertx.core.impl.CloseFuture closeFuture)
Create a connection pool to the database configured with the given
connectOptions and poolOptions . |
MSSQLConnectOptions |
parseConnectionUri(String uri) |
io.vertx.sqlclient.impl.SqlConnectionInternal |
wrapConnection(io.vertx.core.impl.ContextInternal context,
ConnectionFactory factory,
io.vertx.sqlclient.impl.Connection conn) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createPool, createPool, newPool
public static final MSSQLDriver INSTANCE
public Pool newPool(Vertx vertx, java.util.function.Supplier<? extends Future<? extends SqlConnectOptions>> databases, PoolOptions options, io.vertx.core.impl.CloseFuture closeFuture)
Driver
connectOptions
and poolOptions
.
This method is not meant to be used directly by users, instead they should use Driver.createPool(Vertx, List, PoolOptions)
.public MSSQLConnectOptions parseConnectionUri(String uri)
parseConnectionUri
in interface Driver
true
if the driver accepts the connectOptions
, false
otherwisepublic boolean acceptsOptions(SqlConnectOptions options)
acceptsOptions
in interface Driver
connectOptions
, false otherwisepublic ConnectionFactory createConnectionFactory(Vertx vertx, SqlConnectOptions database)
Driver
database
.createConnectionFactory
in interface Driver
vertx
- the Vertx instance tdatabase
- the database to connect topublic ConnectionFactory createConnectionFactory(Vertx vertx, java.util.function.Supplier<? extends Future<? extends SqlConnectOptions>> database)
Driver
database
.createConnectionFactory
in interface Driver
vertx
- the Vertx instance tdatabase
- the database to connect topublic int appendQueryPlaceholder(StringBuilder queryBuilder, int index, int current)
Driver
query
.
The index starts at 0
.
index == current
indicates it is a new parameter and therefore the same
* value should be returned.index < current
indicates the builder wants to reuse a parameter.
The implementation can either return the same value to indicate the parameter can be reused or
return the next index to use (which is shall be the current
valueappendQueryPlaceholder
in interface Driver
queryBuilder
- the builder to append toindex
- the parameter placeholder indexpublic io.vertx.sqlclient.impl.SqlConnectionInternal wrapConnection(io.vertx.core.impl.ContextInternal context, ConnectionFactory factory, io.vertx.sqlclient.impl.Connection conn)
wrapConnection
in interface Driver
Copyright © 2024 Eclipse. All rights reserved.