build fix: no comphelper/profilezone.hxx in this branch
[LibreOffice.git] / xmloff / inc / XMLChartPropertySetMapper.hxx
blobf5cc42fd5f31cf4c99d55b2ad1bb621cc078fc8f
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 #ifndef INCLUDED_XMLOFF_INC_XMLCHARTPROPERTYSETMAPPER_HXX
20 #define INCLUDED_XMLOFF_INC_XMLCHARTPROPERTYSETMAPPER_HXX
22 #include <xmloff/xmlprmap.hxx>
23 #include <xmloff/xmlexppr.hxx>
24 #include <xmloff/xmlimppr.hxx>
25 #include <xmloff/xmlimp.hxx>
27 extern const XMLPropertyMapEntry aXMLChartPropMap[];
29 class SvXMLExport;
31 class XMLChartPropHdlFactory : public XMLPropertyHandlerFactory
33 public:
34 virtual ~XMLChartPropHdlFactory() override;
35 virtual const XMLPropertyHandler* GetPropertyHandler( sal_Int32 nType ) const override;
38 class XMLChartPropertySetMapper : public XMLPropertySetMapper
40 public:
41 explicit XMLChartPropertySetMapper( bool bForExport );
42 virtual ~XMLChartPropertySetMapper() override;
45 class XMLChartExportPropertyMapper : public SvXMLExportPropertyMapper
47 private:
48 SvXMLExport& mrExport;
49 css::uno::Reference< css::chart2::XChartDocument > mxChartDoc;
51 protected:
52 virtual void ContextFilter(
53 bool bEnableFoFontFamily,
54 ::std::vector< XMLPropertyState >& rProperties,
55 const css::uno::Reference<css::beans::XPropertySet >& rPropSet ) const override;
57 private:
58 /// this method is called for every item that has the MID_FLAG_ELEMENT_EXPORT flag set
59 virtual void handleElementItem(
60 SvXMLExport& rExport,
61 const XMLPropertyState& rProperty, SvXmlExportFlags nFlags,
62 const ::std::vector< XMLPropertyState > *pProperties,
63 sal_uInt32 nIdx ) const override;
65 /// this method is called for every item that has the MID_FLAG_SPECIAL_ITEM_EXPORT flag set
66 virtual void handleSpecialItem(
67 SvXMLAttributeList& rAttrList, const XMLPropertyState& rProperty,
68 const SvXMLUnitConverter& rUnitConverter, const SvXMLNamespaceMap& rNamespaceMap,
69 const ::std::vector< XMLPropertyState > *pProperties,
70 sal_uInt32 nIdx ) const override;
72 public:
73 XMLChartExportPropertyMapper( const rtl::Reference< XMLPropertySetMapper >& rMapper,
74 SvXMLExport& rExport );
75 virtual ~XMLChartExportPropertyMapper() override;
77 void setChartDoc( const css::uno::Reference< css::chart2::XChartDocument >& xChartDoc );
80 class XMLChartImportPropertyMapper : public SvXMLImportPropertyMapper
82 private:
83 SvXMLImport& mrImport;
85 public:
86 XMLChartImportPropertyMapper( const rtl::Reference< XMLPropertySetMapper >& rMapper,
87 const SvXMLImport& rImport );
88 virtual ~XMLChartImportPropertyMapper() override;
90 virtual bool handleSpecialItem(
91 XMLPropertyState& rProperty,
92 ::std::vector< XMLPropertyState >& rProperties,
93 const OUString& rValue,
94 const SvXMLUnitConverter& rUnitConverter,
95 const SvXMLNamespaceMap& rNamespaceMap ) const override;
97 virtual void finished(
98 ::std::vector< XMLPropertyState >& rProperties,
99 sal_Int32 nStartIndex, sal_Int32 nEndIndex ) const override;
102 #endif // INCLUDED_XMLOFF_INC_XMLCHARTPROPERTYSETMAPPER_HXX
104 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */