Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*
3 : : * This file is part of the LibreOffice project.
4 : : *
5 : : * This Source Code Form is subject to the terms of the Mozilla Public
6 : : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : : *
9 : : * This file incorporates work covered by the following license notice:
10 : : *
11 : : * Licensed to the Apache Software Foundation (ASF) under one or more
12 : : * contributor license agreements. See the NOTICE file distributed
13 : : * with this work for additional information regarding copyright
14 : : * ownership. The ASF licenses this file to you under the Apache
15 : : * License, Version 2.0 (the "License"); you may not use this file
16 : : * except in compliance with the License. You may obtain a copy of
17 : : * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 : : */
19 : :
20 : : #ifndef _XMLOFF_XMLFOOTNOTEIMPORTCONTEXT_HXX_
21 : : #define _XMLOFF_XMLFOOTNOTEIMPORTCONTEXT_HXX_
22 : :
23 : : #include <xmloff/xmlictxt.hxx>
24 : : #include <com/sun/star/uno/Reference.h>
25 : :
26 : :
27 : : namespace com { namespace sun { namespace star {
28 : : namespace text {
29 : : class XTextCursor;
30 : : class XFootnote;
31 : : }
32 : : namespace xml { namespace sax {
33 : : class XAttributeList;
34 : : } }
35 : : } } }
36 : : namespace rtl {
37 : : class OUString;
38 : : }
39 : : class XMLTextImportHelper;
40 : :
41 : : /// import footnote elements (<text:footnote>)
42 [ - + ]: 6 : class XMLFootnoteImportContext : public SvXMLImportContext
43 : : {
44 : : const ::rtl::OUString sPropertyReferenceId;
45 : :
46 : : /// old document cursor
47 : : ::com::sun::star::uno::Reference<
48 : : ::com::sun::star::text::XTextCursor> xOldCursor;
49 : :
50 : : /// old list item and block (#89891#)
51 : : bool mbListContextPushed;
52 : :
53 : : /// text import helper; holds current XTextCursor (and XText)
54 : : XMLTextImportHelper& rHelper;
55 : :
56 : : /// the footnote
57 : : ::com::sun::star::uno::Reference<
58 : : ::com::sun::star::text::XFootnote> xFootnote;
59 : :
60 : : public:
61 : :
62 : : TYPEINFO();
63 : :
64 : : XMLFootnoteImportContext(
65 : : SvXMLImport& rImport,
66 : : XMLTextImportHelper& rHlp,
67 : : sal_uInt16 nPrfx,
68 : : const ::rtl::OUString& rLocalName );
69 : :
70 : : protected:
71 : :
72 : : virtual void StartElement(
73 : : const ::com::sun::star::uno::Reference<
74 : : ::com::sun::star::xml::sax::XAttributeList> & xAttrList);
75 : :
76 : : virtual void Characters(
77 : : const ::rtl::OUString& rChars);
78 : :
79 : : virtual void EndElement();
80 : :
81 : : virtual SvXMLImportContext *CreateChildContext(
82 : : sal_uInt16 nPrefix,
83 : : const ::rtl::OUString& rLocalName,
84 : : const ::com::sun::star::uno::Reference<
85 : : ::com::sun::star::xml::sax::XAttributeList> & xAttrList );
86 : :
87 : : };
88 : :
89 : : #endif
90 : :
91 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|