Class C3p0ConnectionProviderPlugin
- java.lang.Object
-
- io.vertigo.database.plugins.sql.connection.AbstractSqlConnectionProviderPlugin
-
- io.vertigo.database.plugins.sql.connection.c3p0.C3p0ConnectionProviderPlugin
-
- All Implemented Interfaces:
io.vertigo.core.node.component.Activeable
,io.vertigo.core.node.component.CoreComponent
,io.vertigo.core.node.component.Plugin
,SqlConnectionProviderPlugin
,SqlConnectionProvider
public final class C3p0ConnectionProviderPlugin extends AbstractSqlConnectionProviderPlugin implements io.vertigo.core.node.component.Activeable
If there is no datasource, you have to use a simple connection provider.- See Also:
Utiliser une DataSource
-
-
Constructor Summary
Constructors Constructor Description C3p0ConnectionProviderPlugin(Optional<String> name, String dataBaseClass, String jdbcDriver, String jdbcUrl, Optional<Integer> minPoolSize, Optional<Integer> maxPoolSize, Optional<Integer> acquireIncrement, Optional<String> configName)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SqlConnection
obtainConnection()
Provides a sql connection.void
start()
void
stop()
-
Methods inherited from class io.vertigo.database.plugins.sql.connection.AbstractSqlConnectionProviderPlugin
getDataBase, getName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.vertigo.database.impl.sql.SqlConnectionProviderPlugin
checkTestSelect
-
-
-
-
Constructor Detail
-
C3p0ConnectionProviderPlugin
@Inject public C3p0ConnectionProviderPlugin(Optional<String> name, String dataBaseClass, String jdbcDriver, String jdbcUrl, Optional<Integer> minPoolSize, Optional<Integer> maxPoolSize, Optional<Integer> acquireIncrement, Optional<String> configName)
Constructor.- Parameters:
name
- the name of the connectionProviderdataBaseClass
- the type of databasejdbcDriver
- the class of the jdbc driverjdbcUrl
- the jdbc url
-
-
Method Detail
-
obtainConnection
public SqlConnection obtainConnection()
Provides a sql connection.- Specified by:
obtainConnection
in interfaceSqlConnectionProvider
- Returns:
- Connection
-
start
public void start()
- Specified by:
start
in interfaceio.vertigo.core.node.component.Activeable
-
stop
public void stop()
- Specified by:
stop
in interfaceio.vertigo.core.node.component.Activeable
-
-