Update ooo320-m1
[ooovba.git] / xmloff / source / table / tabledesignsimporter.cxx
blob986a1d9585a31fafb1057236b63b902d2cbd27fd
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: tabledesignsimporter.cxx,v $
10 * $Revision: 1.3 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 // MARKER(update_precomp.py): autogen include statement, do not remove
32 #include "precompiled_xmloff.hxx"
34 #include <com/sun/star/style/XStyleFamiliesSupplier.hpp>
35 #include <com/sun/star/table/XTableRows.hpp>
36 #include <com/sun/star/table/XMergeableCell.hpp>
37 #include <com/sun/star/table/XMergeableCellRange.hpp>
38 #include <com/sun/star/table/XTable.hpp>
39 #include <com/sun/star/text/XText.hpp>
40 #include <com/sun/star/container/XNameContainer.hpp>
41 #include <com/sun/star/lang/XSingleServiceFactory.hpp>
43 #include "xmloff/table/XMLTableImport.hxx"
44 #include "xmloff/xmltkmap.hxx"
45 #include "xmloff/maptype.hxx"
46 #include "xmloff/xmlprmap.hxx"
47 #include "xmloff/txtimp.hxx"
48 #include "xmloff/xmlimp.hxx"
49 #include "xmloff/nmspmap.hxx"
50 #include "xmloff/xmlstyle.hxx"
51 #include "xmloff/prstylei.hxx"
52 #include "xmloff/xmlimp.hxx"
54 #include "xmlnmspe.hxx"
55 #include "table.hxx"
57 #include <boost/shared_ptr.hpp>
59 // --------------------------------------------------------------------
61 using ::rtl::OUString;
62 using namespace ::xmloff::token;
63 using namespace ::com::sun::star::beans;
64 using namespace ::com::sun::star::uno;
65 using namespace ::com::sun::star::table;
66 using namespace ::com::sun::star::xml::sax;
67 using namespace ::com::sun::star::text;
68 using namespace ::com::sun::star::style;
69 using namespace ::com::sun::star::lang;
70 using namespace ::com::sun::star::container;
72 // --------------------------------------------------------------------
74 class TabelDesignsImporter : public SvXMLImport
76 TabelDesignsImporter( const Reference< XMultiServiceFactory > & rSMgr );
77 ~TabelDesignsImporter() throw ();
79 SvXMLImportContext* CreateContext(USHORT nPrefix, const OUString& rLocalName, const Reference<XAttributeList>& xAttrList);
82 // --------------------------------------------------------------------
84 TabelDesignsImporter::TabelDesignsImporter( const Reference< XMultiServiceFactory > & rSMgr )
85 : SvXMLImport( rSMgr, true )
87 // add namespaces
88 GetNamespaceMap().Add(
89 GetXMLToken(XML_NP_PRESENTATION),
90 GetXMLToken(XML_N_PRESENTATION),
91 XML_NAMESPACE_PRESENTATION);
94 // --------------------------------------------------------------------
96 TabelDesignsImporter::~TabelDesignsImporter()
100 // --------------------------------------------------------------------
102 SvXMLImportContext* TabelDesignsImporter::CreateContext(USHORT nPrefix, const OUString& rLocalName, const Reference<XAttributeList>& xAttrList)
106 // --------------------------------------------------------------------