Branch libreoffice-5-0-4
[LibreOffice.git] / include / test / mtfxmldump.hxx
blob6fc24e61992e5f17ff809a9d6faaf39f2358bcd1
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/.
8 */
10 #ifndef INCLUDED_TEST_MTFXMLDUMP_HXX
11 #define INCLUDED_TEST_MTFXMLDUMP_HXX
13 #include <sal/config.h>
14 #include <test/testdllapi.hxx>
16 #include <libxml/tree.h>
17 #include <vcl/gdimtf.hxx>
18 #include <vcl/metaactiontypes.hxx>
19 #include <o3tl/enumarray.hxx>
21 class XmlWriter;
22 enum class MetaActionType;
24 class OOO_DLLPUBLIC_TEST MetafileXmlDump
26 o3tl::enumarray<MetaActionType, bool> maFilter;
28 void writeXml(const GDIMetaFile& rMetaFile, XmlWriter& rWriter);
30 public:
31 MetafileXmlDump();
32 virtual ~MetafileXmlDump();
34 void filterActionType(const MetaActionType nActionType, bool bShouldFilter);
35 void filterAllActionTypes();
37 /** The actual result that will be used for testing.
39 This function normally uses a SvMemoryStream for its operation; but
40 can use a physical file when a filename is specified in
41 pTempStreamName - this is useful when creating the test, to dump the
42 file for examination.
44 xmlDocPtr dumpAndParse(const GDIMetaFile& rMetaFile, const OUString& rTempStreamName = OUString());
47 #endif
49 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */