Interface DatabaseAPI.ConnectedWithResult<T>
- Type Parameters:
T
- The type of the result of the code.
- Enclosing interface:
- DatabaseAPI
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public static interface DatabaseAPI.ConnectedWithResult<T>
Some code that may be run within a transaction that returns a result and
which will be given a new connection for the duration.
-
Method Summary
Modifier and Type Method Description T
act(DatabaseAPI.Connection connection)
The operation to run.
-
Method Details
-
act
The operation to run.- Parameters:
connection
- The newly-created connection. Do not save beyond the scope of this action.- Returns:
- The result of the operation.
-