| java.lang.Object org.geotools.data.AbstractDataStoreFactory org.geotools.data.mysql.MySQLDataStoreFactory
MySQLDataStoreFactory | public class MySQLDataStoreFactory extends AbstractDataStoreFactory (Code) | | Creates a MySQLDataStoreFactory based on the correct params.
This factory should be registered in the META-INF/ folder, under services/
in the DataStoreFactorySpi file.
author: Andrea Aime, University of Modena and Reggio Emilia |
Method Summary | |
public boolean | canProcess(Map params) Checks to see if all the postgis params are there.
Should have:
-
dbtype: equal to postgis
-
host
-
user
-
passwd
-
database
Parameters: params - Set of parameters needed for a postgis data store. | public DataStore | createDataStore(Map params) Construct a postgis data store using the params.
Parameters: params - The full set of information needed to construct a livedata source. | public DataStore | createNewDataStore(Map params) Postgis cannot create a new database. | public static ManageableDataSource | getDefaultDataSource(String host, String user, String passwd, int port, String database, int maxActive, int minIdle, boolean validate) | public String | getDescription() Describe the nature of the datasource constructed by this factory.
A human readable description that is suitable for inclusion in alist of available datasources. | public String | getDisplayName() | public Map | getImplementationHints() Returns the implementation hints. | public Param[] | getParametersInfo() Describe parameters. | public boolean | isAvailable() Test to see if this datastore is available, if it has all the
appropriate libraries to construct a datastore. |
DATABASE | final static Param DATABASE(Code) | | Param, package visibiity for JUnit tests
|
DBTYPE | final static Param DBTYPE(Code) | | Param, package visibiity for JUnit tests
|
HOST | final static Param HOST(Code) | | Param, package visibiity for JUnit tests
|
MAXCONN | final static Param MAXCONN(Code) | | |
MINCONN | final static Param MINCONN(Code) | | |
NAMESPACE | final static Param NAMESPACE(Code) | | Param, package visibiity for JUnit tests
|
PASSWD | final static Param PASSWD(Code) | | Param, package visibiity for JUnit tests
|
PORT | final static Param PORT(Code) | | Param, package visibiity for JUnit tests
|
USER | final static Param USER(Code) | | Param, package visibiity for JUnit tests
|
VALIDATECONN | final static Param VALIDATECONN(Code) | | |
WKBENABLED | final public static Param WKBENABLED(Code) | | |
arrayParameters | final static Param[] arrayParameters(Code) | | Array with all of the params
|
MySQLDataStoreFactory | public MySQLDataStoreFactory()(Code) | | Creates a new instance of PostgisDataStoreFactory
|
canProcess | public boolean canProcess(Map params)(Code) | | Checks to see if all the postgis params are there.
Should have:
-
dbtype: equal to postgis
-
host
-
user
-
passwd
-
database
Parameters: params - Set of parameters needed for a postgis data store. true if dbtype equals postgis, and contains keysfor host, user, passwd, and database. |
createDataStore | public DataStore createDataStore(Map params) throws IOException(Code) | | Construct a postgis data store using the params.
Parameters: params - The full set of information needed to construct a livedata source. Should have dbtype equal to postgis, as well ashost, user, passwd, database, and table. The created DataSource, this may be null if the requiredresource was not found or if insufficent parameters were given.Note that canProcess() should have returned false if theproblem is to do with insuficent parameters. throws: IOException - See DataSourceException throws: DataSourceException - Thrown if there were any problems creatingor connecting the datasource. |
getDescription | public String getDescription()(Code) | | Describe the nature of the datasource constructed by this factory.
A human readable description that is suitable for inclusion in alist of available datasources. Currently uses the string "MySQL Database" |
getImplementationHints | public Map getImplementationHints()(Code) | | Returns the implementation hints. The default implementation returns en empty map.
|
isAvailable | public boolean isAvailable()(Code) | | Test to see if this datastore is available, if it has all the
appropriate libraries to construct a datastore. This datastore just
returns true for now. This method is used for gui apps, so as to not
advertise data store capabilities they don't actually have.
true if and only if this factory is available to createDataStores. |
|
|