| Constructor and Description |
|---|
PlatformFactory() |
| Modifier and Type | Method and Description |
|---|---|
static Platform |
createNewPlatformInstance(DataSource dataSource)
Creates a new platform for the specified database.
|
static Platform |
createNewPlatformInstance(DataSource dataSource,
String username,
String password)
Creates a new platform for the specified database.
|
static Platform |
createNewPlatformInstance(String databaseName)
Creates a new platform for the given (case insensitive) database name
or returns null if the database is not recognized.
|
static Platform |
createNewPlatformInstance(String jdbcDriver,
String jdbcConnectionUrl)
Creates a new platform for the specified database.
|
static String[] |
getSupportedPlatforms()
Returns a list of all supported platforms.
|
static boolean |
isPlatformSupported(String platformName)
Determines whether the indicated platform is supported.
|
static void |
registerPlatform(String platformName,
Class platformClass)
Registers a new platform.
|
public static Platform createNewPlatformInstance(String databaseName) throws DdlUtilsException
databaseName - The name of the database (case is not important)null if the database is not supportedDdlUtilsExceptionpublic static Platform createNewPlatformInstance(String jdbcDriver, String jdbcConnectionUrl) throws DdlUtilsException
PlatformUtils.determineDatabaseType(String, String) to determine the parameter
for createNewPlatformInstance(String). Note that no database connection is
established when using this method.jdbcDriver - The jdbc driverjdbcConnectionUrl - The connection urlnull if the database is not supportedDdlUtilsExceptionpublic static Platform createNewPlatformInstance(DataSource dataSource) throws DdlUtilsException
PlatformUtils.determineDatabaseType(DataSource) to determine the parameter
for createNewPlatformInstance(String). Note that this method sets the data source
at the returned platform instance (method Platform.setDataSource(DataSource)).dataSource - The data source for the databasenull if the database is not supportedDdlUtilsExceptionpublic static Platform createNewPlatformInstance(DataSource dataSource, String username, String password) throws DdlUtilsException
PlatformUtils.determineDatabaseType(DataSource) to determine the parameter
for createNewPlatformInstance(String). Note that this method sets the data source
at the returned platform instance (method Platform.setDataSource(DataSource)).dataSource - The data source for the databaseusername - The user name to use for connecting to the databasepassword - The password to use for connecting to the databasenull if the database is not supportedDdlUtilsExceptionpublic static String[] getSupportedPlatforms()
public static boolean isPlatformSupported(String platformName)
platformName - The name of the platformtrue if the platform is supportedCopyright © 2010-2015 Pivotal Software, Inc. All rights reserved.