Interface SqlClient<T>
- Type Parameters:
T- the original
- All Superinterfaces:
Client<T>
- All Known Implementing Classes:
H2Client,HikariSqlClient,JavaSqlClient
The interface for SQL client
-
Method Summary
Modifier and TypeMethodDescriptiondefault BatchBuildercreateBatchBuilder(String statement) Create a new batch builder for this clientdefault BatchBuildercreateBatchBuilderUnsafe(String statement) Create a new batch builder for this clientdefault StatementBuilderCreate a new statement builder for this clientdefault StatementBuilderCreate a new statement builder for this clientGet the connectionMethods inherited from interface io.github.projectunified.craftdatabase.Client
getOriginal, getSetting
-
Method Details
-
getConnection
Get the connection- Returns:
- the connection
- Throws:
SQLException- if there is an SQL error
-
createStatementBuilder
Create a new statement builder for this client- Returns:
- the statement builder
- Throws:
SQLException- if there is an SQL error
-
createStatementBuilderUnsafe
Create a new statement builder for this client- Returns:
- the statement builder
- Throws:
IllegalStateException- if there is an SQL error
-
createBatchBuilder
Create a new batch builder for this client- Parameters:
statement- the statement- Returns:
- the batch builder
- Throws:
SQLException- if there is an SQL error
-
createBatchBuilderUnsafe
Create a new batch builder for this client- Parameters:
statement- the statement- Returns:
- the batch builder
- Throws:
IllegalStateException- if there is an SQL error
-