android: Update app-specific/MIME type icons
[LibreOffice.git] / writerfilter / source / ooxml / Handler.hxx
blobdf6673d44318ce820c386f190d7362e0de22c8f4
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
19 #pragma once
21 #include <dmapper/resourcemodel.hxx>
22 #include "OOXMLFastContextHandler.hxx"
24 namespace writerfilter::ooxml
26 class OOXMLFootnoteHandler : public Properties
28 OOXMLFastContextHandler* mpFastContext;
30 public:
31 explicit OOXMLFootnoteHandler(OOXMLFastContextHandler* pContext);
32 virtual ~OOXMLFootnoteHandler() override;
34 virtual void attribute(Id name, Value& val) override;
35 virtual void sprm(Sprm& sprm) override;
38 class OOXMLEndnoteHandler : public Properties
40 OOXMLFastContextHandler* mpFastContext;
42 public:
43 explicit OOXMLEndnoteHandler(OOXMLFastContextHandler* pContext);
44 virtual ~OOXMLEndnoteHandler() override;
46 virtual void attribute(Id name, Value& val) override;
47 virtual void sprm(Sprm& sprm) override;
50 class OOXMLFooterHandler : public Properties
52 OOXMLFastContextHandler* mpFastContext;
53 OUString msStreamId;
54 sal_Int32 mnType;
56 public:
57 explicit OOXMLFooterHandler(OOXMLFastContextHandler* pContext);
58 void finalize();
59 virtual void attribute(Id name, Value& val) override;
60 virtual void sprm(Sprm& sprm) override;
63 class OOXMLHeaderHandler : public Properties
65 OOXMLFastContextHandler* mpFastContext;
66 OUString msStreamId;
67 sal_Int32 mnType;
69 public:
70 explicit OOXMLHeaderHandler(OOXMLFastContextHandler* pContext);
71 void finalize();
72 virtual void attribute(Id name, Value& val) override;
73 virtual void sprm(Sprm& sprm) override;
76 class OOXMLCommentHandler : public Properties
78 OOXMLFastContextHandler* mpFastContext;
80 public:
81 explicit OOXMLCommentHandler(OOXMLFastContextHandler* pContext);
82 virtual ~OOXMLCommentHandler() override;
83 virtual void attribute(Id name, Value& val) override;
84 virtual void sprm(Sprm& sprm) override;
87 class OOXMLOLEHandler : public Properties
89 OOXMLFastContextHandler* mpFastContext;
91 public:
92 explicit OOXMLOLEHandler(OOXMLFastContextHandler* pContext);
93 virtual ~OOXMLOLEHandler() override;
95 virtual void attribute(Id name, Value& val) override;
96 virtual void sprm(Sprm& sprm) override;
99 class OOXMLEmbeddedFontHandler : public Properties
101 OOXMLFastContextHandler* mpFastContext;
103 public:
104 explicit OOXMLEmbeddedFontHandler(OOXMLFastContextHandler* pContext);
105 virtual ~OOXMLEmbeddedFontHandler() override;
107 virtual void attribute(Id name, Value& val) override;
108 virtual void sprm(Sprm& sprm) override;
111 class OOXMLBreakHandler : public Properties
113 sal_Int32 mnType;
114 OOXMLFastContextHandler* mpFastContext;
115 Stream& mrStream;
117 public:
118 explicit OOXMLBreakHandler(OOXMLFastContextHandler* pContext, Stream& rStream);
119 virtual ~OOXMLBreakHandler() override;
120 virtual void attribute(Id name, Value& val) override;
121 virtual void sprm(Sprm& sprm) override;
124 class OOXMLPictureHandler : public Properties
126 OOXMLFastContextHandler* mpFastContext;
128 public:
129 explicit OOXMLPictureHandler(OOXMLFastContextHandler* pContext);
130 virtual ~OOXMLPictureHandler() override;
132 virtual void attribute(Id name, Value& val) override;
133 virtual void sprm(Sprm& sprm) override;
136 class OOXMLHyperlinkHandler : public Properties
138 OOXMLFastContextHandler* mpFastContext;
139 OUString mFieldCode;
140 OUString mURL;
142 public:
143 explicit OOXMLHyperlinkHandler(OOXMLFastContextHandler* pContext);
144 virtual ~OOXMLHyperlinkHandler() override;
145 void writetext();
147 virtual void attribute(Id name, Value& val) override;
148 virtual void sprm(Sprm& sprm) override;
151 class OOXMLHyperlinkURLHandler : public Properties
153 OOXMLFastContextHandler* mpFastContext;
154 OUString mURL;
156 public:
157 explicit OOXMLHyperlinkURLHandler(OOXMLFastContextHandler* pContext);
158 virtual ~OOXMLHyperlinkURLHandler() override;
160 virtual void attribute(Id name, Value& val) override;
161 virtual void sprm(Sprm& sprm) override;
164 /// Looks up the stream name for a '<w:altChunk r:id="..."/>' reference.
165 class OOXMLAltChunkHandler : public Properties
167 OOXMLFastContextHandler* mpFastContext;
168 OUString m_aStreamName;
170 public:
171 explicit OOXMLAltChunkHandler(OOXMLFastContextHandler* pContext);
172 virtual ~OOXMLAltChunkHandler() override;
174 virtual void attribute(Id name, Value& val) override;
175 virtual void sprm(Sprm& sprm) override;
179 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */