Top   Module   Use   Manual   Index 
 EXPORTING SERVICES | METHODS' SUMMARY | METHODS' DETAILS 

com :: sun :: star :: sdbc ::

interface XDriverManager

Base Interface
com::sun::star::uno::XInterface

Description
is the basic interface for managing a set of SDBC drivers.

When the method XDriverManager::getConnection() is called, the DriverManager will attempt to locate a suitable driver.

See also
com::sun::star::sdbc::XDriver
See also
com::sun::star::sdbc::XConnection


Known Services which Export this Interface

com::sun::star::sdbc::ConnectionPool is the basic service for pooling SDBC connections.
com::sun::star::sdbc::DriverManager is the basic service for managing a set of SDBC drivers.

Methods' Summary

getConnection attempts to establish a connection to the given database URL. The DriverManager attempts to select an appropriate driver from the set of registered JDBC/SDBC drivers.
getConnectionWithInfo attempts to establish a connection to the given database URL. The DriverManager attempts to select an appropriate driver from the set of registered JDBC/SDBC drivers.
setLoginTimeout sets the maximum time in seconds that a driver will wait while attempting to connect to a database.
getLoginTimeout gets the maximum time in seconds that a driver can wait when attempting to login to a database.

Methods' Details

getConnection
 
com::sun::star::sdbc::XConnection
getConnection(
[ in ] string url )
raises ( com::sun::star::sdbc::SQLException );

Description
attempts to establish a connection to the given database URL. The DriverManager attempts to select an appropriate driver from the set of registered JDBC/SDBC drivers.
Parameter url
a database url of the form sdbc:subprotocol:subname
Returns
the Connection object
Throws
SQLException if a database access error occurs.
getConnectionWithInfo
 
com::sun::star::sdbc::XConnection
getConnectionWithInfo(
[ in ] string url,
[ in ] sequence< com::sun::star::beans::PropertyValue > info )
raises ( com::sun::star::sdbc::SQLException );

Description
attempts to establish a connection to the given database URL. The DriverManager attempts to select an appropriate driver from the set of registered JDBC/SDBC drivers.
Parameter url
a database url of the form sdbc:subprotocol:subname
Parameter info
a list of arbitrary string tag/value pairs as connection arguments; normally at least a "user" and "password" property should be included
Returns
the Connection object
Throws
SQLException if a database access error occurs.
setLoginTimeout
 
void
setLoginTimeout(
[ in ] long seconds );

Description
sets the maximum time in seconds that a driver will wait while attempting to connect to a database.
Parameter seconds
the login time limit in seconds
Throws
SQLException if a database access error occurs.
getLoginTimeout
 
long
getLoginTimeout();
Description
gets the maximum time in seconds that a driver can wait when attempting to login to a database.
Returns
the driver login time limit in seconds
Throws
SQLException if a database access error occurs.

Top of Page