| Modifier and Type | Field and Description |
|---|---|
| private int | |
| private PrintWriter | |
| private final String | |
| private final String | |
| private final String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Connection | Returns: the ConnectionImplements javax. |
| public Connection | Returns: the Connectionthe database user on whose behalf the connection is
being made username, final String the user's password password)Implements javax. |
| public int | Returns: the login timeImplements javax. |
| public PrintWriter | Returns: the LogWriterImplements javax. |
| public void | setLoginTimeout(final int
the loging timeout in seconds loginTimeout)Implements javax. |
| public void | setLogWriter(final PrintWriter
the new log writer; to disable logging, set to null logWriter)Implements javax. Sets the log writer for this |
| m_loginTimeout | back to summary |
|---|---|
| private int m_loginTimeout | |
| m_logWriter | back to summary |
|---|---|
| private PrintWriter m_logWriter | |
| m_password | back to summary |
|---|---|
| private final String m_password | |
| m_url | back to summary |
|---|---|
| private final String m_url | |
| m_username | back to summary |
|---|---|
| private final String m_username | |
| DefaultDataSource | back to summary |
|---|---|
| public DefaultDataSource(final String url, final String username, final String password) | |
| getConnection | back to summary |
|---|---|
| public Connection getConnection() throws SQLException Implements javax. Attempt to establish a database connection.
| |
| getConnection | back to summary |
|---|---|
| public Connection getConnection(final String username, final String password) throws SQLException Implements javax. Attempt to establish a database connection.
| |
| getLoginTimeout | back to summary |
|---|---|
| public int getLoginTimeout() throws SQLException Implements javax. Gets the maximum time in seconds that this data source can wait while attempting to connect to a database.
| |
| getLogWriter | back to summary |
|---|---|
| public PrintWriter getLogWriter() throws SQLException Implements javax. Get the log writer for this data source.
| |
| setLoginTimeout | back to summary |
|---|---|
| public void setLoginTimeout(final int loginTimeout) throws SQLException Implements javax. Sets the maximum time in seconds that this data source will wait while attempting to connect to a database.
| |
| setLogWriter | back to summary |
|---|---|
| public void setLogWriter(final PrintWriter logWriter) throws SQLException Implements javax. Doc from javax. Sets the log writer for this The log writer is a character output stream to which all logging
and tracing messages for this data source will be
printed. This includes messages printed by the methods of this
object, messages printed by methods of other objects manufactured
by this object, and so on. Messages printed to a data source-
specific log writer are not printed to the log writer associated
with the
| |