Class SqlDataSourceScriptDatabaseInitializer
java.lang.Object
org.springframework.boot.sql.init.AbstractScriptDatabaseInitializer
org.springframework.boot.jdbc.init.DataSourceScriptDatabaseInitializer
org.springframework.boot.autoconfigure.sql.init.SqlDataSourceScriptDatabaseInitializer
- All Implemented Interfaces:
Aware
,InitializingBean
,ResourceLoaderAware
DataSourceScriptDatabaseInitializer
for the primary SQL database. May be
registered as a bean to override auto-configuration.- Since:
- 2.6.0
- Author:
- Andy Wilkinson, Phillip Webb
-
Constructor Summary
ConstructorDescriptionSqlDataSourceScriptDatabaseInitializer
(DataSource dataSource, SqlInitializationProperties properties) Create a newSqlDataSourceScriptDatabaseInitializer
instance.SqlDataSourceScriptDatabaseInitializer
(DataSource dataSource, DatabaseInitializationSettings settings) Create a newSqlDataSourceScriptDatabaseInitializer
instance. -
Method Summary
Methods inherited from class org.springframework.boot.jdbc.init.DataSourceScriptDatabaseInitializer
customize, getDataSource, isEmbeddedDatabase, runScripts
Methods inherited from class org.springframework.boot.sql.init.AbstractScriptDatabaseInitializer
afterPropertiesSet, initializeDatabase, setResourceLoader
-
Constructor Details
-
SqlDataSourceScriptDatabaseInitializer
public SqlDataSourceScriptDatabaseInitializer(DataSource dataSource, SqlInitializationProperties properties) Create a newSqlDataSourceScriptDatabaseInitializer
instance.- Parameters:
dataSource
- the primary SQL data sourceproperties
- the SQL initialization properties- See Also:
-
SqlDataSourceScriptDatabaseInitializer
public SqlDataSourceScriptDatabaseInitializer(DataSource dataSource, DatabaseInitializationSettings settings) Create a newSqlDataSourceScriptDatabaseInitializer
instance.- Parameters:
dataSource
- the primary SQL data sourcesettings
- the database initialization settings- See Also:
-
-
Method Details
-
getSettings
- Parameters:
properties
- the SQL initialization properties- Returns:
- a new
DatabaseInitializationSettings
instance - See Also:
-