Interface SQLConnectionFactory
-
- All Known Implementing Classes:
HikariConnectionFactory,MariaDBConnectionFactory,MySQLConnectionFactory,PostgreSQLConnectionFactory
public interface SQLConnectionFactoryRepresents a SQL connection factory, for maintaining different connection types.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()Closes the connection factory, closing all the alive connectionsvoidconnect()Connects to the remote server.ConnectiongetConnection()Retrieves connection to the connected remote server / file.
-
-
-
Method Detail
-
connect
void connect()
Connects to the remote server.
-
getConnection
Connection getConnection() throws SQLException
Retrieves connection to the connected remote server / file.- Returns:
- connection
- Throws:
SQLException- if something wrong occurs
-
close
void close()
Closes the connection factory, closing all the alive connections
-
-