leon.peer.sql.mysql
Class LyMySqlConnection
java.lang.Object
leon.peer.LyConnection
leon.peer.sql.LySqlConnection
leon.peer.sql.mysql.LyMySqlConnection
public class LyMySqlConnection
- extends LySqlConnection
This class is used as a connection for MySql relational database.
- See Also:
LySqlConnection
Field Summary |
static java.lang.String |
__VERSION
|
Method Summary |
java.util.Properties |
getProperties()
To get properties of the connection before opening it. |
boolean |
open(java.lang.String username,
java.lang.String password)
Open the physical connection to the database. |
boolean |
open(java.lang.String username,
java.lang.String password,
java.lang.String driverName)
Open the physical connection to the database. |
Methods inherited from class leon.peer.sql.LySqlConnection |
autoCommit, close, commit, getConnection, getMetaData, getStatement, handleError, released, rollback, sendQueryRequest, sendQueryRequest, sendUpdateRequest, setStatementTimeout |
Methods inherited from class leon.peer.LyConnection |
addValue, dump, getError, getUID, getValue, isClosed, isReserved, prepareCommit, reserved, setDataProvider, setError, setUID |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
__VERSION
public static final java.lang.String __VERSION
- See Also:
- Constant Field Values
LyMySqlConnection
public LyMySqlConnection(LyApplication application,
java.lang.String name,
java.lang.String databaseName)
- Constructor.
- Parameters:
application
- The application of this connectionname
- Name of the connectiondatabaseName
- Name of the database.
LyMySqlConnection
public LyMySqlConnection(LyApplication application,
java.lang.String name,
javax.sql.DataSource dataSource,
java.lang.String databaseName)
- Constructor.
- Parameters:
application
- Application of the data provider that manages this connection.name
- Name of the database.dataSource
- JDBC DataSource providing the JDBC connection.databaseName
- Name of the database.
getProperties
public java.util.Properties getProperties()
- To get properties of the connection before opening it.
- Overrides:
getProperties
in class LySqlConnection
- Returns:
- Properties of this connection used to open it.
open
public boolean open(java.lang.String username,
java.lang.String password)
- Open the physical connection to the database.
- Overrides:
open
in class LySqlConnection
- Parameters:
username
- user id.password
- user password.
- Returns:
- true : connection established, false : connection refused
open
public boolean open(java.lang.String username,
java.lang.String password,
java.lang.String driverName)
- Open the physical connection to the database.
- Overrides:
open
in class LySqlConnection
- Parameters:
username
- user id.password
- user password.driverName
- The driver class name.
- Returns:
- true : connection established, false : connection refused
Website: W4 S.A., contact us: support@w4global.com