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: XLayerImporter.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_configuration_backend_XLayerImporter_idl__
31 #define __com_sun_star_configuration_backend_XLayerImporter_idl__
33 #ifndef __com_sun_star_uno_XInterface_idl__
34 #include
<com
/sun
/star
/uno
/XInterface.idl
>
37 #ifndef __com_sun_star_configuration_backend_XLayer_idl__
38 #include
<com
/sun
/star
/configuration
/backend
/XLayer.idl
>
41 #ifndef __com_sun_star_configuration_backend_XBackend_idl__
42 #include
<com
/sun
/star
/configuration
/backend
/XBackend.idl
>
45 #ifndef __com_sun_star_configuration_backend_MalformedDataException_idl__
46 #include
<com
/sun
/star
/configuration
/backend
/MalformedDataException.idl
>
48 #ifndef __com_sun_star_lang_NullPointerException_idl__
49 #include
<com
/sun
/star
/lang
/NullPointerException.idl
>
51 #ifndef __com_sun_star_lang_IllegalArgumentException_idl__
52 #include
<com
/sun
/star
/lang
/IllegalArgumentException.idl
>
54 #ifndef __com_sun_star_lang_WrappedTargetException_idl__
55 #include
<com
/sun
/star
/lang
/WrappedTargetException.idl
>
58 //=============================================================================
60 module com
{ module sun
{ module star
{ module configuration
{ module backend
{
62 //=============================================================================
64 /** allows importing a layer into a <type>Backend</type>
68 published
interface XLayerImporter
: ::com
::sun
::star
::uno
::XInterface
70 //-------------------------------------------------------------------------
72 /** gets the target backend for importing.
75 the <type>Backend</type> into which layers are
76 imported by <member>XLayerImporter::importLayer()<member/>.
79 XBackend getTargetBackend
();
81 //-------------------------------------------------------------------------
83 /** sets the target backend for importing.
86 a <type>Backend</type> into which layers should be
87 imported by <method>XLayerImporter::importLayer()<method/>.
89 @throws com::sun::star::lang::NullPointerException
90 if the backend passed is <NULL/>.
92 void setTargetBackend
([in] XBackend aBackend
)
93 raises
(com
::sun
::star
::lang
::NullPointerException
) ;
95 //-------------------------------------------------------------------------
97 /** Imports the layer given into the backend.
99 <p>This method imports data for the current entity of the backend.</p>
102 a layer whose data will be imported into the backend
104 @throws com::sun::star::lang::NullPointerException
105 if the layer passed is <NULL/> or no backend is available.
107 @throws com::sun::star::configuration::backend::MalformedDataException
108 if the layer passed is invalid
110 @throws com::sun::star::lang::IllegalArgumentException
111 if the layer passed is for a component
112 that doesn't exist in the backend
114 @throws com::sun::star::lang::WrappedTargetException
115 if an error occurs in the backend or source layer.
117 @see com::sun::star::configuration::backend::XBackend::getOwnUpdateHandler()
119 void importLayer
([in] XLayer aLayer
)
120 raises
(MalformedDataException
,
121 com
::sun
::star
::lang
::IllegalArgumentException
,
122 com
::sun
::star
::lang
::NullPointerException
,
123 com
::sun
::star
::lang
::WrappedTargetException
) ;
125 //-------------------------------------------------------------------------
127 /** Imports the layer given into the backend for a given entity.
129 <p>This method imports data for the current entity of the backend.</p>
132 a layer whose data will be imported into the backend
135 a entity into whose data the layer will be imported
137 @throws com::sun::star::lang::NullPointerException
138 if the layer passed is <NULL/> or no backend is available.
140 @throws com::sun::star::configuration::backend::MalformedDataException
141 if the layer passed is invalid
143 @throws com::sun::star::lang::IllegalArgumentException
144 if the layer passed is for a component
145 that doesn't exist in the backend
146 or if the entity doesn't exist in the backend.
148 @throws com::sun::star::lang::WrappedTargetException
149 if an error occurs in the backend or source layer.
151 @see com::sun::star::configuration::backend::XBackend::getUpdateHandler()
153 void importLayerForEntity
([in] XLayer aLayer
, [in] string aEntity
)
154 raises
(MalformedDataException
,
155 com
::sun
::star
::lang
::IllegalArgumentException
,
156 com
::sun
::star
::lang
::NullPointerException
,
157 com
::sun
::star
::lang
::WrappedTargetException
) ;
159 //-------------------------------------------------------------------------
162 //=============================================================================