1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: XDriverManager.idl,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef __com_sun_star_sdbc_XDriverManager_idl__
31 #define __com_sun_star_sdbc_XDriverManager_idl__
33 #ifndef __com_sun_star_uno_XInterface_idl__
34 #include
<com
/sun
/star
/uno
/XInterface.idl
>
37 #ifndef __com_sun_star_beans_PropertyValue_idl__
38 #include
<com
/sun
/star
/beans
/PropertyValue.idl
>
41 #ifndef __com_sun_star_sdbc_SQLException_idl__
42 #include
<com
/sun
/star
/sdbc
/SQLException.idl
>
45 module com
{ module sun
{ module star
{ module sdbc
{
47 published
interface XConnection
;
48 published
interface XDriver
;
51 /** is the basic interface for managing a set of SDBC drivers.
57 <member scope="com::sun::star::sdbc">XDriverManager::getConnection()</member>
59 the DriverManager will attempt to
60 locate a suitable driver.
63 @see com::sun::star::sdbc::XDriver
64 @see com::sun::star::sdbc::XConnection
66 published
interface XDriverManager
: com
::sun
::star
::uno
::XInterface
68 //-------------------------------------------------------------------------
70 /** attempts to establish a connection to the given database URL.
71 The DriverManager attempts to select an appropriate driver from
72 the set of registered JDBC/SDBC drivers.
74 a database url of the form sdbc:subprotocol:subname
78 if a database access error occurs.
80 XConnection getConnection
([in]string url
)
81 raises
(SQLException
);
82 //-------------------------------------------------------------------------
84 /** attempts to establish a connection to the given database URL.
85 The DriverManager attempts to select an appropriate driver from
86 the set of registered JDBC/SDBC drivers.
88 a database url of the form sdbc:subprotocol:subname
90 a list of arbitrary string tag/value pairs as connection arguments;
91 normally at least a "user" and "password" property should be included
92 @see com::sun::star::sdbc::ConnectionProperties
96 if a database access error occurs.
98 XConnection getConnectionWithInfo
([in]string url
,
99 [in]sequence
<com
::sun
::star
::beans
::PropertyValue
> info
)
100 raises
(SQLException
);
101 //-------------------------------------------------------------------------
103 /** sets the maximum time in seconds that a driver will wait
104 while attempting to connect to a database.
106 the login time limit in seconds
109 if a database access error occurs.
111 void setLoginTimeout
([in]long seconds
);
112 //-------------------------------------------------------------------------
114 /** gets the maximum time in seconds that a driver can wait
115 when attempting to login to a database.
117 the driver login time limit in seconds
120 if a database access error occurs.
122 long getLoginTimeout
();
125 //=============================================================================