Branch libreoffice-5-0-4
[LibreOffice.git] / include / test / primitive2dxmldump.hxx
bloba578e60f7596ed8030c6f720f8ab75a94e11ac15
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_PRIMITIVE2DXMLDUMP_HXX
11 #define INCLUDED_TEST_PRIMITIVE2DXMLDUMP_HXX
13 #include <sal/config.h>
14 #include <test/testdllapi.hxx>
15 #include <test/xmlwriter.hxx>
17 #include <libxml/tree.h>
18 #include <drawinglayer/primitive2d/baseprimitive2d.hxx>
20 #include <vector>
22 class OOO_DLLPUBLIC_TEST Primitive2dXmlDump
24 private:
25 std::vector<bool> maFilter;
26 void decomposeAndWrite(const drawinglayer::primitive2d::Primitive2DSequence& rPrimitive2DSequence, XmlWriter& rWriter);
28 public:
29 Primitive2dXmlDump();
30 virtual ~Primitive2dXmlDump();
32 void filterActionType(const sal_uInt16 nActionType, bool bShouldFilter);
33 void filterAllActionTypes();
35 /** The actual result that will be used for testing.
37 This function normally uses a SvMemoryStream for its operation; but
38 can use a physical file when a filename is specified in
39 pTempStreamName - this is useful when creating the test, to dump the
40 file for examination.
42 xmlDocPtr dumpAndParse(const drawinglayer::primitive2d::Primitive2DSequence& aPrimitive2DSequence, const OUString& rTempStreamName = OUString());
45 #endif // INCLUDED_TEST_PRIMITIVE2DXMLDUMP_HXX
47 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */