Package de.smartsquare.squit.db
Class ConnectionCollection
-
- All Implemented Interfaces:
-
java.lang.AutoCloseable
public final class ConnectionCollection implements AutoCloseable
Data structure for holding Connection objects with auto close capabilities.
The connections are held in a HashMap keyed by the jdbc address, username and password triple.
-
-
Constructor Summary
Constructors Constructor Description ConnectionCollection()
-
Method Summary
Modifier and Type Method Description final ConnectioncreateOrGet(String jdbc, String username, String password)Creates a new Connection or returns an existing one, based on the passed jdbc address, username and password. Unitclose()-
-
Method Detail
-
createOrGet
final Connection createOrGet(String jdbc, String username, String password)
Creates a new Connection or returns an existing one, based on the passed jdbc address, username and password.
-
-
-
-