1 /************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 #ifndef _XMLOFF_XFORMSIMPORT_HXX 24 #define _XMLOFF_XFORMSIMPORT_HXX 25 26 #include "sal/config.h" 27 #include "xmloff/dllapi.h" 28 29 #include <tools/solar.h> // for sal_uInt16 30 #include <com/sun/star/uno/Reference.hxx> 31 32 class SvXMLImport; 33 class SvXMLImportContext; 34 namespace rtl { class OUString; } 35 36 #if defined(WNT) && _MSC_VER < 1400 37 namespace std { template<typename A, typename B> struct pair; } 38 #endif 39 40 namespace com { namespace sun { namespace star { 41 namespace uno { template<typename T> class Reference; } 42 namespace beans { class XPropertySet; struct PropertyValue; } 43 namespace frame { class XModel; } 44 namespace container { class XNameAccess; } 45 } } } 46 47 /** create import context for xforms:model element. */ 48 XMLOFF_DLLPUBLIC SvXMLImportContext* createXFormsModelContext( 49 SvXMLImport& rImport, 50 sal_uInt16 nPrefix, 51 const rtl::OUString& rLocalName ); 52 53 /** perform the actual binding of an XForms-binding with the suitable control 54 * @param document which contains the XForms-model(s) 55 * @param pair<XForms binding ID, reference to control> 56 */ 57 void bindXFormsValueBinding( 58 com::sun::star::uno::Reference<com::sun::star::frame::XModel>, 59 std::pair<com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet>,rtl::OUString> ); 60 61 62 /** perform the actual binding of an XForms-binding as list source with a list control 63 * @param document which contains the XForms-model(s) 64 * @param pair<XForms binding ID, reference to control> 65 */ 66 void bindXFormsListBinding( 67 com::sun::star::uno::Reference<com::sun::star::frame::XModel>, 68 std::pair<com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet>,rtl::OUString> ); 69 70 /** perform the actual binding of an XForms submission with the suitable control 71 * @param document which contains the XForms-model(s) 72 * @param pair<XForms submission ID, reference to control> 73 */ 74 void bindXFormsSubmission( 75 com::sun::star::uno::Reference<com::sun::star::frame::XModel>, 76 std::pair<com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet>,rtl::OUString> ); 77 78 /** applies the given settings to the given XForms container 79 */ 80 void XMLOFF_DLLPUBLIC applyXFormsSettings( 81 const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _rXForms, 82 const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _rSettings 83 ); 84 85 #endif 86 87 88