From ed5640d8b587fbcfed7dd7967f3de04b37a76f26 Mon Sep 17 00:00:00 2001
From: Daniel Baumann Provides information about the element and the whole hierarchy.
+ Allows controlling the lifetime of the hierarchy.
+ Allows observing changes in the hierarchy as a whole.
+ When access to a hierarchy is first obtained from a factory or provider,
+ this is the initial object that is created by the factory.
+ It represents the root of the accessible part of the hierarchy.
+ NOTE: In this description "hierarchy" may actually
+ designate a part or fragment of a larger hierarchy. It is that part that is
+ rooted in the element represented by an implementation of this service
+ and that is accessible starting from this element.
+ Generally it is not possible to navigate the parent or siblings, if any,
+ of this element, so com::sun::star::container::XChild is
+ not supported.
+ The owner of the hierarchy may dispose of this object
+ using com::sun::star::lang::XComponent::dispose().
+ As this object owns its child elements and, recursively, the whole hierarchy,
+ any descendant elements obtained, directly or indirectly, from this object
+ will also be disposed. Disposing of the object does not affect a persistent
+ representation of the hierarchy.
+ When an implementation is obtained from a factory or provider, ownership
+ of it is usually transferred to the client. See the documentation
+ of the particular provider or factory service for details.
+ The provider of this object may still dispose of this object, when the
+ lifetime of the provider ends or if these objects represent
+ the root of only a fragment of an enclosing hierarchy and
+ this fragment is removed from the complete hierarchy by an outside source.
+ Clients may register a com::sun::star::lang::XEventListener
+ to be notified when the object is disposed for either cause.
+ A client can register an
+ com::sun::star::util::XChangesListener,
+ which will receive notifications for any changes within the
+ hierarchy (fragment) this object represents.
+ An implementation will collect as many changes as possible into a single
+ com::sun::star::util::ChangesEvent. For Example:
+
+ If com::sun::star::beans::XMultiPropertySet::setPropertyValues()
+ or com::sun::star::beans::XMultiHierarchicalPropertySet::setHierarchicalPropertyValues()
+ is used on an element of the hierarchy to change multiple values within
+ the hierarchy, all changes will be notified with a single event.
+ If an outside source uses
+ com::sun::star::util::XChangesBatch::commitChanges()
+ on an overlapping hierarchy access, all relevant changes will be notified
+ with a single event.
+ This interface may be missing if the implementation does not support
+ locale-dependent data in the hierarchy or if the (partial) hierarchy rooted
+ in this object does not contain any locale-dependent elements.
+ Changing the locale is generally not supported. If it is supported,
+ there is no guarantee that values already loaded into the hierarchy, or an
+ application cache, are refreshed to reflect the new locale. Use of
+ com::sun::star::lang::XLocalizable::setLocale()
+ is therefore not recommended.
+ Shared sets of configuration data usually serve to provide defaults,
+ which are used if no individual settings are present. Depending on the data
+ store multiple layers of defaults may be combined with a user-specific layer
+ to make up the final configuration.
+ Many aspects of the supported behavior depend strongly on the underlying
+ data store and on the administrative structures it defines. With some data
+ stores this service also enables access to individual user's configuration
+ data by an administrator.
+ On the other hand, in the simplest model there is only a single layer of
+ default data which is accessible through this service.
+ An implementation is usually obtained from a
+ com::sun::star::lang::ServiceManager. The arguments passed to
+ com::sun::star::lang::XMultiComponentFactory::createInstanceWithArgumentsAndContext()
+ select the configuration data source. They may also define the scope of
+ administrable data or contain credentials to be used to authorize the
+ administrative access. Missing parameters may be filled in
+ from the context or the environment.
+ A ConfigurationProvider provides access to the personal
+ layer of configuration data of the current user context. It should in
+ most cases be used when using the configuration data, although
+ for most contexts an AdministrationProvider can be used as
+ a drop-in replacement.
+ The parameter aServiceSpecifier passed to
+ com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments()
+ supports at least the service specifiers
+ Using the first of these service specifiers requests a read-only view of
+ the configuration.
+ The object that is created implements service ConfigurationAccess.
+ To reflect its element role as root of the view, it implements
+ service AccessRootElement.
+ Using the second form requests an updatable view of the configuration.
+ The object that is created should implement service
+ ConfigurationUpdateAccess. To reflect its element role
+ which includes controlling updates for the whole view, it implements
+ service UpdateRootElement.
+ The arguments passed to
+ com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments()
+ in parameter aArguments specify the administrative entity for which
+ data should be administered. In other words they determine the layer to which
+ changes will apply. They also specify the view of that configuration that
+ should be created. That is, they determine the subset of elements that can be
+ accessed starting from the returned object. Each element of the argument
+ sequence should be a com::sun::star::beans::PropertyValue
+ or a com::sun::star::beans::NamedValue,
+ so that the parameters can be identified by name rather than by position.
+ What combinations of arguments are supported depends on the service name
+ and on the data store being administered.
+ With both of the standard service-specifiers above, an implementation must
+ accept a single argument named Other arguments can be used to select a more specific entity and to control
+ the behavior of the view. These are different for different implementations
+ and data stores. Whether and how they are used may also depend on properties
+ that were selected when the provider was created.
+ An implementation may ignore unknown arguments. Some parameters that are commonly supported are described for service
+ ConfigurationProvider.
+ One notable difference exists for parameter com::sun::star::lang::XMultiServiceFactory::createInstance()
+ may be unusable. Only an implementation that supports service names that can be
+ used with no further arguments support this method. It should return the
+ same result as if
+ com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments()
+ had been called using an empty sequence of arguments.
+ The owner of the provider may dispose of this object
+ using com::sun::star::lang::XComponent::dispose().
+ Views created by the provider generally refer to data that is managed by
+ the provider. Therefore, disposing of the provider will cause all objects
+ belonging to these views to be disposed of as well. This does not apply to
+ snapshot views that have their own copy of the data, if available.
+ Values that are direct or indirect descendants of a root element can be
+ retrieved and, if themselves objects, navigated. Other interfaces provide
+ access to information about this element and its context.
+ Changes to values in the hierarchy can be monitored by event listeners.
+ Descendants of this service also implement this service.
+ Ultimately the configuration holds values. These values are organized into
+ a hierarchy using structural elements. The structure is defined in advance in
+ a schema. Necessary information from the schema is stored in the configuration
+ repository itself and is accessible through an implementation of this service.
+ Two different kinds of structural elements are used in the configuration
+ hierarchy:
+ Objects in the configuration hierarchy, for example, implementations of this service,
+ can thus be classified in the following ways:
+ Several types of simple values can be used in the configuration.
+ In addition to the basic (scalar) types, sequences of the basic types are
+ supported. The basic types are:
+ Values are represented as `string`. Sequences are represented as `string[]`. "human-readable" here excludes non-printing characters
+ except for CR, LF and TAB [Unicode code points 9,10,13].
+ For binary data, use type binary instead. Values are represented as `boolean`.
+ Sequences are represented as `boolean[]`. Values are represented as `short`. Sequences are represented as `short[]`. Values are represented as `long`. Sequences are represented as `long[]`. Values are represented as `hyper`. Sequences are represented as `hyper[]`. Values are represented as `double`. Sequences are represented as `double[]`. Values are represented as `byte[]`. Sequences are represented as `byte[][]`. Within templates an additional type any can occur. When
+ such a template is used to create a new SetElement, the type
+ of the element is initially reported as `any` (having no value).
+ When the value of such an element is first set, it will assume the type used.
+ If the schema marks a value as nullable (which is indicated by
+ attribute com::sun::star::beans::PropertyAttribute::MAYBEVOID ),
+ its contents may be `NULL`.
+ The configuration should support explicit access to default values
+ (implementing com::sun::star::beans::XPropertyState
+ and com::sun::star::beans::XPropertyWithState).
+ An implementation actually implements a specialization of this service,
+ which depends on its Container role.
+ Implementations shall implement exactly one of: An implementation actually implements a specialization of this service,
+ which depends on its Element role.
+ Implementations shall implement exactly one of: This is an alternative to GroupAccess.
+ This is an alternative to SetAccess.
+ This is an alternative to SetElement
+ or GroupElement.
+ This is an alternative to AccessRootElement
+ or GroupElement.
+ This is an alternative to AccessRootElement
+ or SetElement.
+ An implementation is usually obtained from a
+ com::sun::star::lang::ServiceManager. The arguments passed to
+ com::sun::star::lang::XMultiComponentFactory::createInstanceWithArgumentsAndContext()
+ select the configuration data source. Arguments must be provided as
+ com::sun::star::beans::NamedValue
+ or com::sun::star::beans::PropertyValue.
+ If the parameters given are incomplete missing values are taken
+ from the context or the environment. If an instance already exists for the
+ given set of arguments, the existing instance may be reused.
+ In particular, instantiating a provider without explicit arguments to access
+ the default configuration data will always yield the same
+ com::sun::star::configuration::DefaultProvider object.
+ Some arguments for
+ com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments()
+ may be given default values during creation of this service. In particular
+ this applies to the parameters The parameter aServiceSpecifier passed to
+ com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments()
+ supports at least the service specifiers
+ Using the first of these service specifiers requests a read-only view of
+ the configuration.
+ The object that is created implements service ConfigurationAccess.
+ To reflect its element role as root of the view, it implements
+ service AccessRootElement.
+ Using the second form requests an updatable view of the configuration.
+ The object that is created should implement service
+ ConfigurationUpdateAccess. To reflect its element role
+ which includes controlling updates for the whole view, it implements
+ service UpdateRootElement.
+ The arguments passed to
+ com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments()
+ in parameter aArguments specify the view of the configuration that
+ should be created. That is, they determine the subset of elements that can be
+ accessed starting from the returned object. Each element of the argument
+ sequence should be a com::sun::star::beans::PropertyValue
+ or a com::sun::star::beans::NamedValue,
+ so that the parameters can be identified by name rather than by position.
+ What combinations of arguments are supported depends on the service name.
+ With both of the standard service-specifiers above, an implementation must
+ accept a single argument named Other arguments can be used to control the behavior of the view. These
+ are different for different implementations. Whether and how they are used
+ may also depend on the configuration store and configuration that were
+ selected when the provider was created.
+ An implementation must ignore unknown arguments. Some parameters that are commonly supported are: Example: In the hierarchy
+"com.sun.star.configuration.ConfigurationAccess"
and
+ "com.sun.star.configuration.ConfigurationUpdateAccess"
.
+
If the root element of the view is marked read-only (as indicated
+ by com::sun::star::beans::PropertyAttributes::READONLY),
+ the implementation may either raise an exception or return a (read-only)
+ ConfigurationAccess/AccessRootElement instead.
+ nodepath
of type `string`.
+ This argument must contain the absolute path to an element of the
+ configuration. The view that is selected consists of the named element and
+ all its descendants. The administrative entity is the default for the
+ AdministrationProvider. Usually this is the largest entity
+ encompassing all entities accessible from this instance. In other words this
+ can be used to influence as global a scope as possible.
+ "Locale"
. For a
+ ConfigurationProvider the default behavior usually is to select
+ the locale set up for the user. But this service by default gets data for all
+ locales for which data is present. Locale-dependent values in this case are
+ replaced by a SetAccess using the language names as accessors.
+ This also allows targeted setting of values for selected locales.
+ This behavior can be requested explicitly by specifying a special argument
+ value locale = "*"
.
+
+
+
+
+
+
+
+
+
+
+
+ */
+ service HierarchyAccess;
+
+ /** provides interfaces to obtain information about this element and its
+ role and context in the hierarchy.
+
+
+
+
+ */
+ service HierarchyElement;
+
+ /** specializes HierarchyAccess, if this element is a Set.
+
+ "Locale"
and "EnableAsync"
.
+ "com.sun.star.configuration.ConfigurationAccess"
and
+ "com.sun.star.configuration.ConfigurationUpdateAccess"
.
+
If the root element of the view is marked read-only (as indicated
+ by com::sun::star::beans::PropertyAttributes::READONLY),
+ the implementation may either raise an exception or return a (read-only)
+ ConfigurationAccess/AccessRootElement instead.
+ nodepath
of type `string`.
+ This argument must contain the absolute path to an element of the
+ configuration. The view that is selected consists of the named element and
+ all its descendants.
+
+
+
+
+ "nodepath"
: `string`"depth"
: `short`"locale"
: com::sun::star::lang::Locale
+ A - B1 - C1
+ |
+ - B2 - C2 (localized: de, en, fr, ..)
+ | |
+ | - C3 - D1
+ | | |
+ | | - D2 - E1
+ | |
+ | - C4 - D3 - E2 - F1
+ | | |
+ | | - F2
+ | |
+ | - C5
+ |
+ - B3
+ |
+ - B4 - C6 - D4 - E3
+
+
+
selecting a view with nodepath = "/A/B2"
,
+ depth = 2
and locale = <Locale for en_US>
+ would result in the tree fragment
+
+(A-) B2 - C2 (en)
+ |
+ - C3 - D1
+ | |
+ | - D2 (..)
+ |
+ - C4 - D3 (..)
+ |
+ - C5
+
+
+
"enableasync"
: `boolean`This parameter was formerly called "lazywrite"
.
+ The old name should still be supported for compatibility.
+
"nocache"
: `boolean`This parameter is not supported by all implementations and may be + silently ignored ! +
+com::sun::star::lang::XMultiServiceFactory::createInstance() + may be unusable. Only an implementation that supports service names that can be + used with no further arguments support this method. It should return the + same result as if + com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments() + had been called using an empty sequence of arguments. +
+*/ + interface com::sun::star::lang::XMultiServiceFactory; + + +/** allows controlling or observing the lifetime of the configuration. + +The owner of the provider may dispose of this object + using com::sun::star::lang::XComponent::dispose(). + Note that the default provider is owned by the + com::sun::star::lang::ServiceManager and should not be + disposed of by user code. +
+ +Views created by the provider generally refer to data that is managed by + the provider. Therefore, disposing of the provider will cause all objects + belonging to these views to be disposed of as well. This does not apply to + snapshot views that have their own copy of the data, if available. +
+ +*/ + interface com::sun::star::lang::XComponent; + +}; + + +}; }; }; }; + +#endif + + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/ConfigurationRegistry.idl b/offapi/com/sun/star/configuration/ConfigurationRegistry.idl new file mode 100644 index 000000000..2773a1782 --- /dev/null +++ b/offapi/com/sun/star/configuration/ConfigurationRegistry.idl @@ -0,0 +1,93 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_ConfigurationRegistry_idl__ +#define __com_sun_star_configuration_ConfigurationRegistry_idl__ + + +#includeThis service is deprecated, + com.sun.star.configuration::ConfigurationProvider should + be used instead.
+ +Using the com::sun::star::registry::XSimpleRegistry + interface, the service can be bound to a subtree within the + configuration tree, as provided by an + com.sun.star.configuration::ConfigurationProvider + service, which must be accessible from the service factory you use for the + creation of this service. +
+There are some restrictions when accessing a configuration tree using a registry. + Most of them are implications of the fact that a configuration tree is very static in + it's structure. Removal and addition of sub nodes is allowed only for special + nodes, and even then the new elements have to comply to a given scheme (which is some + kind of attribute of the container node). So for instance the + com.sun.star.registry::XRegistryKey::createKey() method is not allowed + for some nodes. +
+ Thus anybody using this service is strongly advised to read and understand the specification + of a configuration provider (com.sun.star.configuration::ConfigurationProvider) + and all of its aspects. +
+ + @version 1.0 2000/07/06 +*/ + +published service ConfigurationRegistry +{ + /** controls the binding of the object to a configuration sub tree. +com::sun::star::registry::XSimpleRegistry::open() + is used to open a special subtree within the configuration tree. +
+The parameters of this method control the location of the root of the to-be-opened + configuration node and the access mode (read only or updatable). +
+ */ + interface com::sun::star::registry::XSimpleRegistry; + + /** is used to commit changes to the configuration. +As specified for the + com::sun::star::configuration::ConfigurationUpdateAccess + service, all changes made to a configuration subtree have to be committed + before they become persistent. + To do this for a configuration accessed as a registry, call + com::sun::star::util::XFlushable::flush(). +
+Warning:Changes that are not flushed will be + lost. +
+ */ + interface com::sun::star::util::XFlushable; +}; + + + +}; }; }; }; + + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/ConfigurationUpdateAccess.idl b/offapi/com/sun/star/configuration/ConfigurationUpdateAccess.idl new file mode 100644 index 000000000..7d151349d --- /dev/null +++ b/offapi/com/sun/star/configuration/ConfigurationUpdateAccess.idl @@ -0,0 +1,123 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_ConfigurationUpdateAccess_idl__ +#define __com_sun_star_configuration_ConfigurationUpdateAccess_idl__ + +#includeExtends ConfigurationAccess to support modifying values + or inserting and removing elements. +
+ +Descendants of this service also implement this service + unless they are marked read-only (which is indicated by attribute + com::sun::star::beans::PropertyAttribute::READONLY), + in which case they only need implement ConfigurationAccess. +
+ +The classification of implementations that is described for + ConfigurationAccess applies to implementations of this service + as well. Therefore an implementation will support one of several alternate + services describing its Container role and one of several alternate + services describing its Element role. These services are + extensions of the respective services documented for ConfigurationAccess. +
+The HierarchyAccess specialization implemented will be + further specialized to support modifying access. + Implementations shall therefore implement one of SetUpdate or + GroupUpdate depending on the Container role. +
+ +If the HierarchyElement specialization that is implemented + is AccessRootElement, the implementation must support the + extended functionality of UpdateRootElement. Otherwise, there + are no new requirements mandated by the Element role. +
+ + */ + service ConfigurationAccess; + + /** specializes SetAccess to support modifying the element. + +Implemented, if this element is a Set. + Otherwise service GroupUpdate is provided. +
+ */ + [optional] service SetUpdate; + + /** specializes GroupAccess to support modifying contained + data. + +Implemented, if this element is a Group. + Otherwise service SetUpdate is provided. +
+ */ + [optional] service GroupUpdate; + + /** specializes AccessRootElement to support transaction-like + control over a batch of changes accumulated within the tree fragment. + +Implemented, if this element is the Root of the whole hierarchy. + Otherwise either SetElement or GroupElement is provided. +
+ + @see ConfigurationProvider + Instances obtained from a ConfigurationProvider will + implement this version of HierarchyElement. + */ + [optional] service UpdateRootElement; +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/CorruptedConfigurationException.idl b/offapi/com/sun/star/configuration/CorruptedConfigurationException.idl new file mode 100644 index 000000000..2beab78e2 --- /dev/null +++ b/offapi/com/sun/star/configuration/CorruptedConfigurationException.idl @@ -0,0 +1,50 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_CorruptedConfigurationException_idl__ +#define __com_sun_star_configuration_CorruptedConfigurationException_idl__ + +#includeThis object is accessible as singleton + theDefaultProvider
. + + @since OOo 1.1.2 +*/ +published service DefaultProvider +{ + + /** characterizes the functionality. + */ + service ConfigurationProvider ; + + /**Provides refresh capabilities, data can be refreshed from the backend(s) into + the in-memory cache. + */ + [optional] interface com::sun::star::util::XRefreshable; + + /** Enables the data to be flushed from the in-memory cache to the backend(s). + */ + [optional] interface com::sun::star::util::XFlushable; + + /** Enable setting/getting locale for Provider + + @since OOo 2.0 + */ + + [optional] interface com::sun::star::lang::XLocalizable; + + /** Property to enable/disable asynchronous write-back from in-memory cache to backend(s) + + @since OOo 2.0 + */ + + [optional,property] boolean EnableAsync; + +} ; + + +} ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/GroupAccess.idl b/offapi/com/sun/star/configuration/GroupAccess.idl new file mode 100644 index 000000000..d0305fe90 --- /dev/null +++ b/offapi/com/sun/star/configuration/GroupAccess.idl @@ -0,0 +1,122 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_GroupAccess_idl__ +#define __com_sun_star_configuration_GroupAccess_idl__ + +#includeProvides access to, and information about, its children and descendants + viewed either as properties or as contained elements. +
+ +Groups are static collections within the hierarchy.
+ +The number and names of contained elements are fixed in advance + and each child may have a different type. +
+ +This service subsumes two alternate ways of accessing child and descendent
+ elements. These strongly overlap, supporting the basic identity
+ xGroup.getPropertyValue( aName ) == xGroup.getByName( aName )
.
+
This view is meaningful only for a static fragment of the hierarchy + Object's properties may change, but not which properties they have. + Therefore, dynamic elements of the hierarchy (see SetAccess) + do not implement service PropertyHierarchy. +
+ +If such elements occur as properties or subproperties of an implementation, + it is not specified whether direct subproperty access using + com::sun::star::beans::XHierarchicalPropertySet or + com::sun::star::beans::XMultiHierarchicalPropertySet can + be used to access descendants of such elements. +
+ +Similarly, information about such descendants may not be available from + the com::sun::star::beans::XHierarchicalPropertySetInfo + the implementation provides. +
+ +If an implementation is part of a read-only view of the hierarchy, + all properties and subproperties will be reported as having attribute + com::sun::star::beans::PropertyAttribute::READONLY set, + and attempts to change property values will fail. +
+*/ + service PropertyHierarchy; + +/** provides access to the state of child elements of an implementation. [optional] + +This interface should be present, if the hierarchy supports default values + for simple (non-object) properties and the group contains such properties. +
+ +For properties that are objects themselves, the semantic documented for + service HierarchyAccess applies. +
+ */ + [optional] interface com::sun::star::beans::XPropertyState; + +/** provides access to the states of multiple child elements of + an implementation. [optional] + +This interface should be present, if the hierarchy supports default values + for simple (non-object) properties and the group contains such properties. +
+ +For properties that are objects themselves, the semantic documented for + service HierarchyAccess applies. +
+*/ + [optional] interface com::sun::star::beans::XMultiPropertyStates; +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/GroupElement.idl b/offapi/com/sun/star/configuration/GroupElement.idl new file mode 100644 index 000000000..e6bd88e77 --- /dev/null +++ b/offapi/com/sun/star/configuration/GroupElement.idl @@ -0,0 +1,74 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_GroupElement_idl__ +#define __com_sun_star_configuration_GroupElement_idl__ + +#includeProvides information about the element. + Provides access to its containing group object. +
+ +A group element bears a predefined name. It may only exist within a + containing group object. +
+ + @see com::sun::star::configuration::GroupAccess + Parent objects of this service generally implement service GroupAccess. + + @see com::sun::star::configuration::SetElement + A complementary service, for elements of a dynamic homogeneous container. + + @see com::sun::star::configuration::AccessRootElement + A complementary service, for the root element of a hierarchy. + +*/ +published service GroupElement +{ +/** is the basic service for accessing information about an element in the + hierarchy. +*/ + service HierarchyElement; + +/** provides access to the containing group object. + +In this service this interface is mandatory
+ +com::sun::star::container::XChild::getParent() + shall not return NULL. +
+ +Setting a different parent is not supported.
+*/ + interface com::sun::star::container::XChild; +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/GroupUpdate.idl b/offapi/com/sun/star/configuration/GroupUpdate.idl new file mode 100644 index 000000000..c8cff5c09 --- /dev/null +++ b/offapi/com/sun/star/configuration/GroupUpdate.idl @@ -0,0 +1,78 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_GroupUpdate_idl__ +#define __com_sun_star_configuration_GroupUpdate_idl__ + +#includeThis service extends GroupAccess to support + modifying values. +
+*/ +published service GroupUpdate +{ +/** is the basic service providing read access to a group element of the + hierarchy. + +Any child and descendant objects support modifying access as well, + unless they represent a read-only tree element as indicated by + com::sun::star::beans::PropertyAttribute::READONLY. +
+*/ + service GroupAccess; + +/** allows replacing values. + +This service extends the interface
+ com::sun::star::container::XNameAccess supported
+ by service GroupAccess to allow changing values.
+ This strongly overlaps with functionality available through
+ PropertyHierarchy (from GroupAccess), so that
+ xGroup.setPropertyValue( aName, aValue )
is equivalent to
+ xGroup.replaceByName( aName, aValue )
.
+
Changes can be observed by registering a listener with interface + com::sun::star::beans::XPropertySet or + com::sun::star::beans::XMultiPropertySet. +
+ +Elements of this group may be replaced only if they are of simple type. + The type returned by + com::sun::star::container::XElementAccess::getElementType() + must not be an interface type. Replacing whole subtrees is not supported. +
+*/ + interface com::sun::star::container::XNameReplace; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/HierarchyAccess.idl b/offapi/com/sun/star/configuration/HierarchyAccess.idl new file mode 100644 index 000000000..5ed58f861 --- /dev/null +++ b/offapi/com/sun/star/configuration/HierarchyAccess.idl @@ -0,0 +1,158 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_HierarchyAccess_idl__ +#define __com_sun_star_configuration_HierarchyAccess_idl__ + +#includeSubnodes are accessed by their name. Values that are direct or indirect + descendants of this tree node can be retrieved. Non-value subnodes can be + navigated using container interfaces. + Other interfaces provide access to information about this node. + Changes to values in the subtree can be monitored by event listeners. +
+ +Elements of this container that are not simple values + are similar containers themselves, thus (recursively) forming a + hierarchical tree. +
+ +Implementations of this service usually also implement + service HierarchyElement, which concerns the complementary role + of being accessible as an element of the hierarchy. +
+*/ +published service HierarchyAccess +{ +/** allows access to immediate children of this node. + +com::sun::star::container::XNameAccess::getByName() + returns an `any` holding either a simple value or an interface + on another HierarchyAccess if the child is not a simple value. +
+*/ + interface com::sun::star::container::XNameAccess; + +/** allows access to all descendants of this node + +com::sun::star::container::XHierarchicalNameAccess::getByHierarchicalName() + returns an `any` holding either a simple value or an interface + on another HierarchyAccess if the descendant is not a simple value. +
+*/ + interface com::sun::star::container::XHierarchicalNameAccess; + +/** allows attaching listeners to this node to monitor changes to immediate child nodes. +*/ + interface com::sun::star::container::XContainer; + +/** provides support for inexact names. +Exact names can be obtained for simple or hierarchical names for use in + com::sun::star::container::XNameAccess, + com::sun::star::container::XHierarchicalNameAccess, + com::sun::star::beans::XPropertySet or + any other interfaces that allow access to or manipulation of subnodes + selected by name or hierarchical name. +
+If an inexact name could be matched to either a simple or a hierarchical + name, the simple (immediate child) name is preferred. +
+*/ + interface com::sun::star::beans::XExactName; + +/** provides information about immediate children of this node. [optional] + +This interface may be missing, if the hierarchy supports no traits that are + described by com::sun::star::beans::PropertyAttribute + values or if the same information is available by other means, + e.g. if the implementation supports + com::sun::star::beans::XPropertySet::getPropertySetInfo(). +
+ +If a child of this node is an object that implements + com::sun::star::beans::XProperty, then this implementation + returns the same com::sun::star::beans::Property for that + child as the child itself. +
+*/ + [optional] interface com::sun::star::beans::XPropertySetInfo; + +/** provides access to the state of child elements of an implementation. [optional] + +This interface may be missing if the hierarchy (or a hierarchy fragment + that contains this implementation as element) does not support default values or + if the node does not support accessing the default state of individual children. +
+ +If elements that are not simple values, but objects themselves, support + a default state (as indicated by + com::sun::star::beans::PropertyAttribute::MAYBEDEFAULT), + they should implement + com::sun::star::beans::XPropertyWithState, in which case + the com::sun::star::beans::PropertyState applies to all + their children and recursively to all descendants. +
+ +If an implementation is part of a read-only view of the hierarchy, + attempts to change property states will fail. +
+*/ + [optional] interface com::sun::star::beans::XPropertyState; + +/** provides access to the states of multiple child elements of + an implementation. [optional] + +This interface may be missing if the hierarchy (or a hierarchy fragment + that contains this implementation as element) does not support default values + if the node does not support accessing the default state of individual children. +
+ +If elements that are not simple values, but objects themselves, support + a default state (as indicated by + com::sun::star::beans::PropertyAttribute::MAYBEDEFAULT), + they should implement + com::sun::star::beans::XPropertyWithState, in which case + the com::sun::star::beans::PropertyState applies to all + their children and recursively to all descendants. +
+ +If an implementation is part of a read-only view of the hierarchy, + attempts to change property states will fail. +
+*/ + [optional] interface com::sun::star::beans::XMultiPropertyStates; +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/HierarchyElement.idl b/offapi/com/sun/star/configuration/HierarchyElement.idl new file mode 100644 index 000000000..5f7485713 --- /dev/null +++ b/offapi/com/sun/star/configuration/HierarchyElement.idl @@ -0,0 +1,109 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_HierarchyElement_idl__ +#define __com_sun_star_configuration_HierarchyElement_idl__ + +#includeThe local name and the full hierarchical name can be retrieved. + Attributes detailing the role of the element can be queried. + The state of the element (regarding defaults) can be accessed. +
+ +Implementations of this service usually also implement + service HierarchyAccess, which concerns the complementary role + of providing access to subelements of the hierarchy. +
+*/ +published service HierarchyElement +{ +/** provides the complete hierarchical name of this element + within the hierarchy tree. +*/ + interface com::sun::star::container::XHierarchicalName; + +/** provides the local name of this element within its parent. + +Renaming an element is generally not supported.
+*/ + interface com::sun::star::container::XNamed; + +/** provides a property descriptor for this element.[optional] + +This interface may be missing, if the hierarchy supports no traits that are + described by com::sun::star::beans::PropertyAttribute + values. +
+ +If the parent of this object implements + com::sun::star::beans::XPropertySetInfo, then this returns + the same com::sun::star::beans::Property as the + com::sun::star::beans::XPropertySetInfo of the parent. +
+*/ + [optional] interface com::sun::star::beans::XProperty; + +/** provides access to the default state of this element. [optional] + +This interface may be missing, if the hierarchy supports access to + a default state and values only for simple values or not at all. +
+ +If the parent of this object implements + com::sun::star::beans::XPropertyState, then members + of this interface have the same effect as corresponding members of the parent. +
+ +If an implementation is part of a read-only view of the hierarchy, + attempts to change property states will fail. +
+*/ + [optional] interface com::sun::star::beans::XPropertyWithState; + +/** provides access to the parent of this element [optional]. + +This interface may be missing if this object is not obtained + as a child or descendant of another tree node, for example, directly from a factory or provider. +
+ +com::sun::star::container::XChild::getParent() + returns NULL, if this object is currently not contained in another node. +
+ +Setting a different parent is, generally, not supported.
+*/ + [optional] interface com::sun::star::container::XChild; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/InstallationIncompleteException.idl b/offapi/com/sun/star/configuration/InstallationIncompleteException.idl new file mode 100644 index 000000000..6674f035c --- /dev/null +++ b/offapi/com/sun/star/configuration/InstallationIncompleteException.idl @@ -0,0 +1,40 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_InstallationIncompleteException_idl__ +#define __com_sun_star_configuration_InstallationIncompleteException_idl__ + +#includeProperties in a property set may be full-fledged objects that have + properties themselves (and so on recursively), thereby forming a hierarchy + of properties. This service describes such a hierarchy, and allows + direct access even to subproperties. +
+ + @see com::sun::star::beans::XProperty + Properties of an implementation that are objects themselves will often + implement com::sun::star::beans::XProperty to allow + direct access to information about the object. + If such objects have properties of their own, they should fully implement + PropertyHierarchy again. +*/ +published service PropertyHierarchy +{ +/** provides access to and information about the immediate properties of an implementation. +*/ + interface com::sun::star::beans::XPropertySet; + +/** provides access to and information about the immediate properties + of an implementation. + +This interface allows retrieving or setting multiple properties at once. + Accesses are guaranteed to occur as single atomic operations even if + multiple threads are accessing the object simultaneously. +
+*/ + interface com::sun::star::beans::XMultiPropertySet; + +/** provides access to and information about the whole hierarchy + of properties and subproperties of an implementation. +*/ + interface com::sun::star::beans::XHierarchicalPropertySet; + +/** provides access to and information about the whole hierarchy + of properties and subproperties of an implementation. + +This interface allows retrieving or setting multiple properties at once. + Accesses are guaranteed to occur as single atomic operations even if + multiple threads are accessing the object simultaneously. +
+*/ + interface com::sun::star::beans::XMultiHierarchicalPropertySet; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/ReadOnlyAccess.idl b/offapi/com/sun/star/configuration/ReadOnlyAccess.idl new file mode 100644 index 000000000..b2ad08c4a --- /dev/null +++ b/offapi/com/sun/star/configuration/ReadOnlyAccess.idl @@ -0,0 +1,36 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#ifndef _COM_SUN_STAR_CONFIGURATION_READONLYACCESS_IDL +#define _COM_SUN_STAR_CONFIGURATION_READONLYACCESS_IDL + +#includeThis service is still unpublished and unstable.
+ + @since LibreOffice 4.0 +*/ +service ReadOnlyAccess: com::sun::star::container::XHierarchicalNameAccess { + /** Service constructor. + + @param locale a string representation of the locale to use for localized + properties; use*
for all-locale access
+ */
+ create([in] string locale);
+};
+
+}; }; }; };
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/offapi/com/sun/star/configuration/ReadWriteAccess.idl b/offapi/com/sun/star/configuration/ReadWriteAccess.idl
new file mode 100644
index 000000000..7b376f90f
--- /dev/null
+++ b/offapi/com/sun/star/configuration/ReadWriteAccess.idl
@@ -0,0 +1,36 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#ifndef _COM_SUN_STAR_CONFIGURATION_READWRITEACCESS_IDL
+#define _COM_SUN_STAR_CONFIGURATION_READWRITEACCESS_IDL
+
+#include This service is still unpublished and unstable.
+ + @since LibreOffice 4.0 +*/ +service ReadWriteAccess: com::sun::star::configuration::XReadWriteAccess { + /** Service constructor. + + @param locale a string representation of the locale to use for localized + properties; use*
for all-locale access
+ */
+ create([in] string locale);
+};
+
+}; }; }; };
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/offapi/com/sun/star/configuration/SetAccess.idl b/offapi/com/sun/star/configuration/SetAccess.idl
new file mode 100644
index 000000000..e1560b8c0
--- /dev/null
+++ b/offapi/com/sun/star/configuration/SetAccess.idl
@@ -0,0 +1,88 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef __com_sun_star_configuration_SetAccess_idl__
+#define __com_sun_star_configuration_SetAccess_idl__
+
+#include Also provides information about the template for elements. + Allows normalizing externally generated names. +
+ +Sets are dynamic containers within the hierarchy.
+ +The number and names of contained elements are not fixed in advance, + but all elements have to be of one predetermined type. +
+ + @see com::sun::star::configuration::SetElement + Child objects of this service generally implement SetElement. + The template name returned by the child from + XTemplateInstance::getTemplateName() + corresponds to the name returned by the set from + XTemplateContainer::getElementTemplateName(). + + @see com::sun::star::configuration::GroupAccess + A complementary service that provides for static heterogeneous groups of + elements within the hierarchy. + +*/ +published service SetAccess +{ +/** is the basic service for accessing child and descendent nodes in a hierarchy. + +External names (from foreign namespaces) should be normalized using + com::sun::star::util::XStringEscape::escapeString() + (if available) before using them as element names. +
+*/ + service HierarchyAccess; + +/** is the basic service providing information about and access to elements + of a not necessarily hierarchical set. + +Interface com::sun::star::configuration::XTemplateContainer, + which is optional in SimpleSetAccess must always be implemented + in this service, if the elements are of object type.
+*/ + service SimpleSetAccess; + +/** allows attaching listeners to this node to monitor changes to the set. + +In this service, support for notifications is mandatory. +
+*/ + interface com::sun::star::container::XContainer; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/SetElement.idl b/offapi/com/sun/star/configuration/SetElement.idl new file mode 100644 index 000000000..6260020d7 --- /dev/null +++ b/offapi/com/sun/star/configuration/SetElement.idl @@ -0,0 +1,166 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_SetElement_idl__ +#define __com_sun_star_configuration_SetElement_idl__ + +#includeProvides information about the element. + Provides access to its containing set object. + Allows controlling the lifetime of the element. +
+ +Set elements may be added to and removed from the hierarchy at runtime. + They bear user-defined names. They may exist independently, outside any + container. +
+ +New set element instances generally are created through members of + com::sun::star::lang::XSingleServiceFactory or, + if supported, com::sun::star::lang::XMultiServiceFactory + on an implementation of SetUpdate. Initially, they are not + contained in a set object and have no meaningful name. +
+ +While an instance is not contained in a set object, it is owned by + the client and can be disposed by calling + com::sun::star::lang::XComponent::dispose(). The name + of the object can freely be changed in that situation though without + persistent effect. +
+ +When the instance is inserted into a set (this includes replacing an + existing element), ownership is transferred to the container. + While it is contained in the container, clients must not dispose the + object. When inserted, the name of the object is fixed and is used to + identify it within the container. An implementation may support + com::sun::star::container::XNamed::setName() even in + this case. If it does, changing the name has the same effect of removing + the object (under the old name) and then reinserting it into the same + container (using the new name). +
+ +When an instance is removed from a set (this includes being replaced by + a new element), ownership is transferred to the client again. It can then be + disposed or reinserted into a container. An instance can only be inserted + into a container, if it was obtained from the same hierarchy. +
+ +When a set element is removed from its set from outside the hierarchy, the + container disposes of the object. This occurrence can be detected by registering + a com::sun::star::lang::XEventListener with the object. +
+ +If an implementation is part of a read-only view of the hierarchy, + changing the name or parent is not supported (the object can't be removed from + its container anyway). +
+ + @see com::sun::star::configuration::SetAccess + Parent objects of this service generally implement service SetAccess. + + @see com::sun::star::configuration::GroupElement + A complementary service for elements of a static heterogeneous collection. + + @see com::sun::star::configuration::AccessRootElement + A complementary service for the root element of a hierarchy. + +*/ +published service SetElement +{ +/** is the basic service for accessing information about an element in the + hierarchy. +*/ + service HierarchyElement; + +/** provides access to the containing set object. + +In this service, this interface is mandatory
+ +com::sun::star::container::XChild::getParent() + returns `NULL`, if the object is currently not contained in a container. +
+ +An implementation may also support + com::sun::star::container::XChild::setParent(). + If it does, changing the parent has the effect of first removing the object + from its old parent (if any) and then inserting it into the new parent + (unless that is `NULL`) under the same name. The new parent must be part of + the same hierarchy as the old one. The name of the object must have been set + before. +
+*/ + interface com::sun::star::container::XChild; + +/** allows controlling or observing the lifetime of the object. + +Clients may dispose of the object using + com::sun::star::lang::XComponent::dispose(), only if + the object is currently not contained in a container ( + com::sun::star::container::XChild::getParent() + returns `NULL`). +
+ +Clients may register a com::sun::star::lang::XEventListener + to be notified, if the object is removed from its container by an outside source. +
+*/ + interface com::sun::star::lang::XComponent; + +/** provides information about the type of the element. + +Set elements have a predetermined structure (their type), + that is described by and can be generated from a template. +
+ +If the object was created using interface + com::sun::star::lang::XSingleServiceFactory + on an implementation of SetUpdate, this interface describes the + same template as interface XTemplateContainer on that + SetUpdate. +
+If the object was created using interface + com::sun::star::lang::XMultiServiceFactory + on an implementation of SetUpdate, this interface describes the + template whose name was used as a service identifier for the factory method. +
+Otherwise, the semantics of the information provided about the template depends on the + implementation. +
+ + @see com::sun::star::configuration::XTemplateContainer +*/ + interface com::sun::star::configuration::XTemplateInstance; +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/SetUpdate.idl b/offapi/com/sun/star/configuration/SetUpdate.idl new file mode 100644 index 000000000..8736e2a88 --- /dev/null +++ b/offapi/com/sun/star/configuration/SetUpdate.idl @@ -0,0 +1,91 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_SetUpdate_idl__ +#define __com_sun_star_configuration_SetUpdate_idl__ + +#includeAllows adding and removing elements. + Helps creates new elements to be added. +
+ +This service extends SetAccess to support + modifying the container. +
+ +Any child and descendant objects support modifying access as well, + unless they represent a read-only tree element (as indicated by + com::sun::star::beans::PropertyAttribute::READONLY). +
+*/ +published service SetUpdate +{ +/** is the basic service providing read access to a set within the + hierarchy. +*/ + service SetAccess; + +/** is the basic service providing modifying access to a + not necessarily hierarchical set. + +Changes can be observed by registering a listener with interface + com::sun::star::container::XContainer. +
+ +If the elements of this set are of object type, new elements are constructed + to match the tree structure prescribed by the element template of this set, when + using interfaces com::sun::star::lang::XSingleServiceFactory + and (if supported) com::sun::star::lang::XMultiServiceFactory. +
+ +Objects that are removed from a set can be reinserted into any set supporting + the same template within the same hierarchy. Even under a different name. +
+ +Implementations that support insertion of objects that weren't obtained + from within the hierarchy must reject elements that don't have the correct + structure as described by the template, even if the object returns the + correct template name from XTemplateInstance::getTemplateName(). +
+ +Other ways in which an element may be moved among or within compatible sets + include com::sun::star::container::XChild::setParent() + and com::sun::star::container::XNamed::setName(), if + the element implements them. +
+ + @see com::sun::star::configuration::SetElement +*/ + service SimpleSetUpdate; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/SimpleSetAccess.idl b/offapi/com/sun/star/configuration/SimpleSetAccess.idl new file mode 100644 index 000000000..3a6253162 --- /dev/null +++ b/offapi/com/sun/star/configuration/SimpleSetAccess.idl @@ -0,0 +1,102 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_SimpleSetAccess_idl__ +#define __com_sun_star_configuration_SimpleSetAccess_idl__ + +#includeAlso provides information about the template for elements. + Allows normalizing externally generated names. +
+ +Sets are dynamic containers.
+ +The number and names of contained elements is not fixed in advance, + but all elements have to be of one predetermined type. +
+*/ +published service SimpleSetAccess +{ +/** is the basic service for accessing child and descendent nodes. + +External names from foreign namespaces should be normalized using + com::sun::star::util::XStringEscape::escapeString(), + if available, before using them as element names. +
+*/ + interface com::sun::star::container::XNameAccess; + +/** provides additional information about the element type. [optional] + +All set elements, if they are not just simple values, but whole trees, + must have a predetermined structure (their type) + that is described by and can be generated from a template. + The semantics of the information provided about the template depends on the + implementation. +
+ +This interface may be missing, if the implementation can support only + one predefined type or if the elements are of a simple type and + no further information is available. In the latter case, + com::sun::star::container::XElementAccess::getElementType() + provides all the information there is about the element's type. +
+*/ + [optional] interface com::sun::star::configuration::XTemplateContainer; + +/** allows normalizing and denormalizing external names. [optional] + +Elements of a set often correspond to external entities, + for example, files, web pages, and people whose names obey different rules and + restrictions than names that are valid in the hierarchical naming scheme. +
+ +This interface may be missing if there are no naming restrictions, + if the implementation handles any such conversions internally, + or if clients must enforce such restrictions themselves. In the last case, + the naming scheme documentation must fully document any restrictions. +
+*/ + [optional] interface com::sun::star::util::XStringEscape; + +/** allows attaching listeners to this node to monitor changes to the set. [optional] + +This interface may be missing if the implementation does not support + notifications. +
+*/ + [optional] interface com::sun::star::container::XContainer; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/SimpleSetUpdate.idl b/offapi/com/sun/star/configuration/SimpleSetUpdate.idl new file mode 100644 index 000000000..735316783 --- /dev/null +++ b/offapi/com/sun/star/configuration/SimpleSetUpdate.idl @@ -0,0 +1,164 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_SimpleSetUpdate_idl__ +#define __com_sun_star_configuration_SimpleSetUpdate_idl__ + +#includeAllows adding and removing elements. + Helps create new elements to be added. +
+ +This service extends SimpleSetAccess to support + modifying the container. Any child objects shall in turn support + modifying access. +
+*/ +published service SimpleSetUpdate +{ +/** is the basic service providing read access to a (not necessarily + hierarchical) set. +*/ + service SimpleSetAccess; + +/** allows inserting, removing, and replacing elements. + +This interface extends the interface + com::sun::star::container::XNameAccess supported + by service SimpleSetAccess to allow modifying the container. +
+ +If available, changes can be observed by registering a listener with interface + com::sun::star::container::XContainer. +
+ +If the elements of this set are of simple type (the type returned by + com::sun::star::container::XElementAccess::getElementType() + is not an interface type), then values of that type can directly be passed to + com::sun::star::container::XNameContainer::insertByName() + and + com::sun::star::container::XNameContainer::replaceByName(). +
+ +Otherwise new elements have to be constructed to match the type + prescribed by the element template of this set. Such elements can be created + using interfaces com::sun::star::lang::XSingleServiceFactory + and, if supported, com::sun::star::lang::XMultiServiceFactory. +
+ +Objects to be inserted must not be contained in any set at the time of + insertion. com::sun::star::container::XChild::getParent() + must return `NULL`. If a name had been assigned to the object prior to insertion + (using com::sun::star::container::XNamed::setName() + or by other means), this name is ignored and will be lost. + After insertion the name of the object is the name that was used as argument + to com::sun::star::container::XNameContainer::insertByName() + or com::sun::star::container::XNameContainer::replaceByName(). +
+ + +Objects that are removed using + com::sun::star::container::XNameContainer::removeByName() + or replaced using + com::sun::star::container::XNameContainer::replaceByName() + remain valid and can be reinserted into a set supporting the same template and + even under a different name. +
+ +An implementation need not support insertion of objects that were not + obtained in one of the ways described above. If it does, the implementation + must reject elements that do not have the correct structure as described + by the template. +
+*/ + interface com::sun::star::container::XNameContainer; + +/** allows creating an object that can be inserted into this set. [conditional] + +This interface shall be implemented by an implementation, + if and only if the element type of the set, as returned by + com::sun::star::container::XElementAccess::getElementType(), + is an object type, such as an interface. +
+ +Using com::sun::star::lang::XSingleServiceFactory::createInstance() + an instance of the element template of this set is created. If the set + supports multiple templates or variations of the basic template, a default + variant of the basic template is instantiated. If an implementation supports + variations, they may be specified by passing arguments to + com::sun::star::lang::XSingleServiceFactory::createInstanceWithArguments(). + There are no predefined arguments for all versions of this service. +
+ +The object created is not contained in the set and does not have a name yet. + It may subsequently be inserted into the set and named using + com::sun::star::container::XNameContainer::insertByName() + or + com::sun::star::container::XNameContainer::replaceByName(). +
+*/ + [optional] interface com::sun::star::lang::XSingleServiceFactory; + +/** allows creating various objects that can be inserted into this set. [optional] + +This interface may be implemented by an implementation of + service SetUpdate to support creating elements from other than + the basic element template. An example of this would be an + implementation that supports inheritance, allowing the use of + templates derived from the basic template by extension. +
+ +This interface may only be implemented if the element type of the set + (as returned by + com::sun::star::container::XElementAccess::getElementType()) + is an object type, such as an interface. An implementation should also implement + interface XTemplateContainer which is optional in this service. +
+ +The service identifier argument passed + to com::sun::star::lang::XMultiServiceFactory::createInstance() + or com::sun::star::lang::XMultiServiceFactory::createInstanceWithArguments() + names the template to be instantiated or otherwise identifies the structure + to be built. The implementation must at least support using the template + name obtained from XTemplateContainer::getElementTemplateName() + as a service identifier, in which case the result shall be the same as if + the corresponding member of com::sun::star::lang::XSingleServiceFactory + had been called. +
+ +*/ + [optional] interface com::sun::star::lang::XMultiServiceFactory; + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/Update.idl b/offapi/com/sun/star/configuration/Update.idl new file mode 100644 index 000000000..7c699be87 --- /dev/null +++ b/offapi/com/sun/star/configuration/Update.idl @@ -0,0 +1,39 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ + +#ifndef __com_sun_star_configuration_Update_idl__ +#define __com_sun_star_configuration_Update_idl__ + +#includeThis singleton is unpublished and unstable.
+ + @since OOo 3.3 +*/ +singleton Update: XUpdate; + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/UpdateRootElement.idl b/offapi/com/sun/star/configuration/UpdateRootElement.idl new file mode 100644 index 000000000..78342f73c --- /dev/null +++ b/offapi/com/sun/star/configuration/UpdateRootElement.idl @@ -0,0 +1,96 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_UpdateRootElement_idl__ +#define __com_sun_star_configuration_UpdateRootElement_idl__ + +#includeExtends AccessRootElement by adding support for + collecting changes and applying them to a backend store as a single batch. +
+ +An implementation represents the root of a partial hierarchy. [See the + documentation for AccessRootElement]. The hierarchy in turn is + a view onto a fragment of persistent data tree that can be accessed + through several such views, or even several processes, simultaneously. +
+ +Elements of the hierarchy, such as descendants of this root element, + may support modification by providing appropriate + interfaces. Changes done this way initially only affect these objects + themselves and other objects within the same hierarchy, such as other + descendants of this root element. +
+ +The accumulated changes within this hierarchy can be managed using + com::sun::star::util::XChangesBatch. Pending changes + will become persistent and visible from other overlapping hierarchies + only when com::sun::star::util::XChangesBatch::commitChanges() + is called. If the hierarchy is disposed or discarded without committing + changes, the changes will be lost. +
+ + @see com::sun::star::configuration::GroupUpdate + @see com::sun::star::configuration::SetUpdate +*/ +published service UpdateRootElement +{ +/** provides (read-only) access to information about the root element of + (a fragment of) the hierarchy. It also provides some functionality concerning + the hierarchy (fragment) accessible from that element as a whole. +*/ + service AccessRootElement; + +/** allows managing changes within the hierarchy. + +com::sun::star::util::XChangesBatch::getPendingChanges() + reports all changes within the hierarchy that are done through (direct or + indirect) descendants of this element. The same set of changes is committed + to persistent storage and/or made visible to other objects accessing the same + data set, when + com::sun::star::util::XChangesBatch::commitChanges() + is invoked. +
+ +If the implementation supports + com::sun::star::lang::XLocalizable::setLocale(), changes + will be considered to apply to the locale that is set when + com::sun::star::util::XChangesBatch::commitChanges() + is invoked. +
+ + @see AccessRootElement + @see com::sun::star::util::XChangesNotifier +*/ + interface com::sun::star::util::XChangesBatch; +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/XReadWriteAccess.idl b/offapi/com/sun/star/configuration/XReadWriteAccess.idl new file mode 100644 index 000000000..0980b3936 --- /dev/null +++ b/offapi/com/sun/star/configuration/XReadWriteAccess.idl @@ -0,0 +1,38 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#ifndef _COM_SUN_STAR_CONFIGURATION_XREADWRITEACCESS_IDL +#define _COM_SUN_STAR_CONFIGURATION_XREADWRITEACCESS_IDL + +#includeThis interface is still unpublished and unstable.
+ + @since LibreOffice 3.6 +*/ +interface XReadWriteAccess { + interface com::sun::star::container::XHierarchicalNameReplace; + + interface com::sun::star::util::XChangesBatch; + + // @since LibreOffice 5.0 + interface com::sun::star::beans::XHierarchicalPropertySetInfo; +}; + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/XTemplateContainer.idl b/offapi/com/sun/star/configuration/XTemplateContainer.idl new file mode 100644 index 000000000..cd119a0fd --- /dev/null +++ b/offapi/com/sun/star/configuration/XTemplateContainer.idl @@ -0,0 +1,68 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_XTemplateContainer_idl__ +#define __com_sun_star_configuration_XTemplateContainer_idl__ + +#includeAn implementation will also implement + com::sun::star::lang::XSingleServiceFactory, in which case + that interface creates instances of the specified template. +
+If multiple templates are supported, the supported factory interface may be + com::sun::star::lang::XMultiServiceFactory, in which case + the `string` returned from + XTemplateContainer::getElementTemplateName() can be used as + the service name argument. +
+ + @see XTemplateInstance + */ +published interface XTemplateContainer: com::sun::star::uno::XInterface +{ + + /** retrieves the name of the template + +If instances of multiple templates are accepted by the container, + this is the name of the basic or primary template. +
+Instances of the template must be created + using an appropriate factory. +
+ + @returns + the name of the (default) template for elements. + */ + string getElementTemplateName(); + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/XTemplateInstance.idl b/offapi/com/sun/star/configuration/XTemplateInstance.idl new file mode 100644 index 000000000..2eab30a26 --- /dev/null +++ b/offapi/com/sun/star/configuration/XTemplateInstance.idl @@ -0,0 +1,58 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_XTemplateInstance_idl__ +#define __com_sun_star_configuration_XTemplateInstance_idl__ + +#includeTemplate names are similar to service names, but apply to structure and + content, rather than to type. +
+Often a template description can be retrieved from a repository and then be + interpreted by a factory object. Templates provide a means to build + new kinds of objects dynamically. +
+ + @see XTemplateContainer + */ +published interface XTemplateInstance: com::sun::star::uno::XInterface +{ + + /** retrieves the name of the template + + @returns + the name of the template this object was built from or conforms to. + */ + string getTemplateName(); + +}; + + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/XUpdate.idl b/offapi/com/sun/star/configuration/XUpdate.idl new file mode 100644 index 000000000..90862b112 --- /dev/null +++ b/offapi/com/sun/star/configuration/XUpdate.idl @@ -0,0 +1,51 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ + +#ifndef __com_sun_star_configuration_XUpdate_idl__ +#define __com_sun_star_configuration_XUpdate_idl__ + +#includeThis interface is unpublished and unstable.
+ + @since OOo 3.3 +*/ +interface XUpdate { + void insertExtensionXcsFile([in] boolean shared, [in] string fileUri); + + void insertExtensionXcuFile([in] boolean shared, [in] string fileUri); + + void removeExtensionXcuFile([in] string fileUri); + // fileUri must exactly match corresponding insertExtensionXcuFile + // argument + + void insertModificationXcuFile( + [in] string fileUri, [in] sequence< string > includedPaths, + [in] sequence< string > excludedPaths); +}; + +}; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/AuthenticationFailedException.idl b/offapi/com/sun/star/configuration/backend/AuthenticationFailedException.idl new file mode 100644 index 000000000..c004544e4 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/AuthenticationFailedException.idl @@ -0,0 +1,42 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ + +#ifndef __com_sun_star_configuration_backend_AuthenticationFailedException_idl__ +#define __com_sun_star_configuration_backend_AuthenticationFailedException_idl__ + +#includeConfiguration data is organized into layers which are selected + by components and entities. +
+ +Components are characterized by configuration schemas. + A component contains configuration data for a particular + application domain or software module. +
+Entities are organized hierarchically in organizations, + groups, roles and individual users. Each element of the associated + hierarchy corresponds to a layer that applies to an entity. +
+A layer contains data for multiple components + associated to a single entity. +
+
+ @since OOo 1.1.2
+*/
+published service Backend
+{
+
+ /**
+ provides access to configuration schemas.
+ */
+ interface XSchemaSupplier ;
+
+
+ /**
+ provides access to the layer data.
+ */
+ interface XBackend ;
+
+
+ /**
+ provides information about supported and special entities.
+ */
+ [optional] interface XBackendEntities ;
+
+} ;
+
+
+} ; } ; } ; } ; } ;
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/offapi/com/sun/star/configuration/backend/BackendAccessException.idl b/offapi/com/sun/star/configuration/backend/BackendAccessException.idl
new file mode 100644
index 000000000..4a423c417
--- /dev/null
+++ b/offapi/com/sun/star/configuration/backend/BackendAccessException.idl
@@ -0,0 +1,43 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef __com_sun_star_configuration_backend_BackendAccessException_idl__
+#define __com_sun_star_configuration_backend_BackendAccessException_idl__
+
+#include Wraps an exception that originates in the underlying access layer. If this interface is present, a SingleBackend
+ may be passed, that is used to access the data.
+ Also a com::sun::star::configuration::bootstrap::BootstrapContext
+ can be passed, that provides further settings for the backend.
+ If this interface is missing, the real backend to use is determined
+ from the com::sun::star::uno::XComponentContext.
+ Indicates an error that originates in the underlying access layer. May be a numeric error code, a message `string` or `VOID`,
+ if the original exception is not represented as a
+ com::sun::star::uno::Exception.
+ Examples of this include
+
+
+
Any future attempts to access data from the backend through this object + will also fail. +
+ + @since OOo 1.1.2 + */ +published exception ConnectionLostException : BackendAccessException { +} ; + +} ; +} ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/CopyImporter.idl b/offapi/com/sun/star/configuration/backend/CopyImporter.idl new file mode 100644 index 000000000..68bfae8e7 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/CopyImporter.idl @@ -0,0 +1,72 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_CopyImporter_idl__ +#define __com_sun_star_configuration_backend_CopyImporter_idl__ + +#includeIn this implementation, the changes are copied over any + XLayer data that already exists in the Backend, + replacing it completely. +
+ */ + service Importer ; + + + /** allows initializing the implementation with settings that control + its behavior . + +This interface, which is optional in Importer + is mandatory in this service and supports the following arguments + which must be provided as + com::sun::star::beans::NamedValue: +
Overwrite
: `boolean`The source and destination repositories are selected by arguments + passed to + com::sun::star::task::XJob::execute(). + The names and meanings of such arguments depend on + the implementation. Each implementation must document such arguments. +
+ +Implementations may return a value from + com::sun::star::task::XJob::execute() + that indicates the status of job execution. The type and meaning of + such status indicators depend on the implementation. +
+If `VOID` or `TRUE` is returned, this indicates successful + execution. If an + com::sun::star::uno::Exception is returned, + it represents an error condition encountered during execution. +
+ +The following arguments to + com::sun::star::task::XJob::execute() + should be supported by implementations. Implementations must document + a failure to support any of these arguments: +
ImporterService
: `string`OverwriteExisting
: `boolean`TruncateExisting
: `boolean`Entity
: `string`Component
: `string`LayerFilter
: LayerFilterThis object is accessible as singleton within the context
. + + @since OOo 1.1.2 +*/ +service DefaultBackend +{ + + /** characterizes the functionality. + */ + service Backend ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/HierarchyBrowser.idl b/offapi/com/sun/star/configuration/backend/HierarchyBrowser.idl new file mode 100644 index 000000000..2bd96640d --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/HierarchyBrowser.idl @@ -0,0 +1,72 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_HierarchyBrowser_idl__ +#define __com_sun_star_configuration_backend_HierarchyBrowser_idl__ + +#includeThe repository to browse is selected by arguments passed to + com::sun::star::task::XJob::execute(). + The names and meanings of such arguments depend on + the implementation. Each implementation must document such arguments. +
+ +The following argument to + com::sun::star::task::XJob::execute() + must be supported by all implementations: +
ExcludeComponents
: `string[]` or `string`The return value of + com::sun::star::task::XJob::execute() + is a list of components found. The format in which components are + returned may depend on the implementation. Each implementation + should support returning component identifiers that are compatible + with some implementation of Backend. +
+ */ + interface com::sun::star::task::XJob ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/Importer.idl b/offapi/com/sun/star/configuration/backend/Importer.idl new file mode 100644 index 000000000..8ea23576b --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/Importer.idl @@ -0,0 +1,70 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_Importer_idl__ +#define __com_sun_star_configuration_backend_Importer_idl__ + +#includeThe configuration changes are read from a XLayer + and stored into a Backend. +
+ + @since OOo 1.1.2 +*/ +published service Importer +{ + + /** allows importing configuration data into a backend. + */ + interface XLayerImporter ; + + + /** allows initializing the implementation with settings that control + its behavior . + +Arguments are provided as + com::sun::star::beans::NamedValue. + Implementations specify which arguments they support. + +
Notify
: `boolean`Examples of this include +
The well known requests handled by this service include +
The continuation restrictions are as follows: Let C be the + subset of the provided continuations that are of type + com::sun::star::task::XInteractionApprove, + com::sun::star::task::XInteractionDisapprove, + com::sun::star::task::XInteractionRetry, or + com::sun::star::task::XInteractionAbort (or of a + derived type). All other continuations are ignored for these requests. + The request is only handled if the set C is any of the + following: +
The arguments must be a sequence of + com::sun::star::beans::PropertyValues. The + currently supported properties are: +
"Parent"
of type
+ com::sun::star::awt::XWindow denotes the
+ parent window for any GUI dialogs the interaction handler pops up;
+ it is strongly recommended that this property is supplied;"Context"
of type `string` is a
+ textual description of the current context (used, e.g., as a first
+ line of text in error boxes); this property is optional.A layer contains the configuration setting changes to be performed + on a default settings tree to obtain the values of those settings + for a given entity and component. +
+ + @see com::sun::star::configuration::backend::Schema + Service providing access to schema data for a configuration component. + + @see com::sun::star::configuration::backend::UpdatableLayer + Service providing write access to a configuration data layer. + + @since OOo 1.1.2 + */ +published service Layer +{ + + /** + provides read access to the contents of the configuration layer. + */ + interface XLayer ; + + + /** + provides read access to sublayers accessible through an + additional criterion (for instance the locale they contain data for). + */ + [optional] interface XCompositeLayer ; + + + /** + provides a way to detect changes to the layer. + +Timestamps should be considered as opaque markers and + can only safely be compared for equality and + only to timestamps generated by the same implementation. + When the content of the Layer changes, + the timestamp is guaranteed to change to a different value. +
+The timestamp format depends on the implementation. + If the timestamp is a representation of the time of the last change, + the recommended format is "YYYYMMDDhhmmssZ". +
+ */ + [optional] interface com::sun::star::util::XTimeStamped ; + + + /** + The URL of the layer data. + + @since OOo 2.0 + */ + [property,optional,readonly] string URL ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/LayerDescriber.idl b/offapi/com/sun/star/configuration/backend/LayerDescriber.idl new file mode 100644 index 000000000..da89b4254 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/LayerDescriber.idl @@ -0,0 +1,52 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ + +#ifndef __com_sun_star_configuration_backend_LayerDescriber_idl__ +#define __com_sun_star_configuration_backend_LayerDescriber_idl__ + +#includeA layer filter wraps a source XLayer object and + provides access to a filtered version of its data. + The data read from the filter usually is produced from the source data + by adding and removing elements or modifying values. +
+ + @see com::sun::star::configuration::backend::DataImporter + Service that supports applying a LayerFilter to imported data. + + @since OOo 2.0 + */ +published service LayerFilter +{ + + /** + provides read access to the filtered contents. + +Method XLayer::readData() will render a filtered version + of the data produced by the same method of the source object. +
+ */ + interface XLayer ; + + + /** + provides a means to set the source data for the filter. + + Call com::sun::star::lang::XInitialization::initialize()()
+ with a single argument of type com::sun::star::beans::NamedValue,
+ where com::sun::star::beans::NamedValue::Name is "Source"
+ and com::sun::star::beans::NamedValue::Value
+ is an object implementing XLayer.
+
The configuration layer data is read from a XLayer + and the changed layer is provided as XLayer again or + described to a XLayerHandler. +
+ + @see com::sun::star::configuration::backend::UpdatableLayer + Service describes a layer and accepts a changed layer... + + @since OOo 1.1.2 +*/ +published service LayerUpdateMerger +{ + + /** accepts events describing the changes. + */ + interface com::sun::star::configuration::backend::XUpdateHandler ; + + + /** allows initializing layer data source and target. + +Both source and target of the update can be provided by passing a + XUpdatableLayer object. Alternatively they can be + provided individually by providing a XLayer object as + data source and an XLayerHandler object to receive the + updated data. +
+Implementations can provide more arguments to fine tune the behavior. + Such arguments are provided as + com::sun::star::beans::NamedValue. + Implementations should support the following named arguments: +
Overwrite
: `boolean`Truncate
: `boolean`Data to be imported can be a single layer either from a full local + configuration database or from a particular OOR Update XML file. +
+Data is imported into the DefaultBackend. +
+ + @see com::sun::star::configuration::backend::LocalHierarchyBrowser + Service that can be used to locate available layer files or components. + + @see com::sun::star::configuration::backend::LocalSingleBackend + Service that can be used to access a local configuration database. + + @since OOo 1.1.2 +*/ +published service LocalDataImporter +{ + + /** provides for running an import job + + The implementation returns `VOID` from
+ com::sun::star::task::XJob::execute()
+ to indicates successful execution. If import is not executed,
+ because OverwriteExisting =
`TRUE` was specified,
+ a com::sun::star::lang::IllegalAccessException
+ is returned.
+
If `VOID` or `TRUE` is returned, this indicates successful + execution. If an + com::sun::star::uno::Exception is returned, + it represents an error condition encountered during execution. +
+ +The standard arguments to + com::sun::star::task::XJob::execute() + are all supported by implementations. Additionally the following + argument is required to select the data source: +
LayerDataUrl
: `string` If no Component
is provided, this must be the
+ location of an OOR Update XML file, which will be imported
+ directly.
+
If a Component
is provided, the
+ LayerDataUrl
is treated as Entity
+ (i.e. Layer directory base URL) for a local
+ configuration database and the appropriate component
+ from that repository is imported.
+
Implementations may support additional parameters to select + a destination Backend, that is not the + DefaultBackend. +
+ */ + service DataImporter ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/LocalHierarchyBrowser.idl b/offapi/com/sun/star/configuration/backend/LocalHierarchyBrowser.idl new file mode 100644 index 000000000..e097f21df --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/LocalHierarchyBrowser.idl @@ -0,0 +1,79 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_LocalHierarchyBrowser_idl__ +#define __com_sun_star_configuration_backend_LocalHierarchyBrowser_idl__ + +#includeEither a schema repository or a layer directory can be browsed. + Components can be retrieved either as component names or as + file URLs. +
+ + The following additional arguments are supported for
+ com::sun::star::task::XJob::execute():
+
+
SchemaDataUrl
: `string`LayerDataUrl
should not be specified.
+ LayerDataUrl
: `string`SchemaDataUrl
should not be specified.
+ FetchComponentNames
: `boolean`Typically this member should contain an exception characterizing + the error in detail. +
+For example the following exceptions may be used: +
If no more detail information is available, this may be left `VOID`. +
+ */ + any ErrorDetails; +}; + + +}; }; }; }; }; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/MergeImporter.idl b/offapi/com/sun/star/configuration/backend/MergeImporter.idl new file mode 100644 index 000000000..e9deb915e --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/MergeImporter.idl @@ -0,0 +1,61 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_MergeImporter_idl__ +#define __com_sun_star_configuration_backend_MergeImporter_idl__ + +#includeNo named arguments to + com::sun::star::lang::XInitialization::initialize() + are supported. +
+ + @since OOo 1.1.2 +*/ +published service MergeImporter +{ + + /** allows importing configuration data into a backend. + +In this implementation, the changes are merged with any + XLayer data that already exists in the Backend, + replacing it completely. +
+ + @see LayerUpdateMerger + Service that can be used to perform merging of changes into a layer. + */ + service Importer ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/MergeRecoveryRequest.idl b/offapi/com/sun/star/configuration/backend/MergeRecoveryRequest.idl new file mode 100644 index 000000000..569c4a338 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/MergeRecoveryRequest.idl @@ -0,0 +1,79 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_MergeRecoveryRequest_idl__ +#define __com_sun_star_configuration_backend_MergeRecoveryRequest_idl__ + +#includeTypically this member should contain an exception characterizing + the error in detail. +
+For example the following exceptions may be used: +
If no more detail information is available, this may be left `VOID`. +
+ */ + any ErrorDetails; + + /** + Identifier of the layer object containing the invalid data. + */ + string ErrorLayerId; + + /** + specifies whether the requester wants to remove or skip the invalid layer. + + If `TRUE` the requester wants to remove the underlying data of
+ the layer.
+ If `FALSE` the request is to skip the underlying data this time,
+ but without removing it.
+
If present a type + com::sun::star::configuration::bootstrap::BootstrapContext + must be passed, that provides further backend initialization settings. +
+ + + */ + + [optional] interface com::sun::star::lang::XInitialization ; + +} ; + + +} ; } ; } ; } ; } ; +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/NodeAttribute.idl b/offapi/com/sun/star/configuration/backend/NodeAttribute.idl new file mode 100644 index 000000000..44eea3eea --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/NodeAttribute.idl @@ -0,0 +1,85 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_NodeAttribute_idl__ +#define __com_sun_star_configuration_backend_NodeAttribute_idl__ + + +module com { module sun { module star { module configuration { module backend { + + +/** These values are used to specify the behavior of a node or property + in a layer. + +The values were chosen so they can be combined with values from + SchemaAttribute +
+ + @see com::sun::star::configuration::backend::SchemaAttribute + During merging the values may be combined with static attributes + from the schema. + + @since OOo 1.1.2 + */ +published constants NodeAttribute +{ + + /** indicates that a node or property may not be changed or overridden + in subsequent layers + */ + const short FINALIZED = 256; + + + /** indicates that a set item may not be removed or replaced + in subsequent layers. + */ + const short MANDATORY = 512; + + + /** indicates that a node or property may not be changed + in this or subsequent layer. + */ + const short READONLY = 1024; + + + /** indicates that contents shall be fused. + +Used in XLayerHandler::addOrReplaceNode(), + XLayerHandler::addOrReplaceNodeFromTemplate(), + XUpdateHandler::addOrReplaceNode(), and + XUpdateHandler::addOrReplaceNodeFromTemplate().
+ + @since OOo 2.0.3 + */ + const short FUSE = 2048; + + + /** can be used to mask the node attributes from merged attributes + */ + const short MASK = 32512; // 0xFF00, changed to 0x7F00 because only 3 bits + // are masked and fixing a bug in idlc + +}; + + +}; }; }; }; }; + + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/OfflineBackend.idl b/offapi/com/sun/star/configuration/backend/OfflineBackend.idl new file mode 100644 index 000000000..4d7a5181d --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/OfflineBackend.idl @@ -0,0 +1,65 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_OfflineBackend_idl__ +#define __com_sun_star_configuration_backend_OfflineBackend_idl__ + +#includeIf no backend is provided during initialization or if the context
+ contains an Offline
flag that is `TRUE`, then off-line mode
+ is activated. This may fail, if the off-line cache has not been filled
+ during a previous execution.
+
Less entities may be available from XBackendEntities, + when operating in off-line mode than when operating with an on-line + SingleBackend. +
+If off-line mode is not invoked, the implementation behaves + like any other BackendAdapter. +
+ + */ + service BackendAdapter ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/OnlineBackend.idl b/offapi/com/sun/star/configuration/backend/OnlineBackend.idl new file mode 100644 index 000000000..9822ae5ba --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/OnlineBackend.idl @@ -0,0 +1,52 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_OnlineBackend_idl__ +#define __com_sun_star_configuration_backend_OnlineBackend_idl__ + +#includeA component is a set of hierarchically organized and semantically + related configuration settings, e.g StarWriter settings. +
+A component schema contains two separate sections, one which + describes the templates to be used in the dynamic containers (sets) of + the component and one which describes the component's data structure. +
+ + @see com::sun::star::configuration::backend::Layer + Service providing access to individual + configuration data for an entity. + + @since OOo 1.1.2 + */ +published service Schema +{ + + /** + handles access to the schema data for a component. +The data can be read either in its entirety (templates and component + description) or each of its parts can be accessed. +
+ */ + interface XSchema ; + + + /** + The URL of the layer data. + + @since OOo 2.0 + */ + [property,optional,readonly] string URL ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/SchemaAttribute.idl b/offapi/com/sun/star/configuration/backend/SchemaAttribute.idl new file mode 100644 index 000000000..dbbf4ebe4 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/SchemaAttribute.idl @@ -0,0 +1,65 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_SchemaAttribute_idl__ +#define __com_sun_star_configuration_backend_SchemaAttribute_idl__ + + +module com { module sun { module star { module configuration { module backend { + + +/** These values are used to specify the behavior of a node or property + in the schema. + + @see com::sun::star::configuration::backend::NodeAttribute + During merging the values may be combined with node attributes. + + @since OOo 1.1.2 + */ +published constants SchemaAttribute +{ + + /** indicates that a property value can't be null. + */ + const short REQUIRED = 1; + + + /** indicates that the content of the node or the value of the property + may depend on the locale. + */ + const short LOCALIZED = 2; + + + /** indicates that properties can be added to the node at runtime + */ + const short EXTENSIBLE = 4; + + + /** can be used to mask the schema attributes from merged attributes + */ + const short MASK = 255; // 0x00FF + +}; + + +}; }; }; }; }; + + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/SchemaSupplier.idl b/offapi/com/sun/star/configuration/backend/SchemaSupplier.idl new file mode 100644 index 000000000..d43d4144c --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/SchemaSupplier.idl @@ -0,0 +1,47 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_SchemaSupplier_idl__ +#define __com_sun_star_configuration_backend_SchemaSupplier_idl__ + +#includeConfiguration data is organized into layers which are selected + by components and entities. +
+ +Components are characterized by configuration schemas. + A component contains configuration data for a particular + application domain or software module. +
+Entities are organized hierarchically in organizations, + groups, roles and individual users. Each element of the associated + hierarchy corresponds to a layer that applies to an entity. +
+Layers contains data for multiple components + associated to a single entity. +
+
+ @since OOo 1.1.2
+*/
+published service SingleBackend
+{
+
+ /**
+ provides access to configuration schemas.
+ */
+ interface XSchemaSupplier ;
+
+
+ /**
+ provides access to the layer data.
+ */
+ interface XMultiLayerStratum ;
+
+
+ /**
+ provides information about supported and special entities.
+ */
+ interface XBackendEntities ;
+
+} ;
+
+
+} ; } ; } ; } ; } ;
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/offapi/com/sun/star/configuration/backend/SingleBackendAdapter.idl b/offapi/com/sun/star/configuration/backend/SingleBackendAdapter.idl
new file mode 100644
index 000000000..da6ecb788
--- /dev/null
+++ b/offapi/com/sun/star/configuration/backend/SingleBackendAdapter.idl
@@ -0,0 +1,52 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef __com_sun_star_configuration_backend_SingleBackendAdapter_idl__
+#define __com_sun_star_configuration_backend_SingleBackendAdapter_idl__
+
+#include All real functionality is provided by the wrapped SingleBackend.
+
+ @see com::sun::star::configuration::backend::OnlineBackend
+
+ @since OOo 1.1.2
+*/
+published service SingleBackendAdapter
+{
+
+ /** provides access to configuration data from a SingleBackend.
+ */
+ service BackendAdapter ;
+
+} ;
+
+
+} ; } ; } ; } ; } ;
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/offapi/com/sun/star/configuration/backend/SingleLayerStratum.idl b/offapi/com/sun/star/configuration/backend/SingleLayerStratum.idl
new file mode 100644
index 000000000..b59deecbb
--- /dev/null
+++ b/offapi/com/sun/star/configuration/backend/SingleLayerStratum.idl
@@ -0,0 +1,55 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef __com_sun_star_configuration_backend_SingleLayerStratum_idl__
+#define __com_sun_star_configuration_backend_SingleLayerStratum_idl__
+
+#include no parameters need to be passed as backends are initialized
+ using the service registration database "services.rdb".
+ The name is unique within a component. A layer contains the configuration setting changes to be performed
+ on a default layer (or schema) to obtain the values of those settings
+ for a given entity and component.
+ An updatable layer can be read or replaced with another layer.
+ If the implementation supports
+ com::sun::star::util::XTimeStamped,
+ then after executing XUpdatableLayer::replaceWith()
+ the timestamp will be the one for the replaced contents and
+ if reading after updates is supported the next read will reproduce the
+ replaced data.
+ Depending of the actual type (simple, i.e pure XLayer or
+ composite, i.e XCompositeLayer) of the current layer and
+ the provided replacement layer, the operation performed
+ by XUpdatableLayer::replaceWith(), will vary.
+ For the different current/replacement layer combinations, we have:
+ Data can be retrieved on behalf of one or more entities. There is an implied owner entity associated to the object
+ when it is created. This entity should be used for normal data access.
+ For administrative operations data of other entities can be accessed.
+ The owner entity is the default entity for the backend.
+ For normal configuration data access the owner entity
+ should always be used.
+ The admin entity is an entity that should be used to
+ read and manage configuration data that applies to all entities
+ within the backend.
+ Must be one the identifiers returned by
+ XCompositeLayer::listSubLayerIds()
+ Subsequent calls describe the contents of the layer
+ until a matching call to XLayerHandler::endLayer()
+ is encountered.
+ Must match a previous call to XLayerHandler::startLayer().
+ Not every implementation can detect each condition Subsequent calls describe overrides to properties and members
+ or items of the node until a matching call to
+ XLayerHandler::endNode()is encountered.
+ The value is a combination of
+ NodeAttribute flags.
+ The attributes are combined cumulatively with those
+ set on lower layers.
+ Not every implementation can detect each condition The current node must be a set and
+ a preexisting item (if any) must be removable.
+ The new item will be created from the default template
+ of the set.
+ Subsequent calls describe the difference from the template
+ of properties and members or items of the node until
+ a matching call to XLayerHandler::endNode()
+ is encountered.
+ The value is a combination of
+ NodeAttribute flags. Note that
+ NodeAttribute::FUSE has an impact on the
+ semantics of this method.
+ Not every implementation can detect each condition The current node must be a set and
+ a preexisting item (if any) must be removable.
+ Subsequent calls describe the difference from the template
+ of properties and members or items of the node until
+ a matching call to XLayerHandler::endNode()
+ is encountered.
+ The value is a combination of
+ NodeAttribute flags. Note that
+ NodeAttribute::FUSE has an impact on the
+ semantics of this method.
+ Not every implementation can detect each condition Must match the last open call to
+ XLayerHandler::overrideNode(),
+ XLayerHandler::addOrReplaceNode() or
+ XLayerHandler::addOrReplaceNodeFromTemplate().
+ Not every implementation can detect each condition The current node must be a set and
+ the item must be removable.
+ Not every implementation can detect each condition Subsequent calls describe new value(s) for the property until a
+ matching call to XLayerHandler::endProperty()
+ is encountered.
+ The value is a combination of
+ NodeAttribute flags.
+ The attributes are combined cumulatively with those
+ set on lower layers.
+ This must be the same type as is already defined in the schema
+ or lower layers, unless the previous type was unspecified
+ (as indicated by
+ com::sun::star::uno::TypeClass::ANY.)
+ A `VOID` type indicates that the type is unspecified
+ in this layer.
+ In this case any subsequent value may be of a generic type
+ (e.g. `string` or - for list values -
+ `string[]`.) Such values may be
+ converted to the type defined in the schema by
+ the implementation.
+ Not every implementation can detect each condition The value must match the type of the current property.
+ If the property does not have the
+ SchemaAttribute::REQUIRED flag set,
+ the value can be `VOID`.
+ If the current property is localized, this value applies
+ to the default locale.
+ Not every implementation can detect each condition The value must match the type of the current property.
+ If the property does not have the
+ SchemaAttribute::REQUIRED flag set,
+ the value can be `VOID`.
+ Not every implementation can detect each condition Must match an open call to
+ XLayerHandler::overrideProperty(),
+ Not every implementation can detect each condition The current node must be extensible.
+ The value is a combination of
+ NodeAttribute flags and may also contain the
+ SchemaAttribute::REQUIRED flag.
+ NodeAttribute::MANDATORY need not be set,
+ as dynamically added properties always are mandatory
+ in subsequent layers.
+ Not every implementation can detect each condition The current node must be extensible.
+ The value is a combination of
+ NodeAttribute flags and may also contain the
+ SchemaAttribute::REQUIRED flag.
+
+
+ Not all implementations of XUpdatableLayer
+ support conversions of the replacement layer.
+ In such a case the sublayers of the provided layer may be ignored
+ or all simple data be merged into the main layer.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
NodeAttribute::MANDATORY need not be set, + as dynamic properties always are mandatory + in subsequent layers. +
+ + @param aValue + specifies the value of the new property. + +The value also determines the type. + Therefore the value must not be `VOID`. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void addPropertyWithValue( [in] string aName, + [in] short aAttributes, + [in] any aValue ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + +}; + + +}; }; }; }; }; + + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XLayerImporter.idl b/offapi/com/sun/star/configuration/backend/XLayerImporter.idl new file mode 100644 index 000000000..793227684 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XLayerImporter.idl @@ -0,0 +1,132 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_XLayerImporter_idl__ +#define __com_sun_star_configuration_backend_XLayerImporter_idl__ + +#includeThis method imports data for the current entity of the backend.
+ + @param aLayer + a layer whose data will be imported into the backend + + @throws com::sun::star::lang::NullPointerException + if the layer passed is `NULL` or no backend is available. + + @throws com::sun::star::configuration::backend::MalformedDataException + if the layer passed is invalid + + @throws com::sun::star::lang::IllegalArgumentException + if the layer passed is for a component + that doesn't exist in the backend + + @throws com::sun::star::lang::WrappedTargetException + if an error occurs in the backend or source layer. + + @see com::sun::star::configuration::backend::XBackend::getOwnUpdateHandler() + */ + void importLayer([in] XLayer aLayer) + raises (MalformedDataException, + com::sun::star::lang::IllegalArgumentException, + com::sun::star::lang::NullPointerException, + com::sun::star::lang::WrappedTargetException) ; + + + /** Imports the layer given into the backend for a given entity. + +This method imports data for the current entity of the backend.
+ + @param aLayer + a layer whose data will be imported into the backend + + @param aEntity + an entity into whose data the layer will be imported + + @throws com::sun::star::lang::NullPointerException + if the layer passed is `NULL` or no backend is available. + + @throws com::sun::star::configuration::backend::MalformedDataException + if the layer passed is invalid + + @throws com::sun::star::lang::IllegalArgumentException + if the layer passed is for a component + that doesn't exist in the backend + or if the entity doesn't exist in the backend. + + @throws com::sun::star::lang::WrappedTargetException + if an error occurs in the backend or source layer. + + @see com::sun::star::configuration::backend::XBackend::getUpdateHandler() + */ + void importLayerForEntity([in] XLayer aLayer, [in] string aEntity) + raises (MalformedDataException, + com::sun::star::lang::IllegalArgumentException, + com::sun::star::lang::NullPointerException, + com::sun::star::lang::WrappedTargetException) ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XMultiLayerStratum.idl b/offapi/com/sun/star/configuration/backend/XMultiLayerStratum.idl new file mode 100644 index 000000000..5c20f01bb --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XMultiLayerStratum.idl @@ -0,0 +1,314 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_XMultiLayerStratum_idl__ +#define __com_sun_star_configuration_backend_XMultiLayerStratum_idl__ + +#includeThe interface provides access to data for multiple entities and + timestamp-checking capabilities for efficient caching. +
+ + @see com::sun::star::configuration::backend::XBackendEntities + @see com::sun::star::util::XTimeStamped + @see com::sun::star::configuration::backend::XSchemaSupplier + @see com::sun::star::configuration::backend::XSingleLayerStratum + + @since OOo 1.1.2 +*/ +published interface XMultiLayerStratum : ::com::sun::star::uno::XInterface +{ + + /** + identifies the layers within this stratum which should be read and + merged to determine data of a component for an entity + + + @param aComponent + The name of the component to access. + + @param aEntity + The name of an entity on behalf of which data will be accessed. + + @return + a list of layer identifiers that can be used to + retrieve Layer objects. +The list is ordered by priority. Typically + the most general layers (global defaults, + entire organization) are first, more specific layers + (associated to specific groups or roles) are next + and the entity's own data is last. +
+ + @throws com::sun::star::lang::IllegalArgumentException + if the component identifier is invalid or + if the entity doesn't exist. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + + @see com::sun::star::configuration::backend::XMultiLayerStratum::getLayer() + @see com::sun::star::configuration::backend::XMultiLayerStratum::getLayers() + @see com::sun::star::configuration::backend::XMultiLayerStratum::getMultipleLayers() + @see com::sun::star::configuration::backend::XBackendEntities + */ + sequenceThe layer id returned is one of the layer ids obtained from + XMultiLayerStratum::listLayerIds() for the same + component and entity. +
+ + @param aComponent + The name of the component to access. + + @param aEntity + The name of an entity on behalf of which data will be accessed. + + @returns + a layer identifier that can be used to obtain + an UpdatableLayer object. + + @throws com::sun::star::lang::IllegalArgumentException + if the component identifier is invalid or + if the entity doesn't exist. + + @throws com::sun::star::lang::NoSupportException + if the implementation does not support updates. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + + @see com::sun::star::configuration::backend::XMultiLayerStratum::getUpdatableLayer() + @see com::sun::star::configuration::backend::XBackendEntities + */ + string getUpdateLayerId([in] string aComponent, + [in] string aEntity) + raises (BackendAccessException, + com::sun::star::lang::NoSupportException, + com::sun::star::lang::IllegalArgumentException) ; + + + /** + retrieves a layer associated to a layer id, if newer than indicated. + +A timestamp can be provided, which is used to indicate + a point in time. The layer should be returned only if is modified + since that time. +
+ + @param aLayerId + identifier of the layers to be accessed. +Layer ids can be obtained from + XMultiLayerStratum::listLayerIds() or + XMultiLayerStratum::getUpdateLayerId(). +
+ + @param aTimestamp + a timestamp for the layer. + +An empty timestamp indicates, that the layer should be + retrieved irrespective of its modification time. +
+The format and meaning of a timestamp depends on + the implementation. Timestamps can be obtained using + com::sun::star::util::XTimeStamped::getTimestamp(). +
+ + @returns + a Layer object providing access to the layer data, + `NULL` if the layer is newer than indicated by the timestamp. + + @throws com::sun::star::lang::IllegalArgumentException + if the layer id is invalid or + if the timestamp is invalid + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + + @see com::sun::star::util::XTimeStamped + */ + XLayer getLayer([in] string aLayerId, + [in] string aTimestamp) + raises (BackendAccessException, + com::sun::star::lang::IllegalArgumentException) ; + + + /** + retrieves the layers associated to a series of layer ids, + if newer than indicated. +A timestamp can be provided, which is used to indicate + a point in time. Only layers that are modified since that time + should be returned. The same timestamp is used for all layers. +
+ + @param aLayerIds + identifiers of the layers to be accessed. +Layer ids can be obtained from + XMultiLayerStratum::listLayerIds(). +
+ + @param aTimestamp + a timestamp for all of the layers. +An empty timestamp indicates, that the layers should be + retrieved irrespective of their modification time. +
+The format and meaning of a timestamp depends on + the implementation. Timestamps can be obtained using + com::sun::star::util::XTimeStamped::getTimestamp(). +
+ + @returns + a list of Layer objects + providing access to the layer data. +The list has the same length as aLayerIds. Each layer + object is associated to the layer id in the corresponding + position. +
+For layers that are newer than indicated by the + timestamp, the list contains a `NULL` element. +
+ + @throws com::sun::star::lang::IllegalArgumentException + if one of the layer ids is invalid or + if the timestamp is invalid + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + + @see com::sun::star::util::XTimeStamped + */ + sequenceFor each layer an individual timestamp can be provided, + which is used to indicate the last known version of the layer. + Only layers that are modified since that time should be returned. +
+ + @param aLayerIds + identifiers of the layers to be accessed. +Layer ids can be obtained from + XMultiLayerStratum::listLayerIds(). +
+ + @param aTimestamps + timestamps for each of the layers. + +This list must have the same length as aLayerIds. + Timestamps are matched to layer ids by their position. +
+An empty timestamp indicates, that the associated layer + should be retrieved irrespective of its modification time. +
+The format and meaning of a timestamp depends on + the implementation. Timestamps can be obtained using + com::sun::star::util::XTimeStamped::getTimestamp(). +
+ + @returns + a list of Layer objects + providing access to the layer data. +The list has the same length as aLayerIds. Each layer + object is associated to the layer id in the corresponding + position. +
+For layers that are newer than indicated by the corresponding + timestamp, the list contains a `NULL` element. +
+ + @throws com::sun::star::lang::IllegalArgumentException + if one of the layer ids is invalid or + if one of the timestamps is invalid or + if the lengths of the arguments don't match. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + + @see com::sun::star::util::XTimeStamped + */ + sequenceA layer id for writing can be obtained from + XMultiLayerStratum::getUpdateLayerId(). +
+ + @return + an UpdatableLayer object providing + write access to the layer + + @throws com::sun::star::lang::IllegalArgumentException + if the layer id is invalid. + + @throws com::sun::star::lang::NoSupportException + if the implementation does not support updates. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + */ + XUpdatableLayer getUpdatableLayer([in] string aLayerId) + raises (BackendAccessException, + com::sun::star::lang::NoSupportException, + com::sun::star::lang::IllegalArgumentException) ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XSchema.idl b/offapi/com/sun/star/configuration/backend/XSchema.idl new file mode 100644 index 000000000..606cadcbf --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XSchema.idl @@ -0,0 +1,121 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_XSchema_idl__ +#define __com_sun_star_configuration_backend_XSchema_idl__ + +#includeThe schema description may comprise components templates or both. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException + if a schema is already started (and has not been ended). + + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void startSchema( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that the current schema description is complete. + +Must match a previous call to startSchema(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endSchema( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that the schema depends on templates + from a different component. + + @param aName + specifies the name of the component. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void importComponent( [in] string aName ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a component description is started. + +Subsequent calls describe the schema of the component + until a matching call to endComponent() + is encountered. +
+ + @param aName + specifies the name of the component. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void startComponent( [in] string aName ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a component description is complete. + +Must match a previous call to startComponent(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endComponent( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a template description is started for a group. + +Subsequent calls describe the members and properties of the template + until a matching call to endTemplate() + is encountered. +
+ + @param aTemplate + specifies the identity of the template. + + @param aAttributes + specifies the attributes of the template. + +The value is a combination of + SchemaAttribute flags. +
+SchemaAttribute::EXTENSIBLE can be used + to describe a template for a node with an extensible + set of properties. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void startGroupTemplate( [in] TemplateIdentifier aTemplate, + [in] short aAttributes ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a template description is started for a set. + +Subsequent calls describe the members and properties of the template + until a matching call to endTemplate() + is encountered. +
+ + @param aTemplate + specifies the identity of the template. + + @param aAttributes + specifies the attributes of the template. + +The value is a combination of + SchemaAttribute flags. +
+SchemaAttribute::EXTENSIBLE can be used + to describe a template for a node with an extensible + set of properties. +
+ + @param aItemType + specifies the (default) template for set items. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void startSetTemplate( [in] TemplateIdentifier aTemplate, + [in] short aAttributes, + [in] TemplateIdentifier aItemType ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a template description is complete. + +Must match a previous call to startGroupTemplate() + or startSetTemplate(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endTemplate( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a group description is started. + +Subsequent calls describe the members and properties of the group + until a matching call to endNode() + is encountered. +
+ + @param aName + specifies the name of the group. + + @param aAttributes + specifies the attributes of the node. + +The value is a combination of + SchemaAttribute flags. +
+SchemaAttribute::EXTENSIBLE can be used + to describe a group with an extensible set of properties. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void startGroup( [in] string aName, + [in] short aAttributes ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a set description is started. + +Subsequent calls describe the item-types and properties of the set + until a matching call to endNode() + is encountered. +
+ + @param aName + specifies the name of the set. + + @param aAttributes + specifies the attributes of the node. + +The value is a combination of + SchemaAttribute flags. +
+SchemaAttribute::EXTENSIBLE can be used + to describe a set with an extensible set of properties. +
+ + @param aItemType + specifies the (default) template for set items. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void startSet( [in] string aName, + [in] short aAttributes, + [in] TemplateIdentifier aItemType ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a node description is complete. + +Must match the last open call to startGroup() + or startSet(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endNode( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a property is added to the current node. + +The property will have a default value of `NULL` + (unless it is SchemaAttribute::REQUIRED). +
+ + @param aName + specifies the name of the new property. + + @param aAttributes + specifies the attributes of the new property. + +The value is a combination of + SchemaAttribute flags. +
+ + @param aType + specifies the type of the new property. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void addProperty( [in] string aName, + [in] short aAttributes, + [in] type aType ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + + /** receives notification that a property having a default value + is added to the current node. + + @param aName + specifies the name of the new property. + + @param aAttributes + specifies the attributes of the new property. + +The value is a combination of + SchemaAttribute flags. +
+ + @param aDefaultValue + specifies the value of the new property. + +The value also determines the type. + Therefore the value must not be `VOID`. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void addPropertyWithDefault( [in] string aName, + [in] short aAttributes, + [in] any aDefaultValue ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + + /** receives notification that the current group has a child node + that is an instance of a specified template. + + @param aName + specifies the name of the new node. + + @param aTemplate + specifies a template that describes the new node. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void addInstance( [in] string aName, + [in] TemplateIdentifier aTemplate ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + + /** receives notification that the current set can contain items + that are instances of a specified template. + + @param aItemType + specifies a template that is accepted as valid item type + for the current set node. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void addItemType( [in] TemplateIdentifier aItemType ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + +}; + + +}; }; }; }; }; + + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XSchemaSupplier.idl b/offapi/com/sun/star/configuration/backend/XSchemaSupplier.idl new file mode 100644 index 000000000..6c7319006 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XSchemaSupplier.idl @@ -0,0 +1,67 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_XSchemaSupplier_idl__ +#define __com_sun_star_configuration_backend_XSchemaSupplier_idl__ + +#includeThe interface provides timestamp-checking capabilities + for efficient caching. +
+ + @see com::sun::star::util::XTimeStamped + @see com::sun::star::configuration::backend::XSchemaSupplier + @see com::sun::star::configuration::backend::XMultiLayerStratum + + @since OOo 1.1.2 +*/ +published interface XSingleLayerStratum : ::com::sun::star::uno::XInterface +{ + + /** + retrieves the layer data for a component, if newer than indicated. + +A timestamp can be provided, which is used to indicate + a point in time. The layer should be returned only if is modified + since that time. +
+ + @param aComponent + The name of the component to access. + + @param aTimestamp + a timestamp for the layer. + +An empty timestamp indicates, that the layer should be + retrieved irrespective of its modification time. +
+The format and meaning of a timestamp depends on + the implementation. Timestamps can be obtained using + com::sun::star::util::XTimeStamped::getTimestamp(). +
+ + @returns + a Layer object providing access to the layer data, + `NULL` if the layer is newer than indicated by the timestamp. + + @throws com::sun::star::lang::IllegalArgumentException + if the component identifier is invalid or + if the timestamp is invalid. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + + @see com::sun::star::util::XTimeStamped + */ + XLayer getLayer([in] string aComponent, + [in] string aTimestamp) + raises (BackendAccessException, + com::sun::star::lang::IllegalArgumentException) ; + + + /** + retrieves a writable representation of the layer for a component. + + @param aComponent + The name of the component to access. + + @return + an UpdatableLayer object providing + write access to the layer + + @throws com::sun::star::lang::IllegalArgumentException + if the component identifier is invalid. + + @throws com::sun::star::lang::NoSupportException + if the implementation does not support updates. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the data. + */ + XUpdatableLayer getUpdatableLayer([in] string aComponent) + raises (BackendAccessException, + com::sun::star::lang::NoSupportException, + com::sun::star::lang::IllegalArgumentException) ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XUpdatableLayer.idl b/offapi/com/sun/star/configuration/backend/XUpdatableLayer.idl new file mode 100644 index 000000000..dcc9e35ec --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XUpdatableLayer.idl @@ -0,0 +1,71 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ + +#ifndef __com_sun_star_configuration_backend_XUpdatableLayer_idl__ +#define __com_sun_star_configuration_backend_XUpdatableLayer_idl__ + +#includeAfter the replacement has been performed, reading the + layer will return the new content. Some implementations + may not support this, so after an update + XLayer::readData() may fail. +
+ + @param aNewLayer + replacement layer + + @throws com::sun::star::lang::NullPointerException + if a `NULL` handler is passed. + @throws com::sun::star::lang::WrappedTargetException + if an error occurs during the replacement. + @throws com::sun::star::configuration::backend::MalformedDataException + if the layer contains invalid data. + */ + void replaceWith([in] XLayer aNewLayer) + raises (com::sun::star::lang::NullPointerException, + com::sun::star::lang::WrappedTargetException, + MalformedDataException) ; + +} ; + +} ; } ; } ; } ; } ; +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XUpdateHandler.idl b/offapi/com/sun/star/configuration/backend/XUpdateHandler.idl new file mode 100644 index 000000000..5bff16437 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XUpdateHandler.idl @@ -0,0 +1,633 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_XUpdateHandler_idl__ +#define __com_sun_star_configuration_backend_XUpdateHandler_idl__ + +#includeSome implementations can only detect this when executing + XUpdateHandler::endUpdate() +
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void startUpdate( ) + raises( MalformedDataException, + com::sun::star::lang::IllegalAccessException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that the current update description is complete. + +Must match a previous call to XUpdateHandler::startUpdate(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::IllegalAccessException + if the target layer is read-only + + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endUpdate( ) + raises( MalformedDataException, + com::sun::star::lang::IllegalAccessException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a modification of a node is started. + +Subsequent calls describe changes to properties and items or + members of the node until a matching call to + XUpdateHandler::endNode() is encountered. +
+ + @param aName + specifies the name of the node. + + @param aAttributes + specifies attribute values to be applied to the node in the + current layer. + +The value is a combination of + NodeAttribute flags. +
+Only attributes which are selected in aAttributeMask + are changed. +
+ + @param aAttributeMask + specifies which attributes should be changed for the node. + +The value is a combination of + NodeAttribute flags. +
+ + @param bReset + if `TRUE`, specifies that the node should be reset to its default + state as given by lower layers and the schema or template prior + to applying the changes. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void modifyNode ( [in] string aName, + [in] short aAttributes, + [in] short aAttributeMask, + [in] boolean bReset ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a node is started as a new item. + +The current node must be a set and + a preexisting item (if any) must be removable. +
+The new item will be created from the default template + of the set. +
+Subsequent calls describe the difference from the template + of properties, items or members of the node until a matching call + to XUpdateHandler::endNode() is encountered. +
+ + @param aName + specifies the name of the new item. + + @param aAttributes + specifies attribute values to be applied to the new node. + +The value is a combination of + NodeAttribute flags. Note that + NodeAttribute::FUSE has an impact on the + semantics of this method. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void addOrReplaceNode ( [in] string aName, + [in] short aAttributes ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a node is started as a new item + based on a particular template. + +The current node must be a set and + a preexisting item (if any) must be removable. +
+Subsequent calls describe the difference from the template + of properties or members of the node until a matching call + to XUpdateHandler::endNode() is encountered. +
+ + @param aName + specifies the name of the item. + + @param aTemplate + specifies the template to use for the new node + + @param aAttributes + specifies attribute values to be applied to the new node. + +The value is a combination of + NodeAttribute flags. Note that + NodeAttribute::FUSE has an impact on the + semantics of this method. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void addOrReplaceNodeFromTemplate( [in] string aName, + [in] short aAttributes, + [in] TemplateIdentifier aTemplate ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a node modification is complete. + +Must match the last open call to + XUpdateHandler::modifyNode(), + XUpdateHandler::addOrReplaceNode() or + XUpdateHandler::addOrReplaceNodeFromTemplate(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endNode( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that an item is to be dropped from a set. + +The current node must be a set and + the item must be removable. +
+ + @param aName + specifies the name of the node. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void removeNode( [in] string aName ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that modification of an existing property is + started. + +Subsequent calls describe changes to the value(s) + of the property until a matching call to + XUpdateHandler::endProperty() is encountered. +
+ + @param aName + specifies the name of the property. + + @param aAttributes + specifies new attributes of the property. + +The value is a combination of + NodeAttribute flags. +
+Only attributes which are selected in aAttributeMask are changed. +
+NodeAttribute::MANDATORY need not be set + and can't be removed, as dynamic properties always are mandatory + in subsequent layers. +
+ + @param aAttributeMask + specifies which attributes should be changed for the property. + +The value is a combination of + NodeAttribute flags. +
+ + @param aType + specifies the type of the property. + +A `VOID` type can be used to signify that + the type is unknown and should not be recorded. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void modifyProperty( [in] string aName, + [in] short aAttributes, + [in] short aAttributeMask, + [in] type aType ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification about a change to the value of + the current property. + + @param aValue + specifies the new value of the property. + +The value must match the type of the existing property. + If the property does not have the + SchemaAttribute::REQUIRED flag set, + the value can be `VOID`. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void setPropertyValue( [in] any aValue ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification about a change to the value of + the current property for a specific locale. + + @param aValue + specifies the new value of the property for the given locale. + +The value must match the type of the existing property. + If the property does not have the + SchemaAttribute::REQUIRED flag set, + the value can be `VOID`. +
+ + @param aLocale + specifies the locale that the new value applies to. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void setPropertyValueForLocale( [in] any aValue, [in] string aLocale ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that the value of the current property + should be reset to its default. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void resetPropertyValue( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that the value of the current property + for a specific locale should be reset to its default. + + @param aLocale + specifies the locale the change applies to. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void resetPropertyValueForLocale( [in] string aLocale ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a property modification is complete. + +Must match the last open call to + XUpdateHandler::modifyProperty(). +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void endProperty( ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a property is reset to its default state. + + @param aName + specifies the name of the property. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::NodeAttribute + */ + void resetProperty( [in] string aName ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a property having a value of `VOID` + is added to the current node. + +The current node must be extensible and + a preexisting property (if any) must be + removable in this layer. +
+ + @param aName + specifies the name of the new property. + + @param aAttributes + specifies the attributes of the new property. + +The value is a combination of + NodeAttribute flags and may also contain the + SchemaAttribute::REQUIRED flag. +
+ +NodeAttribute::MANDATORY need not be set, + as dynamic properties always are mandatory + in subsequent layers. +
+ + @param aType + specifies the type of the new property. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void addOrReplaceProperty( [in] string aName, + [in] short aAttributes, + [in] type aType ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a property having a non-`NULL` value + is added to the current node. + +The current node must be extensible and + a preexisting property (if any) must be + removable in this layer. +
+ + @param aName + specifies the name of the new property. + + @param aAttributes + specifies the attributes of the new property. + +The value is a combination of + NodeAttribute flags and may also contain the + SchemaAttribute::REQUIRED flag. +
+ +NodeAttribute::MANDATORY need not be set, + as dynamic properties always are mandatory + in subsequent layers. +
+ + @param aValue + specifies the value of the new property. + +The value also determines the type. + Therefore the value must not be `VOID`. +
+ + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + + @see com::sun::star::configuration::backend::SchemaAttribute + */ + void addOrReplacePropertyWithValue( [in] string aName, + [in] short aAttributes, + [in] any aValue ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + + /** receives notification that a property is dropped from the current node. + +The current node must be extensible and the property removable.
+ + @param aName + specifies the name of the property. + + @throws com::sun::star::configuration::backend::MalformedDataException +Not every implementation can detect each condition
+ + @throws com::sun::star::lang::WrappedTargetException + if an error occurs processing the event. + */ + void removeProperty( [in] string aName ) + raises( MalformedDataException, + com::sun::star::lang::WrappedTargetException ); + +}; + + +}; }; }; }; }; + + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/XVersionedSchemaSupplier.idl b/offapi/com/sun/star/configuration/backend/XVersionedSchemaSupplier.idl new file mode 100644 index 000000000..9d8e83167 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/XVersionedSchemaSupplier.idl @@ -0,0 +1,78 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_XVersionedSchemaSupplier_idl__ +#define __com_sun_star_configuration_backend_XVersionedSchemaSupplier_idl__ + +#includeThe format of the version string is arbitrary. No meaning + should be attached to it, unless an implementing service + defines one. If no version can be determined, an empty + `string` may be returned. +
+ +Clients may assume that all instances of a schema with the + same version are identical. The converse is not true. + In particular an implementation may return the same version + string for all schemas it supplies (i.e. return a version for + the complete schema, including all components) +
+ + @throws com::sun::star::lang::IllegalArgumentException + if the component identifier is invalid. + + @throws com::sun::star::configuration::backend::BackendAccessException + if an error occurs while accessing the version data. + */ + string getSchemaVersion([in] string aComponent) + raises (BackendAccessException, + com::sun::star::lang::IllegalArgumentException) ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/xml/LayerParser.idl b/offapi/com/sun/star/configuration/backend/xml/LayerParser.idl new file mode 100644 index 000000000..53a90edcd --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/xml/LayerParser.idl @@ -0,0 +1,77 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_xml_LayerParser_idl__ +#define __com_sun_star_configuration_backend_xml_LayerParser_idl__ + +#includeThe configuration layer XML from a given stream is parsed and fed to a + com::sun::star::configuration::backend::XLayerHandler. +
+ + @see com::sun::star::configuration::backend::xml::SchemaParser + Service that represents a configuration schema stored in XML. + + @see com::sun::star::configuration::backend::xml::LayerWriter + Service that writes OOR Update XML for data described via + com::sun::star::configuration::backend::XLayerHandler. + + @since OOo 1.1.2 +*/ +published service LayerParser +{ + + /** provides access to the parsed layer data. + */ + interface com::sun::star::configuration::backend::XLayer ; + + + /** provides access to the source XML stream. + */ + interface com::sun::star::io::XActiveDataSink ; + + + /** allows initializing the source stream. + +The source can be passed + as a com::sun::star::io::XInputStream or + as a com::sun::star::xml::sax::InputSource. +
+ */ + interface com::sun::star::lang::XInitialization ; + +} ; + +} ; +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/xml/LayerWriter.idl b/offapi/com/sun/star/configuration/backend/xml/LayerWriter.idl new file mode 100644 index 000000000..6e3a30c08 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/xml/LayerWriter.idl @@ -0,0 +1,72 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_xml_LayerWriter_idl__ +#define __com_sun_star_configuration_backend_xml_LayerWriter_idl__ + +#includeThe configuration layer data described to a + com::sun::star::configuration::backend::XLayerHandler + is written to a stream as OOR Update XML. +
+ + @see com::sun::star::configuration::backend::xml::LayerParser + Service that parses configuration layer XML. + + @since OOo 1.1.2 +*/ +published service LayerWriter +{ + + /** accepts events describing the layer data. + */ + interface com::sun::star::configuration::backend::XLayerHandler ; + + + /** provides access to the target stream. + */ + interface com::sun::star::io::XActiveDataSource ; + + + /** allows initializing target stream. + +The target can be passed + as a com::sun::star::io::XOutputStream. +
+ */ + interface com::sun::star::lang::XInitialization ; + +} ; + +} ; +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/backend/xml/SchemaParser.idl b/offapi/com/sun/star/configuration/backend/xml/SchemaParser.idl new file mode 100644 index 000000000..e8f600425 --- /dev/null +++ b/offapi/com/sun/star/configuration/backend/xml/SchemaParser.idl @@ -0,0 +1,72 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_backend_xml_SchemaParser_idl__ +#define __com_sun_star_configuration_backend_xml_SchemaParser_idl__ + +#includeThe configuration schema XML from a given stream is parsed and fed to a + com::sun::star::configuration::backend::XSchemaHandler. +
+ + @see com::sun::star::configuration::backend::xml::LayerParser + Service that parses configuration layer XML. + + @since OOo 1.1.2 +*/ +published service SchemaParser +{ + + /** provides access to the parsed schema data. + */ + interface com::sun::star::configuration::backend::XSchema ; + + + /** provides access to the source XML stream. + */ + interface com::sun::star::io::XActiveDataSink ; + + + /** allows initializing the source stream. + +The source can be passed + as a com::sun::star::io::XInputStream or + as a com::sun::star::xml::sax::InputSource. +
+ */ + interface com::sun::star::lang::XInitialization ; + +} ; + +} ; +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/bootstrap/BootstrapContext.idl b/offapi/com/sun/star/configuration/bootstrap/BootstrapContext.idl new file mode 100644 index 000000000..1e488492f --- /dev/null +++ b/offapi/com/sun/star/configuration/bootstrap/BootstrapContext.idl @@ -0,0 +1,65 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ +#ifndef __com_sun_star_configuration_bootstrap_BootstrapContext_idl__ +#define __com_sun_star_configuration_bootstrap_BootstrapContext_idl__ + +#includeThe contained settings are used to initialize the + com::sun::star::configuration::DefaultProvider and + com::sun::star::configuration::backend::DefaultBackend of the + component context. +
+The implementation is usually available as a singleton in the context + that it wraps... +
+ + @since OOo 1.1.2 + + @deprecated +*/ +published service BootstrapContext +{ + + /** + provides access to metaconfiguration data. + +Some values are retrieved from external metaconfiguration, + if they are not overridden in the wrapped context. +
+ */ + interface com::sun::star::uno::XComponentContext ; + +} ; + + +} ; } ; } ; } ; } ; + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/offapi/com/sun/star/configuration/theDefaultProvider.idl b/offapi/com/sun/star/configuration/theDefaultProvider.idl new file mode 100644 index 000000000..16e280ee3 --- /dev/null +++ b/offapi/com/sun/star/configuration/theDefaultProvider.idl @@ -0,0 +1,35 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#ifndef _COM_SUN_STAR_CONFIGURATION_THEDEFAULTPROVIDER_IDL +#define _COM_SUN_STAR_CONFIGURATION_THEDEFAULTPROVIDER_IDL + +module com { module sun { module star { module lang { + published interface XMultiServiceFactory; +}; }; }; }; + +module com { module sun { module star { module configuration { + +/** + The default ConfigurationProvider. + +This singleton somewhat arbitrarily makes available the + com::sun::star::lang::XMultiServiceFactory interface of + the (old-style) DefaultProvider service, as it is the most + frequently used one. See the DefaultProvider service for + details.
+ + @since OOo 1.1.2 +*/ +published singleton theDefaultProvider: + com::sun::star::lang::XMultiServiceFactory; + +}; }; }; }; + +#endif -- cgit v1.2.3