Apache OpenOffice (AOO) Bugzilla – Issue 118124
css.configuration.ConfigurationUpdateAccess - missing XPropertyWithState/XMultiPropertyStates
Last modified: 2013-01-29 21:54:27 UTC
the following code worked in oo 3.2 but will fail in oo3.4beta. seems com::sun::star::beans::XPropertyWithState and com::sun::star::beans::XMultiPropertyStates are missing ? Sub TestConfigUpdateAccess() Dim aConfigProvider as Object Dim aConfig as Object Dim obj as Object Dim mProps(1) as new com.sun.star.beans.PropertyValue aConfigProvider = createUnoService("com.sun.star.configuration.ConfigurationProvider") mProps(0).Name = "nodepath" mProps(0).Value = "org.openoffice.Office.Views" aConfig = aConfigProvider.createInstanceWithArguments("com.sun.star.configuration.ConfigurationUpdateAccess", mProps()) obj = aConfig.getByHierarchicalName("Windows") if hasUnoInterfaces(obj, "com.sun.star.beans.XPropertyWithState") then obj.setToDefaultAsProperty() else Msgbox "???" endif aConfig.commitChanges() End Sub
confirming with aoo 3.4m1 r1236920
The implementation is "org.openoffice-configmgr::Access" in configmgr::Access trunk/main/configmgr/source/access.hxx trunk/main/configmgr/source/access.cxx http://svn.apache.org/viewvc/incubator/ooo/trunk/main/configmgr/source/access.hxx?revision=1198417&view=markup#l99 That class implements only following interfaces: public com::sun::star::beans::XExactName, public com::sun::star::beans::XHierarchicalPropertySet, public com::sun::star::beans::XHierarchicalPropertySetInfo, public com::sun::star::beans::XMultiHierarchicalPropertySet, public com::sun::star::beans::XMultiPropertySet, public com::sun::star::beans::XProperty, public com::sun::star::beans::XPropertySet, public com::sun::star::beans::XPropertySetInfo, public com::sun::star::container::XContainer, public com::sun::star::container::XHierarchicalName, public com::sun::star::container::XHierarchicalNameAccess, public com::sun::star::container::XNameContainer, public com::sun::star::container::XNamed, public com::sun::star::lang::XComponent, public com::sun::star::lang::XServiceInfo, public com::sun::star::lang::XSingleServiceFactory, public com::sun::star::lang::XTypeProvider, The ones you mention are missing. * XPropertyWithState: Services which Support this Interface ::com::sun::star::configuration::AccessRootElement ::com::sun::star::configuration::ConfigurationAccess ::com::sun::star::configuration::ConfigurationUpdateAccess ::com::sun::star::configuration::GroupElement ::com::sun::star::configuration::SetElement ::com::sun::star::configuration::UpdateRootElement all services include ::com::sun::star::configuration::HierarchyElement where ::com::sun::star::beans::XPropertyWithState is marked as OPTIONAL: http://www.openoffice.org/api/docs/common/ref/com/sun/star/configuration/HierarchyElement.html#XPropertyWithState * XMultiPropertyStates: Services which Support this Interface ::com::sun::star::configuration::ConfigurationAccess ::com::sun::star::configuration::ConfigurationUpdateAccess ::com::sun::star::configuration::GroupAccess ::com::sun::star::configuration::GroupUpdate ::com::sun::star::configuration::HierarchyAccess This interface is also marked as OPTIONAL in http://www.openoffice.org/api/docs/common/ref/com/sun/star/configuration/HierarchyAccess.html#XMultiPropertyStates Conclusion: this cannot be considered a regression. It is indeed an incompatible change, but these are marked as to be implemented optionally.
It's indeed not nice and I assume these interfaces were removed during the config manager rework. Because of the fact that they were not used in the office and optional the developer has removed them or better has not implemented them again. I think it is no show stopper for 3.4 But can you give further details in which scenario you use this interfaces and the API's? It would be good to know for further considerations if we bring it back or not. I would prefer if we could drop it. But we need further info. It's always the questions of effort.
> I think it is no show stopper for 3.4 i agree > But can you give further details in which > scenario you use this interfaces and the API's? good question, i remember we had some trouble with oo3.3 and our java extensions. root cause was the incompatible change of the new "org.openoffice-configmgr" implementation. btw i found this thread: http://www.mail-archive.com/dev@framework.openoffice.org/msg00951.html
getting rid of value "enhancement" for field "severity". For enhancement the field "issue type" shall be used.