Class H2Connection
java.lang.Object
io.r2dbc.h2.H2Connection
- All Implemented Interfaces:
Closeable,Connection
An implementation of
Connection for connecting to an H2 database.-
Method Summary
Modifier and TypeMethodDescriptionbeginTransaction(TransactionDefinition definition) close()createSavepoint(String name) createStatement(String sql) booleanreleaseSavepoint(String name) setAutoCommit(boolean autoCommit) setLockWaitTimeout(Duration duration) setStatementTimeout(Duration duration) setTransactionIsolationLevel(IsolationLevel isolationLevel) validate(ValidationDepth depth) Validates the connection according to the givenValidationDepth.
-
Method Details
-
beginTransaction
- Specified by:
beginTransactionin interfaceConnection
-
beginTransaction
- Specified by:
beginTransactionin interfaceConnection
-
close
-
commitTransaction
- Specified by:
commitTransactionin interfaceConnection
-
createBatch
- Specified by:
createBatchin interfaceConnection
-
createSavepoint
- Specified by:
createSavepointin interfaceConnection
-
createStatement
- Specified by:
createStatementin interfaceConnection
-
getTransactionIsolationLevel
- Specified by:
getTransactionIsolationLevelin interfaceConnection
-
getMetadata
- Specified by:
getMetadatain interfaceConnection
-
isAutoCommit
public boolean isAutoCommit()- Specified by:
isAutoCommitin interfaceConnection
-
releaseSavepoint
- Specified by:
releaseSavepointin interfaceConnection
-
rollbackTransaction
- Specified by:
rollbackTransactionin interfaceConnection
-
rollbackTransactionToSavepoint
- Specified by:
rollbackTransactionToSavepointin interfaceConnection
-
setAutoCommit
- Specified by:
setAutoCommitin interfaceConnection
-
setLockWaitTimeout
- Specified by:
setLockWaitTimeoutin interfaceConnection
-
setStatementTimeout
- Specified by:
setStatementTimeoutin interfaceConnection
-
setTransactionIsolationLevel
- Specified by:
setTransactionIsolationLevelin interfaceConnection
-
validate
Validates the connection according to the givenValidationDepth.- Specified by:
validatein interfaceConnection- Parameters:
depth- the validation depth- Returns:
- a
Publisherthat indicates whether the validation was successful - Throws:
IllegalArgumentException- ifdepthisnull
-