1*cdf0e10cSrcweir/************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir 28*cdf0e10cSrcweir#ifndef __com_sun_star_configuration_backend_UpdatableLayer_idl__ 29*cdf0e10cSrcweir#define __com_sun_star_configuration_backend_UpdatableLayer_idl__ 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir#ifndef __com_sun_star_configuration_backend_Layer_idl__ 32*cdf0e10cSrcweir#include <com/sun/star/configuration/backend/Layer.idl> 33*cdf0e10cSrcweir#endif 34*cdf0e10cSrcweir 35*cdf0e10cSrcweir#ifndef __com_sun_star_configuration_backend_XUpdatableLayer_idl__ 36*cdf0e10cSrcweir#include <com/sun/star/configuration/backend/XUpdatableLayer.idl> 37*cdf0e10cSrcweir#endif 38*cdf0e10cSrcweir 39*cdf0e10cSrcweir//============================================================================== 40*cdf0e10cSrcweir 41*cdf0e10cSrcweirmodule com { module sun { module star { module configuration { module backend { 42*cdf0e10cSrcweir 43*cdf0e10cSrcweir//============================================================================== 44*cdf0e10cSrcweir 45*cdf0e10cSrcweir/** 46*cdf0e10cSrcweir provides read/write access to a configuration data layer. 47*cdf0e10cSrcweir 48*cdf0e10cSrcweir <p>A layer contains the configuration setting changes to be performed 49*cdf0e10cSrcweir on a default layer (or schema) to obtain the values of those settings 50*cdf0e10cSrcweir for a given entity and component. 51*cdf0e10cSrcweir </p> 52*cdf0e10cSrcweir <p>An updatable layer can be read or replaced with another layer. 53*cdf0e10cSrcweir </p> 54*cdf0e10cSrcweir 55*cdf0e10cSrcweir @since OOo 1.1.2 56*cdf0e10cSrcweir */ 57*cdf0e10cSrcweirpublished service UpdatableLayer 58*cdf0e10cSrcweir{ 59*cdf0e10cSrcweir //-------------------------------------------------------------------------- 60*cdf0e10cSrcweir 61*cdf0e10cSrcweir /** 62*cdf0e10cSrcweir handles read access to the contents of the layer. 63*cdf0e10cSrcweir 64*cdf0e10cSrcweir <p> If the implementation supports 65*cdf0e10cSrcweir <type scope="com::sun::star::util">XTimeStamped</type>, 66*cdf0e10cSrcweir then after executing <member>XUpdatableLayer::replaceWith()</member> 67*cdf0e10cSrcweir the timestamp will be the one for the replaced contents and 68*cdf0e10cSrcweir if reading after updates is supported the next read will reproduce the 69*cdf0e10cSrcweir replaced data. 70*cdf0e10cSrcweir </p> 71*cdf0e10cSrcweir */ 72*cdf0e10cSrcweir service Layer ; 73*cdf0e10cSrcweir 74*cdf0e10cSrcweir //-------------------------------------------------------------------------- 75*cdf0e10cSrcweir 76*cdf0e10cSrcweir /** 77*cdf0e10cSrcweir provides write access to the contents of the layer. 78*cdf0e10cSrcweir 79*cdf0e10cSrcweir <p> Depending of the actual type (simple, i.e pure <type>XLayer</type> or 80*cdf0e10cSrcweir composite, i.e <type>XCompositeLayer</type>) of the current layer and 81*cdf0e10cSrcweir the provided replacement layer, the operation performed 82*cdf0e10cSrcweir by <member>XUpdatableLayer::replaceWith()</member>, will vary. 83*cdf0e10cSrcweir </p> 84*cdf0e10cSrcweir <p> For the different current/replacement layer combinations, we have: 85*cdf0e10cSrcweir <dl> 86*cdf0e10cSrcweir <dt>Simple/Simple<dt> 87*cdf0e10cSrcweir <dd>the provided layer's contents replace the current one's.</dd> 88*cdf0e10cSrcweir 89*cdf0e10cSrcweir <dt>Composite/Composite<dt> 90*cdf0e10cSrcweir <dd>all layers (main and sub) present in the 91*cdf0e10cSrcweir provided layer are used to replace the corresponding current 92*cdf0e10cSrcweir layer contents. Sublayers present in the current layer but 93*cdf0e10cSrcweir not in the provided one are left untouched. Sublayers present 94*cdf0e10cSrcweir in the provided layer but not in the current one are added to 95*cdf0e10cSrcweir the current layer. 96*cdf0e10cSrcweir </dd> 97*cdf0e10cSrcweir 98*cdf0e10cSrcweir <dt>Simple/Composite<dt> 99*cdf0e10cSrcweir <dd>the main layer and sublayers of the provided layer 100*cdf0e10cSrcweir are merged into one whose contents replace the current layer. 101*cdf0e10cSrcweir </dd> 102*cdf0e10cSrcweir 103*cdf0e10cSrcweir <dt>Composite/Simple<dt> 104*cdf0e10cSrcweir <dd>the provided layer is split into a composite one whose contents 105*cdf0e10cSrcweir are then used to replace the current layer as described above. 106*cdf0e10cSrcweir </dd> 107*cdf0e10cSrcweir 108*cdf0e10cSrcweir </dl> 109*cdf0e10cSrcweir <em> Not all implementations of <type>XUpdatableLayer</type> 110*cdf0e10cSrcweir support conversions of the replacement layer. 111*cdf0e10cSrcweir In such a case the sublayers of the provided layer may be ignored 112*cdf0e10cSrcweir or all simple data be merged into the main layer. 113*cdf0e10cSrcweir </em> 114*cdf0e10cSrcweir </p> 115*cdf0e10cSrcweir */ 116*cdf0e10cSrcweir interface XUpdatableLayer ; 117*cdf0e10cSrcweir 118*cdf0e10cSrcweir //-------------------------------------------------------------------------- 119*cdf0e10cSrcweir 120*cdf0e10cSrcweir} ; 121*cdf0e10cSrcweir 122*cdf0e10cSrcweir//============================================================================== 123*cdf0e10cSrcweir 124*cdf0e10cSrcweir} ; } ; } ; } ; } ; 125*cdf0e10cSrcweir 126*cdf0e10cSrcweir#endif 127*cdf0e10cSrcweir 128