Package org.mariadb.jdbc
Class Driver
java.lang.Object
org.mariadb.jdbc.Driver
- All Implemented Interfaces:
Driver
MariaDB Driver
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
acceptsURL
(String url) returns true if the driver can accept the url.connect
(String url, Properties props) Connect to the given connection string.static Connection
connect
(Configuration configuration) Connect according to configurationint
gets the major version of the driver.int
gets the minor version of the driver.getPropertyInfo
(String url, Properties info) Get the property info.boolean
checks if the driver is jdbc compliant.
-
Constructor Details
-
Driver
public Driver()
-
-
Method Details
-
connect
Connect according to configuration- Parameters:
configuration
- configuration- Returns:
- a Connection
- Throws:
SQLException
- if connect fails
-
connect
Connect to the given connection string.- Specified by:
connect
in interfaceDriver
- Parameters:
url
- the url to connect to- Returns:
- a connection
- Throws:
SQLException
- if it is not possible to connect
-
acceptsURL
returns true if the driver can accept the url.- Specified by:
acceptsURL
in interfaceDriver
- Parameters:
url
- the url to test- Returns:
- true if the url is valid for this driver
-
getPropertyInfo
Get the property info.- Specified by:
getPropertyInfo
in interfaceDriver
- Parameters:
url
- the url to get properties forinfo
- the info props- Returns:
- all possible connector options
- Throws:
SQLException
- if there is a problem getting the property info
-
getMajorVersion
public int getMajorVersion()gets the major version of the driver.- Specified by:
getMajorVersion
in interfaceDriver
- Returns:
- the major versions
-
getMinorVersion
public int getMinorVersion()gets the minor version of the driver.- Specified by:
getMinorVersion
in interfaceDriver
- Returns:
- the minor version
-
jdbcCompliant
public boolean jdbcCompliant()checks if the driver is jdbc compliant.- Specified by:
jdbcCompliant
in interfaceDriver
- Returns:
- true since the driver is not compliant
-
getParentLogger
- Specified by:
getParentLogger
in interfaceDriver
- Throws:
SQLFeatureNotSupportedException
-