summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2018-01-07 12:05:53 +0900
committerTomaž Vajngerl <quikee@gmail.com>2018-01-07 09:34:44 +0100
commite1fb3d95ac6d58b60448981e82d90621cad7fea5 (patch)
tree0a409b12d7356847cde99572589ccc6953529e57 /include
parent27da558d7c1fe45b58d0bcc28b961fabbc5f2f1a (diff)
Remove XmlWriter in test module and use tools::XmlWriter
Change-Id: I0a0e07a6a71ed95d783d35b7d94b857074ec3450 Reviewed-on: https://gerrit.libreoffice.org/47523 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include')
-rw-r--r--include/test/mtfxmldump.hxx6
-rw-r--r--include/test/primitive2dxmldump.hxx7
-rw-r--r--include/test/xmlwriter.hxx49
-rw-r--r--include/tools/XmlWriter.hxx2
4 files changed, 8 insertions, 56 deletions
diff --git a/include/test/mtfxmldump.hxx b/include/test/mtfxmldump.hxx
index 38087d6f8f3a..b55de95258db 100644
--- a/include/test/mtfxmldump.hxx
+++ b/include/test/mtfxmldump.hxx
@@ -12,20 +12,20 @@
#include <sal/config.h>
#include <test/testdllapi.hxx>
-
#include <libxml/tree.h>
#include <vcl/gdimtf.hxx>
#include <vcl/metaactiontypes.hxx>
#include <o3tl/enumarray.hxx>
-class XmlWriter;
+namespace tools { class XmlWriter; }
+
enum class MetaActionType;
class OOO_DLLPUBLIC_TEST MetafileXmlDump final
{
o3tl::enumarray<MetaActionType, bool> maFilter;
- void writeXml(const GDIMetaFile& rMetaFile, XmlWriter& rWriter);
+ void writeXml(const GDIMetaFile& rMetaFile, tools::XmlWriter& rWriter);
public:
MetafileXmlDump();
diff --git a/include/test/primitive2dxmldump.hxx b/include/test/primitive2dxmldump.hxx
index 80ef271ee720..5acf69999ecd 100644
--- a/include/test/primitive2dxmldump.hxx
+++ b/include/test/primitive2dxmldump.hxx
@@ -12,18 +12,17 @@
#include <sal/config.h>
#include <test/testdllapi.hxx>
-#include <test/xmlwriter.hxx>
-
#include <libxml/tree.h>
#include <drawinglayer/primitive2d/baseprimitive2d.hxx>
-
#include <vector>
+namespace tools { class XmlWriter; }
+
class OOO_DLLPUBLIC_TEST Primitive2dXmlDump final
{
private:
std::vector<bool> maFilter;
- void decomposeAndWrite(const drawinglayer::primitive2d::Primitive2DContainer& rPrimitive2DSequence, XmlWriter& rWriter);
+ void decomposeAndWrite(const drawinglayer::primitive2d::Primitive2DContainer& rPrimitive2DSequence, tools::XmlWriter& rWriter);
public:
Primitive2dXmlDump();
diff --git a/include/test/xmlwriter.hxx b/include/test/xmlwriter.hxx
deleted file mode 100644
index 96a5314d8d48..000000000000
--- a/include/test/xmlwriter.hxx
+++ /dev/null
@@ -1,49 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#ifndef INCLUDED_TEST_XMLWRITER_HXX
-#define INCLUDED_TEST_XMLWRITER_HXX
-
-#include <test/testdllapi.hxx>
-
-#include <libxml/xmlwriter.h>
-#include <rtl/ustring.hxx>
-#include <rtl/string.hxx>
-
-class SvStream;
-
-class OOO_DLLPUBLIC_TEST XmlWriter final
-{
-private:
- SvStream* mpStream;
- xmlTextWriterPtr mpWriter;
-
-public:
- XmlWriter(SvStream* pStream);
- ~XmlWriter();
-
- void startDocument();
- void endDocument();
-
- void element(const OString& sTagName);
-
- void startElement(const OString& sTagName);
- void endElement();
-
- void attribute(const OString& sTagName, const OString& aValue);
- void attribute(const OString& sTagName, const OUString& aValue);
- void attribute(const OString& sTagName, sal_Int32 aNumber);
-
- void content(const OString& aValue);
- void content(const OUString& aValue);
-};
-
-#endif // INCLUDED_TEST_XMLWRITER_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/tools/XmlWriter.hxx b/include/tools/XmlWriter.hxx
index 15a3a0013912..8224df417f1b 100644
--- a/include/tools/XmlWriter.hxx
+++ b/include/tools/XmlWriter.hxx
@@ -49,6 +49,8 @@ public:
void content(const OString& sValue);
void content(const OUString& sValue);
+
+ void element(const OString& sName);
};
} // end tools namespace