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: XAuthorizable.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_sdbcx_XAuthorizable_idl__
31 #define __com_sun_star_sdbcx_XAuthorizable_idl__
33 #ifndef __com_sun_star_uno_XInterface_idl__
34 #include
<com
/sun
/star
/uno
/XInterface.idl
>
37 #ifndef __com_sun_star_sdbc_SQLException_idl__
38 #include
<com
/sun
/star
/sdbc
/SQLException.idl
>
41 module com
{ module sun
{ module star
{ module sdbcx
{
43 /** is used for accessing and setting the permissions of a user for a database
45 @see com::sun::star::sdbcx::PrivilegeObject
47 published
interface XAuthorizable
: com
::sun
::star
::uno
::XInterface
50 /** retrieves the permissions for a specific object.
52 the name of the object
55 <type scope="com::sun::star::sdbcx">PrivilegeObject</Type>
58 @throws com::sun::star::sdbc::SQLException
59 if a database access error occurs.
61 long getPrivileges
([in]string objName
, [in]long objType
) raises
62 (com
::sun
::star
::sdbc
::SQLException
);
63 //-------------------------------------------------------------------------
65 /** retrieves the permissions for a specific object, which could be granted
66 to other users and groups.
68 the name of the object
71 <type scope="com::sun::star::sdbcx">PrivilegeObject</Type>
74 @throws com::sun::star::sdbc::SQLException
75 if a database access error occurs.
77 long getGrantablePrivileges
([in]string objName
, [in]long objType
) raises
78 (com
::sun
::star
::sdbc
::SQLException
);
79 //-------------------------------------------------------------------------
81 /** adds additional permissions for a specific object.
83 the name of the object
85 a value from the <type scope="com::sun::star::sdbcx">PrivilegeObject</type> constants group
86 @throws com::sun::star::sdbc::SQLException
87 if a database access error occurs.
89 void grantPrivileges
([in]string objName
, [in]long objType
,
90 [in]long objPrivileges
) raises
91 (com
::sun
::star
::sdbc
::SQLException
);
92 //-------------------------------------------------------------------------
94 /** removes permissions for a specific object from a group or user.
96 the name of the object
98 a value from the <type scope="com::sun::star::sdbcx">PrivilegeObject</type> constants group
99 @throws com::sun::star::sdbc::SQLException
100 if a database access error occurs.
102 void revokePrivileges
([in]string objName
, [in]long objType
,
103 [in]long objPrivileges
) raises
104 (com
::sun
::star
::sdbc
::SQLException
);
107 //=============================================================================
111 /*===========================================================================
112 ===========================================================================*/