1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef __com_sun_star_sdbc_XDriverManager_idl__
20 #define __com_sun_star_sdbc_XDriverManager_idl__
22 #include
<com
/sun
/star
/uno
/XInterface.idl
>
24 #include
<com
/sun
/star
/beans
/PropertyValue.idl
>
26 #include
<com
/sun
/star
/sdbc
/SQLException.idl
>
28 module com
{ module sun
{ module star
{ module sdbc
{
30 published
interface XConnection
;
31 published
interface XDriver
;
34 /** is the basic interface for managing a set of SDBC drivers.
40 com::sun::star::sdbc::XDriverManager::getConnection()
42 the DriverManager will attempt to
43 locate a suitable driver.
46 @see com::sun::star::sdbc::XDriver
47 @see com::sun::star::sdbc::XConnection
49 published
interface XDriverManager
: com
::sun
::star
::uno
::XInterface
52 /** attempts to establish a connection to the given database URL.
53 The DriverManager attempts to select an appropriate driver from
54 the set of registered JDBC/SDBC drivers.
56 a database url of the form sdbc:subprotocol:subname
60 if a database access error occurs.
62 XConnection getConnection
([in]string url
)
63 raises
(SQLException
);
65 /** attempts to establish a connection to the given database URL.
66 The DriverManager attempts to select an appropriate driver from
67 the set of registered JDBC/SDBC drivers.
69 a database url of the form sdbc:subprotocol:subname
71 a list of arbitrary string tag/value pairs as connection arguments;
72 normally at least a "user" and "password" property should be included
73 @see com::sun::star::sdbc::ConnectionProperties
77 if a database access error occurs.
79 XConnection getConnectionWithInfo
([in]string url
,
80 [in]sequence
<com
::sun
::star
::beans
::PropertyValue
> info
)
81 raises
(SQLException
);
83 /** sets the maximum time in seconds that a driver will wait
84 while attempting to connect to a database.
86 the login time limit in seconds
89 if a database access error occurs.
91 void setLoginTimeout
([in]long seconds
);
93 /** gets the maximum time in seconds that a driver can wait
94 when attempting to login to a database.
96 the driver login time limit in seconds
99 if a database access error occurs.
101 long getLoginTimeout
();
109 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */