summaryrefslogtreecommitdiff
path: root/xmloff
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2014-07-25 10:58:15 -0400
committerKohei Yoshida <kohei.yoshida@collabora.com>2014-07-25 11:50:02 -0400
commit8a690c88a92c7e92c702cedf96851ae1eb929379 (patch)
treeb72472b0e9188e5ab524886d3486457f3892b14e /xmloff
parent0198b3a9451700d875c1b389d30e1a0cc9ab4b47 (diff)
Apply pimpl to XMLPropertySetMapper.
Let's hide its implementation for real this time. Change-Id: I18c82f4969f2e3560536a68e9bbd86b9282e2ace
Diffstat (limited to 'xmloff')
-rw-r--r--xmloff/inc/XMLElementPropertyContext.hxx1
-rw-r--r--xmloff/source/chart/SchXMLExport.cxx11
-rw-r--r--xmloff/source/chart/SchXMLTools.cxx1
-rw-r--r--xmloff/source/chart/XMLChartStyleContext.cxx2
-rw-r--r--xmloff/source/draw/XMLGraphicsDefaultStyle.cxx4
-rw-r--r--xmloff/source/draw/ximpbody.cxx1
-rw-r--r--xmloff/source/forms/elementexport.cxx1
-rw-r--r--xmloff/source/forms/layerexport.cxx2
-rw-r--r--xmloff/source/style/PageHeaderFooterContext.cxx1
-rw-r--r--xmloff/source/style/PageMasterPropMapper.cxx2
-rw-r--r--xmloff/source/style/prstylei.cxx2
-rw-r--r--xmloff/source/style/styleexp.cxx1
-rw-r--r--xmloff/source/style/xmlaustp.cxx1
-rw-r--r--xmloff/source/style/xmlexppr.cxx21
-rw-r--r--xmloff/source/style/xmlimppr.cxx2
-rw-r--r--xmloff/source/style/xmlprcon.cxx7
-rw-r--r--xmloff/source/style/xmlprmap.cxx155
-rw-r--r--xmloff/source/table/XMLTableExport.cxx7
-rw-r--r--xmloff/source/text/XMLTextShapeStyleContext.cxx2
-rw-r--r--xmloff/source/text/txtexppr.cxx1
-rw-r--r--xmloff/source/text/txtflde.cxx13
-rw-r--r--xmloff/source/text/txtimp.cxx2
-rw-r--r--xmloff/source/text/txtimppr.cxx1
-rw-r--r--xmloff/source/text/txtparae.cxx1
-rw-r--r--xmloff/source/text/txtprmap.cxx2
-rw-r--r--xmloff/source/text/txtstyli.cxx1
26 files changed, 197 insertions, 48 deletions
diff --git a/xmloff/inc/XMLElementPropertyContext.hxx b/xmloff/inc/XMLElementPropertyContext.hxx
index 00771eaa3a74..f89630badd08 100644
--- a/xmloff/inc/XMLElementPropertyContext.hxx
+++ b/xmloff/inc/XMLElementPropertyContext.hxx
@@ -22,6 +22,7 @@
#include <xmloff/xmlprmap.hxx>
#include <xmloff/xmlictxt.hxx>
+#include <xmloff/maptype.hxx>
class SvXMLImport;
diff --git a/xmloff/source/chart/SchXMLExport.cxx b/xmloff/source/chart/SchXMLExport.cxx
index 743db2a36d18..fc52354c459f 100644
--- a/xmloff/source/chart/SchXMLExport.cxx
+++ b/xmloff/source/chart/SchXMLExport.cxx
@@ -1178,18 +1178,15 @@ void SchXMLExportHelper_Impl::parseDocument( Reference< chart::XChartDocument >&
{
try
{
- Any aAny( xDocPropSet->getPropertyValue(
- OUString( "HasMainTitle" )));
+ Any aAny = xDocPropSet->getPropertyValue("HasMainTitle");
aAny >>= bHasMainTitle;
- aAny = xDocPropSet->getPropertyValue(
- OUString( "HasSubTitle" ));
+ aAny = xDocPropSet->getPropertyValue("HasSubTitle");
aAny >>= bHasSubTitle;
- aAny = xDocPropSet->getPropertyValue(
- OUString( "HasLegend" ));
+ aAny = xDocPropSet->getPropertyValue("HasLegend");
aAny >>= bHasLegend;
if ( bIncludeTable )
{
- OUString sNullDate( "NullDate" );
+ OUString sNullDate("NullDate");
aAny = xDocPropSet->getPropertyValue(sNullDate);
if ( !aAny.hasValue() )
{
diff --git a/xmloff/source/chart/SchXMLTools.cxx b/xmloff/source/chart/SchXMLTools.cxx
index 05acf10f4607..891e7bded80f 100644
--- a/xmloff/source/chart/SchXMLTools.cxx
+++ b/xmloff/source/chart/SchXMLTools.cxx
@@ -29,6 +29,7 @@
#include <xmloff/xmlexp.hxx>
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmlmetai.hxx>
+#include <xmloff/maptype.hxx>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>
diff --git a/xmloff/source/chart/XMLChartStyleContext.cxx b/xmloff/source/chart/XMLChartStyleContext.cxx
index 52e6ea0812b0..cc7b285e1c21 100644
--- a/xmloff/source/chart/XMLChartStyleContext.cxx
+++ b/xmloff/source/chart/XMLChartStyleContext.cxx
@@ -22,6 +22,8 @@
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmlnumfi.hxx>
#include <xmloff/families.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <tools/debug.hxx>
#include "XMLChartPropertyContext.hxx"
diff --git a/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx b/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx
index 64ca80cd4860..bcca5b8af057 100644
--- a/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx
+++ b/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx
@@ -27,8 +27,10 @@
#include <xmloff/nmspmap.hxx>
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmltoken.hxx>
-
#include <xmloff/families.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/maptype.hxx>
+
#include "XMLShapePropertySetContext.hxx"
using namespace ::com::sun::star;
diff --git a/xmloff/source/draw/ximpbody.cxx b/xmloff/source/draw/ximpbody.cxx
index 530fa8758203..c1f8f0824faa 100644
--- a/xmloff/source/draw/ximpbody.cxx
+++ b/xmloff/source/draw/ximpbody.cxx
@@ -36,6 +36,7 @@
#include "ximpshow.hxx"
#include "PropertySetMerger.hxx"
#include "animationimport.hxx"
+#include <tools/debug.hxx>
using namespace ::com::sun::star;
diff --git a/xmloff/source/forms/elementexport.cxx b/xmloff/source/forms/elementexport.cxx
index c30699d675e2..71128474db50 100644
--- a/xmloff/source/forms/elementexport.cxx
+++ b/xmloff/source/forms/elementexport.cxx
@@ -54,6 +54,7 @@
#include <xmloff/XMLEventExport.hxx>
#include <xmloff/xmluconv.hxx>
#include <xmloff/xmltoken.hxx>
+#include <xmloff/maptype.hxx>
#include <tools/time.hxx>
#include <tools/diagnose_ex.h>
#include <comphelper/extract.hxx>
diff --git a/xmloff/source/forms/layerexport.cxx b/xmloff/source/forms/layerexport.cxx
index 9ccccf6065b2..8b13c07f4f5e 100644
--- a/xmloff/source/forms/layerexport.cxx
+++ b/xmloff/source/forms/layerexport.cxx
@@ -30,7 +30,9 @@
#include <xmloff/families.hxx>
#include <xmloff/contextid.hxx>
#include <xmloff/controlpropertyhdl.hxx>
+#include <xmloff/maptype.hxx>
#include <tools/diagnose_ex.h>
+#include <tools/debug.hxx>
#include "controlpropertymap.hxx"
#include <com/sun/star/container/XIndexAccess.hpp>
#include <com/sun/star/form/XFormsSupplier2.hpp>
diff --git a/xmloff/source/style/PageHeaderFooterContext.cxx b/xmloff/source/style/PageHeaderFooterContext.cxx
index 8cb1e2f32189..155338cb335b 100644
--- a/xmloff/source/style/PageHeaderFooterContext.cxx
+++ b/xmloff/source/style/PageHeaderFooterContext.cxx
@@ -20,6 +20,7 @@
#include "PageHeaderFooterContext.hxx"
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmltoken.hxx>
+#include <xmloff/xmltypes.hxx>
#include "PagePropertySetContext.hxx"
using namespace com::sun::star;
diff --git a/xmloff/source/style/PageMasterPropMapper.cxx b/xmloff/source/style/PageMasterPropMapper.cxx
index de1fecfc9917..fde6964f4247 100644
--- a/xmloff/source/style/PageMasterPropMapper.cxx
+++ b/xmloff/source/style/PageMasterPropMapper.cxx
@@ -22,6 +22,8 @@
#include <xmloff/PageMasterStyleMap.hxx>
#include "PageMasterPropHdlFactory.hxx"
+#include <com/sun/star/beans/XPropertySet.hpp>
+
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
diff --git a/xmloff/source/style/prstylei.cxx b/xmloff/source/style/prstylei.cxx
index 3dfbb37931bc..77a2fcffff5f 100644
--- a/xmloff/source/style/prstylei.cxx
+++ b/xmloff/source/style/prstylei.cxx
@@ -33,6 +33,8 @@
#include <xmloff/prstylei.hxx>
#include <xmloff/attrlist.hxx>
#include <xmloff/xmlerror.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/maptype.hxx>
//UUUU
#include <com/sun/star/drawing/FillStyle.hpp>
diff --git a/xmloff/source/style/styleexp.cxx b/xmloff/source/style/styleexp.cxx
index 03ac10749ed7..bba026359e13 100644
--- a/xmloff/source/style/styleexp.cxx
+++ b/xmloff/source/style/styleexp.cxx
@@ -38,6 +38,7 @@
#include <xmloff/styleexp.hxx>
#include <xmloff/xmlexp.hxx>
#include <xmloff/XMLEventExport.hxx>
+#include <xmloff/maptype.hxx>
#include <set>
#include <boost/scoped_ptr.hpp>
diff --git a/xmloff/source/style/xmlaustp.cxx b/xmloff/source/style/xmlaustp.cxx
index 67f26ec4a556..3358486d75d8 100644
--- a/xmloff/source/style/xmlaustp.cxx
+++ b/xmloff/source/style/xmlaustp.cxx
@@ -25,6 +25,7 @@
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmlexp.hxx>
+#include <xmloff/xmlprhdl.hxx>
#include <xmloff/XMLTextListAutoStylePool.hxx>
#include <xmloff/PageMasterStyleMap.hxx>
diff --git a/xmloff/source/style/xmlexppr.cxx b/xmloff/source/style/xmlexppr.cxx
index 11487677aced..6f62661696b3 100644
--- a/xmloff/source/style/xmlexppr.cxx
+++ b/xmloff/source/style/xmlexppr.cxx
@@ -19,7 +19,6 @@
#include <com/sun/star/container/XNameContainer.hpp>
#include <com/sun/star/xml/AttributeData.hpp>
-#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/XPropertyState.hpp>
#include <com/sun/star/beans/XMultiPropertySet.hpp>
#include <com/sun/star/beans/XTolerantMultiPropertySet.hpp>
@@ -35,6 +34,9 @@
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmlexp.hxx>
#include <xmloff/xmlprmap.hxx>
+#include <xmloff/maptype.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/xmlprhdl.hxx>
using namespace ::std;
using namespace ::com::sun::star;
@@ -568,9 +570,20 @@ void SvXMLExportPropertyMapper::ChainExportMapper(
}
}
-vector< XMLPropertyState > SvXMLExportPropertyMapper::_Filter(
- const Reference< XPropertySet > xPropSet,
- bool bDefault, bool bEnableFoFontFamily) const
+std::vector<XMLPropertyState> SvXMLExportPropertyMapper::Filter(
+ const uno::Reference<beans::XPropertySet>& rPropSet, bool bEnableFoFontFamily ) const
+{
+ return _Filter(rPropSet, false, bEnableFoFontFamily);
+}
+
+std::vector<XMLPropertyState> SvXMLExportPropertyMapper::FilterDefaults(
+ const uno::Reference<beans::XPropertySet>& rPropSet, bool bEnableFoFontFamily ) const
+{
+ return _Filter(rPropSet, true, bEnableFoFontFamily);
+}
+
+vector<XMLPropertyState> SvXMLExportPropertyMapper::_Filter(
+ const Reference<XPropertySet>& xPropSet, bool bDefault, bool bEnableFoFontFamily ) const
{
vector< XMLPropertyState > aPropStateArray;
diff --git a/xmloff/source/style/xmlimppr.cxx b/xmloff/source/style/xmlimppr.cxx
index 9b7f11a76251..9e2d07052800 100644
--- a/xmloff/source/style/xmlimppr.cxx
+++ b/xmloff/source/style/xmlimppr.cxx
@@ -35,6 +35,8 @@
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmlerror.hxx>
#include <xmloff/contextid.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/maptype.hxx>
#include <algorithm>
#include <functional>
diff --git a/xmloff/source/style/xmlprcon.cxx b/xmloff/source/style/xmlprcon.cxx
index f8b12df73a54..b96bec798b6c 100644
--- a/xmloff/source/style/xmlprcon.cxx
+++ b/xmloff/source/style/xmlprcon.cxx
@@ -17,11 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-#include <xmloff/xmlimp.hxx>
-
-
#include <xmloff/xmlprcon.hxx>
-
+#include <xmloff/xmlimp.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/maptype.hxx>
using namespace ::com::sun::star;
using namespace ::std;
diff --git a/xmloff/source/style/xmlprmap.cxx b/xmloff/source/style/xmlprmap.cxx
index c0d98b6cc96e..dcc9c28e4be1 100644
--- a/xmloff/source/style/xmlprmap.cxx
+++ b/xmloff/source/style/xmlprmap.cxx
@@ -17,15 +17,22 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-#include <tools/debug.hxx>
-#include <xmloff/xmlprhdl.hxx>
-#include "xmlbahdl.hxx"
#include <xmloff/xmlprmap.hxx>
+#include <xmloff/xmlprhdl.hxx>
#include <xmloff/xmltypes.hxx>
+#include <xmloff/xmltoken.hxx>
+#include <xmloff/maptype.hxx>
+#include <xmloff/prhdlfac.hxx>
+#include <tools/debug.hxx>
+
+#include "xmlbahdl.hxx"
+
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/XPropertyState.hpp>
#include <com/sun/star/uno/Any.hxx>
-#include <xmloff/xmltoken.hxx>
+#include <com/sun/star/uno/Sequence.hxx>
+
+#include <vector>
using namespace ::std;
@@ -33,6 +40,39 @@ using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using ::xmloff::token::GetXMLToken;
+/** Helper-class for XML-im/export:
+ - Holds a pointer to a given array of XMLPropertyMapEntry
+ - Provides several methods to access data from this array
+ - Holds a Sequence of XML-names (for properties)
+ - The filter takes all properties of the XPropertySet which are also
+ in the XMLPropertyMapEntry and which are have not a default value
+ and put them into a vector of XMLPropertyStae
+ - this class knows how to compare, im/export properties
+
+ Attention: At all methods, which get an index as parameter, there is no
+ range validation to save runtime !!
+*/
+struct XMLPropertySetMapperEntry_Impl
+{
+ OUString sXMLAttributeName;
+ OUString sAPIPropertyName;
+ sal_Int32 nType;
+ sal_uInt16 nXMLNameSpace;
+ sal_Int16 nContextId;
+ SvtSaveOptions::ODFDefaultVersion nEarliestODFVersionForExport;
+ bool bImportOnly;
+ const XMLPropertyHandler *pHdl;
+
+ XMLPropertySetMapperEntry_Impl(
+ const XMLPropertyMapEntry& rMapEntry,
+ const rtl::Reference< XMLPropertyHandlerFactory >& rFactory );
+
+ XMLPropertySetMapperEntry_Impl(
+ const XMLPropertySetMapperEntry_Impl& rEntry );
+
+ sal_uInt32 GetPropType() const { return nType & XML_TYPE_PROP_MASK; }
+};
+
XMLPropertySetMapperEntry_Impl::XMLPropertySetMapperEntry_Impl(
const XMLPropertyMapEntry& rMapEntry,
const rtl::Reference< XMLPropertyHandlerFactory >& rFactory ) :
@@ -62,27 +102,35 @@ XMLPropertySetMapperEntry_Impl::XMLPropertySetMapperEntry_Impl(
DBG_ASSERT( pHdl, "Unknown XML property type handler!" );
}
+struct XMLPropertySetMapper::Impl
+{
+ std::vector<XMLPropertySetMapperEntry_Impl> maMapEntries;
+ std::vector<rtl::Reference <XMLPropertyHandlerFactory> > maHdlFactories;
+
+ bool mbOnlyExportMappings;
+
+ Impl( bool bForExport ) : mbOnlyExportMappings(bForExport) {}
+};
+
// Ctor
XMLPropertySetMapper::XMLPropertySetMapper(
- const XMLPropertyMapEntry* pEntries,
- const rtl::Reference< XMLPropertyHandlerFactory >& rFactory,
- bool bForExport )
- :
- mbOnlyExportMappings( bForExport)
+ const XMLPropertyMapEntry* pEntries, const rtl::Reference<XMLPropertyHandlerFactory>& rFactory,
+ bool bForExport ) :
+ mpImpl(new Impl(bForExport))
{
- aHdlFactories.push_back( rFactory );
+ mpImpl->maHdlFactories.push_back(rFactory);
if( pEntries )
{
const XMLPropertyMapEntry* pIter = pEntries;
- if (mbOnlyExportMappings)
+ if (mpImpl->mbOnlyExportMappings)
{
while( pIter->msApiName )
{
if (!pIter->mbImportOnly)
{
XMLPropertySetMapperEntry_Impl aEntry( *pIter, rFactory );
- aMapEntries.push_back( aEntry );
+ mpImpl->maMapEntries.push_back( aEntry );
}
pIter++;
}
@@ -92,7 +140,7 @@ XMLPropertySetMapper::XMLPropertySetMapper(
while( pIter->msApiName )
{
XMLPropertySetMapperEntry_Impl aEntry( *pIter, rFactory );
- aMapEntries.push_back( aEntry );
+ mpImpl->maMapEntries.push_back( aEntry );
pIter++;
}
}
@@ -101,29 +149,86 @@ XMLPropertySetMapper::XMLPropertySetMapper(
XMLPropertySetMapper::~XMLPropertySetMapper()
{
+ delete mpImpl;
}
void XMLPropertySetMapper::AddMapperEntry(
const rtl::Reference < XMLPropertySetMapper >& rMapper )
{
for( vector < rtl::Reference < XMLPropertyHandlerFactory > >::iterator
- aFIter = rMapper->aHdlFactories.begin();
- aFIter != rMapper->aHdlFactories.end();
+ aFIter = rMapper->mpImpl->maHdlFactories.begin();
+ aFIter != rMapper->mpImpl->maHdlFactories.end();
++aFIter )
{
- aHdlFactories.push_back( *aFIter );
+ mpImpl->maHdlFactories.push_back(*aFIter);
}
for( vector < XMLPropertySetMapperEntry_Impl >::iterator
- aEIter = rMapper->aMapEntries.begin();
- aEIter != rMapper->aMapEntries.end();
+ aEIter = rMapper->mpImpl->maMapEntries.begin();
+ aEIter != rMapper->mpImpl->maMapEntries.end();
++aEIter )
{
- if (!mbOnlyExportMappings || !(*aEIter).bImportOnly)
- aMapEntries.push_back( *aEIter );
+ if (!mpImpl->mbOnlyExportMappings || !(*aEIter).bImportOnly)
+ mpImpl->maMapEntries.push_back( *aEIter );
}
}
+sal_Int32 XMLPropertySetMapper::GetEntryCount() const
+{
+ return mpImpl->maMapEntries.size();
+}
+
+sal_uInt32 XMLPropertySetMapper::GetEntryFlags( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= 0) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return mpImpl->maMapEntries[nIndex].nType & ~MID_FLAG_MASK;
+}
+
+sal_uInt32 XMLPropertySetMapper::GetEntryType( sal_Int32 nIndex, bool bWithFlags ) const
+{
+ DBG_ASSERT( (nIndex >= 0) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ sal_uInt32 nType = mpImpl->maMapEntries[nIndex].nType;
+ if( !bWithFlags )
+ nType = nType & MID_FLAG_MASK;
+ return nType;
+}
+
+sal_uInt16 XMLPropertySetMapper::GetEntryNameSpace( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= 0) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return mpImpl->maMapEntries[nIndex].nXMLNameSpace;
+}
+
+const OUString& XMLPropertySetMapper::GetEntryXMLName( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= 0) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return mpImpl->maMapEntries[nIndex].sXMLAttributeName;
+}
+
+const OUString& XMLPropertySetMapper::GetEntryAPIName( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= 0) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return mpImpl->maMapEntries[nIndex].sAPIPropertyName;
+}
+
+sal_Int16 XMLPropertySetMapper::GetEntryContextId( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= -1) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return nIndex == -1 ? 0 : mpImpl->maMapEntries[nIndex].nContextId;
+}
+
+SvtSaveOptions::ODFDefaultVersion XMLPropertySetMapper::GetEarliestODFVersionForExport( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= -1) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return nIndex == -1 ? SvtSaveOptions::ODFVER_UNKNOWN : mpImpl->maMapEntries[nIndex].nEarliestODFVersionForExport;
+}
+
+const XMLPropertyHandler* XMLPropertySetMapper::GetPropertyHandler( sal_Int32 nIndex ) const
+{
+ DBG_ASSERT( (nIndex >= 0) && (nIndex < (sal_Int32)mpImpl->maMapEntries.size() ), "illegal access to invalid entry!" );
+ return mpImpl->maMapEntries[nIndex].pHdl;
+}
+
// Export a Property
bool XMLPropertySetMapper::exportXML(
OUString& rStrExpValue,
@@ -175,7 +280,7 @@ sal_Int32 XMLPropertySetMapper::GetEntryIndex(
{
do
{
- const XMLPropertySetMapperEntry_Impl& rEntry = aMapEntries[nIndex];
+ const XMLPropertySetMapperEntry_Impl& rEntry = mpImpl->maMapEntries[nIndex];
if( (!nPropType || nPropType == rEntry.GetPropType()) &&
rEntry.nXMLNameSpace == nNamespace &&
rStrName == rEntry.sXMLAttributeName )
@@ -200,7 +305,7 @@ sal_Int32 XMLPropertySetMapper::FindEntryIndex(
do
{
- const XMLPropertySetMapperEntry_Impl& rEntry = aMapEntries[nIndex];
+ const XMLPropertySetMapperEntry_Impl& rEntry = mpImpl->maMapEntries[nIndex];
if( rEntry.nXMLNameSpace == nNameSpace &&
rEntry.sXMLAttributeName.equals( sXMLName ) &&
rEntry.sAPIPropertyName.equalsAscii( sApiName ) )
@@ -222,7 +327,7 @@ sal_Int32 XMLPropertySetMapper::FindEntryIndex( const sal_Int16 nContextId ) con
sal_Int32 nIndex = 0;
do
{
- const XMLPropertySetMapperEntry_Impl& rEntry = aMapEntries[nIndex];
+ const XMLPropertySetMapperEntry_Impl& rEntry = mpImpl->maMapEntries[nIndex];
if( rEntry.nContextId == nContextId )
return nIndex;
else
@@ -239,10 +344,10 @@ void XMLPropertySetMapper::RemoveEntry( sal_Int32 nIndex )
const sal_Int32 nEntries = GetEntryCount();
if( nIndex>=nEntries || nIndex<0 )
return;
- vector < XMLPropertySetMapperEntry_Impl >::iterator aEIter = aMapEntries.begin();
+ vector < XMLPropertySetMapperEntry_Impl >::iterator aEIter = mpImpl->maMapEntries.begin();
for( sal_Int32 nN=0; nN<nIndex; nN++ )
++aEIter;
- aMapEntries.erase( aEIter );
+ mpImpl->maMapEntries.erase( aEIter );
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/xmloff/source/table/XMLTableExport.cxx b/xmloff/source/table/XMLTableExport.cxx
index 5bbee2c47b67..7c5631d995e1 100644
--- a/xmloff/source/table/XMLTableExport.cxx
+++ b/xmloff/source/table/XMLTableExport.cxx
@@ -17,6 +17,8 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <xmloff/table/XMLTableExport.hxx>
+
#include <xmloff/dllapi.h>
#include <sal/config.h>
@@ -36,11 +38,14 @@
#include <com/sun/star/style/XStyle.hpp>
#include <com/sun/star/beans/XPropertySetInfo.hpp>
-#include <xmloff/table/XMLTableExport.hxx>
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmlprmap.hxx>
#include <xmloff/xmlexppr.hxx>
#include <xmloff/xmlexp.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/maptype.hxx>
+#include <xmloff/prhdlfac.hxx>
+#include <tools/debug.hxx>
#include "table.hxx"
using namespace ::xmloff::token;
diff --git a/xmloff/source/text/XMLTextShapeStyleContext.cxx b/xmloff/source/text/XMLTextShapeStyleContext.cxx
index 0c341fe8a09f..4e29e07d6d2b 100644
--- a/xmloff/source/text/XMLTextShapeStyleContext.cxx
+++ b/xmloff/source/text/XMLTextShapeStyleContext.cxx
@@ -28,6 +28,8 @@
#include "XMLTextColumnsContext.hxx"
#include "XMLBackgroundImageContext.hxx"
#include <xmloff/txtprmap.hxx>
+#include <xmloff/xmltypes.hxx>
+#include <xmloff/maptype.hxx>
#include <xmloff/XMLTextShapeStyleContext.hxx>
diff --git a/xmloff/source/text/txtexppr.cxx b/xmloff/source/text/txtexppr.cxx
index edc98a8fe57c..98638907015d 100644
--- a/xmloff/source/text/txtexppr.cxx
+++ b/xmloff/source/text/txtexppr.cxx
@@ -29,6 +29,7 @@
#include <tools/debug.hxx>
#include <xmloff/txtprmap.hxx>
#include <xmloff/xmlexp.hxx>
+#include <xmloff/maptype.hxx>
#include "XMLSectionFootnoteConfigExport.hxx"
//UUUU
diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx
index 607a1d211dad..36341bd01bc5 100644
--- a/xmloff/source/text/txtflde.cxx
+++ b/xmloff/source/text/txtflde.cxx
@@ -23,18 +23,19 @@
* export of all text fields
*/
#include "txtflde.hxx"
+#include <xmloff/XMLEventExport.hxx>
+#include <xmloff/families.hxx>
+#include <xmloff/nmspmap.hxx>
+#include <xmloff/numehelp.hxx>
+#include <xmloff/xmlement.hxx>
#include <xmloff/xmlexp.hxx>
+#include <xmloff/xmlnume.hxx>
#include <xmloff/xmlnumfe.hxx>
#include <xmloff/xmltoken.hxx>
-#include <xmloff/xmlement.hxx>
#include <xmloff/xmluconv.hxx>
-#include <xmloff/xmlnume.hxx>
-#include <xmloff/numehelp.hxx>
+#include <xmloff/maptype.hxx>
-#include <xmloff/families.hxx>
-#include <xmloff/XMLEventExport.hxx>
#include "XMLTextCharStyleNamesElementExport.hxx"
-#include <xmloff/nmspmap.hxx>
#include <sax/tools/converter.hxx>
#include <com/sun/star/util/DateTime.hpp>
diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx
index ebefde2cfcae..297b871afd5c 100644
--- a/xmloff/source/text/txtimp.cxx
+++ b/xmloff/source/text/txtimp.cxx
@@ -33,6 +33,8 @@
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/txtstyli.hxx>
#include <xmloff/xmlnumi.hxx>
+#include <tools/debug.hxx>
+#include <xmloff/maptype.hxx>
#include "txtparai.hxx"
#include <xmloff/txtprmap.hxx>
diff --git a/xmloff/source/text/txtimppr.cxx b/xmloff/source/text/txtimppr.cxx
index 36fb328eabc7..b2007635a614 100644
--- a/xmloff/source/text/txtimppr.cxx
+++ b/xmloff/source/text/txtimppr.cxx
@@ -28,6 +28,7 @@
#include <xmloff/txtprmap.hxx>
#include <xmloff/xmlimp.hxx>
#include <xmloff/txtimppr.hxx>
+#include <xmloff/maptype.hxx>
#define XML_LINE_LEFT 0
#define XML_LINE_RIGHT 1
diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx
index 30f3f303ebc2..6d0b2d8c2fb5 100644
--- a/xmloff/source/text/txtparae.cxx
+++ b/xmloff/source/text/txtparae.cxx
@@ -99,6 +99,7 @@
#include <xmloff/formlayerexport.hxx>
#include "XMLTextCharStyleNamesElementExport.hxx"
#include <xmloff/odffields.hxx>
+#include <xmloff/maptype.hxx>
#include <basegfx/polygon/b2dpolypolygon.hxx>
#include <basegfx/polygon/b2dpolypolygontools.hxx>
#include <basegfx/polygon/b2dpolygontools.hxx>
diff --git a/xmloff/source/text/txtprmap.cxx b/xmloff/source/text/txtprmap.cxx
index 7979d1a4f2db..7c043da983a2 100644
--- a/xmloff/source/text/txtprmap.cxx
+++ b/xmloff/source/text/txtprmap.cxx
@@ -21,6 +21,8 @@
#include <tools/debug.hxx>
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/xmltoken.hxx>
+#include <xmloff/maptype.hxx>
+#include <xmloff/xmltypes.hxx>
#include "txtprhdl.hxx"
//UUUU
diff --git a/xmloff/source/text/txtstyli.cxx b/xmloff/source/text/txtstyli.cxx
index 04e073ab4b48..af0fba42c9fa 100644
--- a/xmloff/source/text/txtstyli.cxx
+++ b/xmloff/source/text/txtstyli.cxx
@@ -29,6 +29,7 @@
#include <xmloff/xmltkmap.hxx>
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmluconv.hxx>
+#include <xmloff/maptype.hxx>
#include <com/sun/star/beans/XMultiPropertySet.hpp>
#include <com/sun/star/container/XNameContainer.hpp>