public interface Driver extends AutoCloseable
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
configure(Configuration config) |
Configuration |
getConfiguration() |
default Function<String,String> |
getCypherModification() |
default ExceptionTranslator |
getExceptionTranslator()
An
ExceptionTranslator translating driver specific exception into a Neo4j-OGM api exceptions. |
Function<TransactionManager,BiFunction<Transaction.Type,Iterable<String>,Transaction>> |
getTransactionFactorySupplier() |
default TypeSystem |
getTypeSystem()
This returns the type system of the specific drivers.
|
Request |
request(Transaction transaction) |
default boolean |
requiresTransaction()
Indicates if the driver requires an explicit transaction to run queries.
|
default <T> T |
unwrap(Class<T> clazz)
Unwraps this Neo4j-OGM specific driver into it's underlying physical driver of type
T if the concrete driver's
transport is compatible with the specified class. |
void configure(Configuration config)
Function<TransactionManager,BiFunction<Transaction.Type,Iterable<String>,Transaction>> getTransactionFactorySupplier()
void close()
close in interface AutoCloseableRequest request(Transaction transaction)
transaction - Current transaction, may be null, depending on the driverConfiguration getConfiguration()
default boolean requiresTransaction()
default TypeSystem getTypeSystem()
default ExceptionTranslator getExceptionTranslator()
ExceptionTranslator translating driver specific exception into a Neo4j-OGM api exceptions.default <T> T unwrap(Class<T> clazz)
T if the concrete driver's
transport is compatible with the specified class.
A call to this method won't initialize a driver. Depending on the actual type, the underlying driver will be null
if it had not been used beforehand or Configuration.Builder#verifyConnection(Boolean) hat been set to true.
This method won't return null once the driver has been initialized until close() has been called.
T - Type of the classclazz - The class into which the driver should be unwrappedIllegalArgumentException - if this driver cannot be unwrapped into the given class.Copyright © 2015–2023 Neo Technology, Inc.. All rights reserved.