20#include <config_wasm_strip.h>
22#include <osl/diagnose.h>
23#include <com/sun/star/lang/XMultiServiceFactory.hpp>
24#include <com/sun/star/uno/XComponentContext.hpp>
58enum XMLUserDefinedTransformerAction
63 XML_ETACTION_STYLE_RENAME,
66 XML_ETACTION_TAB_STOP,
67 XML_ETACTION_FORM_CONTROL,
68 XML_ETACTION_FORM_PROPERTY,
70 XML_ETACTION_TRACKED_CHANGES,
71 XML_ETACTION_CHART_PLOT_AREA,
72 XML_ETACTION_DOCUMENT_RENAME,
78#define ENTRY3( n, l, a, p1, p2, p3 ) \
79 { n, l, a, p1, p2, p3 }
80#define ENTRY3QQN( n, l, a, n1, l1, n2, l2, p3 ) \
81 ENTRY3( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ), \
82 XMLTransformerActionInit::QNameParam( n2, l2 ), p3 )
84#define ENTRY2( n, l, a, p1, p2 ) \
85 ENTRY3( n, l, a, p1, p2, 0 )
86#define ENTRY2QN( n, l, a, n1, l1, p2 ) \
87 ENTRY2( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ), p2 )
89#define ENTRY1( n, l, a, p1 ) \
90 ENTRY3( n, l, a, p1, 0, 0 )
91#define ENTRY1Q( n, l, a, n1, l1 ) \
92 ENTRY1( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ) )
94#define ENTRY0( n, l, a ) \
95 ENTRY3( n, l, a, 0, 0, 0 )
101 return static_cast< sal_Int32
>(f) | (
static_cast< sal_Int32
>(s) << 16);
882 OUString
const m_aElemQName;
883 OUString m_aOldClass;
887 const OUString& rQName );
889 const OUString& rQName,
893 virtual void StartElement(
const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList )
override;
899XMLDocumentTransformerContext_Impl::XMLDocumentTransformerContext_Impl(
901 const OUString& rQName ) :
903 m_aElemQName( rQName )
906XMLDocumentTransformerContext_Impl::XMLDocumentTransformerContext_Impl(
908 const OUString& rQName ,
912 m_aElemQName( rImp.GetNamespaceMap().GetQNameByKey( nPrefix,
917void XMLDocumentTransformerContext_Impl::StartElement(
918 const Reference< XAttributeList >& rAttrList )
920 Reference< XAttributeList > xAttrList( rAttrList );
922 m_aOldClass = GetTransformer().GetClass();
925 bool bOOo =
false, bOOoW =
false, bOOoC =
false,
926 bDOM=
false, bDC =
false, bSVG =
false;
927 sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0;
928 for( sal_Int16 i=0;
i < nAttrCount;
i++ )
930 const OUString& rAttrName = xAttrList->getNameByIndex( i );
933 GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName,
938 const OUString& rValue = xAttrList->getValueByIndex( i );
939 GetTransformer().SetClass( rValue );
942 xAttrList = pMutableAttrList;
943 OUString sMime =
"application/vnd.oasis.opendocument." + rValue;
944 pMutableAttrList->SetValueByIndex( i, sMime );
946 pMutableAttrList->RenameAttributeByIndex(i, aNewAttrQName );
951 const OUString& rAttrValue = xAttrList->getValueByIndex( i );
962 else if(
IsXMLToken( rAttrValue, XML_N_SVG ) )
966 if( !(bOOo && bOOoW && bOOoC && bDOM && bDC && bSVG) )
968 if( !pMutableAttrList )
971 xAttrList = pMutableAttrList;
974 pMutableAttrList->AddAttribute(
975 GetTransformer().GetNamespaceMap().GetAttrNameByKey(
977 GetTransformer().GetNamespaceMap().GetNameByKey(
980 pMutableAttrList->AddAttribute(
981 GetTransformer().GetNamespaceMap().GetAttrNameByKey(
983 GetTransformer().GetNamespaceMap().GetNameByKey(
986 pMutableAttrList->AddAttribute(
987 GetTransformer().GetNamespaceMap().GetAttrNameByKey(
989 GetTransformer().GetNamespaceMap().GetNameByKey(
992 pMutableAttrList->AddAttribute(
993 GetTransformer().GetNamespaceMap().GetAttrNameByKey(
995 GetTransformer().GetNamespaceMap().GetNameByKey(
998 pMutableAttrList->AddAttribute(
999 GetTransformer().GetNamespaceMap().GetAttrNameByKey(
1001 GetTransformer().GetNamespaceMap().GetNameByKey(
1004 pMutableAttrList->AddAttribute(
1005 GetTransformer().GetNamespaceMap().GetAttrNameByKey(
1007 GetTransformer().GetNamespaceMap().GetNameByKey(
1011 GetTransformer().GetDocHandler()->startElement( m_aElemQName, xAttrList );
1014void XMLDocumentTransformerContext_Impl::EndElement()
1016 GetTransformer().GetDocHandler()->endElement( m_aElemQName );
1018 GetTransformer().SetClass( m_aOldClass );
1025 OUString m_aClassQName;
1029 const OUString& rQName );
1031 virtual void StartElement(
const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList )
override;
1037XMLBodyTransformerContext_Impl::XMLBodyTransformerContext_Impl(
1039 const OUString& rQName ) :
1044void XMLBodyTransformerContext_Impl::StartElement(
1045 const Reference< XAttributeList >& rAttrList )
1051 Reference< XAttributeList > xAttrList = pMutableAttrList;
1052 OUString aClass( GetTransformer().GetClass() );
1053 if( aClass.isEmpty() )
1059 OUString aGlobalQName(
1060 GetTransformer().GetNamespaceMap().GetQNameByKey(
1067 m_aClassQName = GetTransformer().GetNamespaceMap().GetQNameByKey(
1069 GetTransformer().GetDocHandler()->startElement( m_aClassQName,
1073void XMLBodyTransformerContext_Impl::EndElement()
1075 GetTransformer().GetDocHandler()->endElement( m_aClassQName );
1085 const OUString& rQName );
1087 virtual void StartElement(
const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList )
override;
1092XMLTabStopOOoTContext_Impl::XMLTabStopOOoTContext_Impl(
1094 const OUString& rQName ) :
1099void XMLTabStopOOoTContext_Impl::StartElement(
1100 const Reference< XAttributeList >& rAttrList )
1104 OSL_ENSURE( pActions,
"go no actions" );
1106 Reference< XAttributeList > xAttrList( rAttrList );
1108 sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0;
1109 for( sal_Int16 i=0;
i < nAttrCount;
i++ )
1111 const OUString& rAttrName = xAttrList->getNameByIndex( i );
1112 OUString aLocalName;
1113 sal_uInt16 nPrefix =
1114 GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName,
1116 XMLTransformerActions::key_type aKey( nPrefix, aLocalName );
1117 XMLTransformerActions::const_iterator aIter =
1118 pActions->find( aKey );
1119 if( aIter != pActions->end() )
1121 if( !pMutableAttrList )
1125 xAttrList = pMutableAttrList;
1127 const OUString& rAttrValue = xAttrList->getValueByIndex( i );
1128 switch( (*aIter).second.m_nActionType )
1132 OUString aNewAttrQName(
1133 GetTransformer().GetNamespaceMap().GetQNameByKey(
1134 (*aIter).second.GetQNamePrefixFromParam1(),
1136 (*aIter).second.GetQNameTokenFromParam1()) ) );
1137 pMutableAttrList->RenameAttributeByIndex( i,
1141 !rAttrValue.isEmpty() &&
1142 rAttrValue[0] !=
' ' )
1144 OUString aNewAttrQName(
1145 GetTransformer().GetNamespaceMap().GetQNameByKey(
1148 pMutableAttrList->AddAttribute( aNewAttrQName,
1154 OUString aAttrValue( rAttrValue );
1157 pMutableAttrList->SetValueByIndex( i, aAttrValue );
1161 OSL_ENSURE(
false,
"unknown action" );
1174 sal_uInt16
const m_nPrefix;
1179 const OUString& rQName,
1183 virtual void StartElement(
const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList )
override;
1188XMLTrackedChangesOOoTContext_Impl::XMLTrackedChangesOOoTContext_Impl(
1190 const OUString& rQName,
1194 m_nPrefix( nPrefix ),
1199void XMLTrackedChangesOOoTContext_Impl::StartElement(
1200 const Reference< XAttributeList >& rAttrList )
1202 sal_Int16 nAttrCount = rAttrList.is() ? rAttrList->getLength() : 0;
1203 for( sal_Int16 i=0;
i < nAttrCount;
i++ )
1205 const OUString& rAttrName = rAttrList->getNameByIndex( i );
1206 OUString aLocalName;
1207 sal_uInt16 nPrefix =
1208 GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName,
1210 if( m_nPrefix == nPrefix &&
IsXMLToken( aLocalName, m_eToken ) )
1212 const Reference< XPropertySet > rPropSet =
1213 GetTransformer().GetPropertySet();
1214 OSL_ENSURE( rPropSet.is(),
"no info property set" );
1217 OUString
aPropName(
"RedlineProtectionKey");
1218 Reference< XPropertySetInfo > xPropSetInfo(
1219 rPropSet->getPropertySetInfo() );
1220 if( xPropSetInfo.is() &&
1221 xPropSetInfo->hasPropertyByName( aPropName ) )
1223 Sequence < sal_Int8 > aKey;
1225 rAttrList->getValueByIndex( i ) );
1226 rPropSet->setPropertyValue( aPropName,
Any( aKey ) );
1230 OSL_ENSURE(
false,
"RedineProtectionKey is missing" );
1243 OUString
const m_aElemQName;
1247 const OUString& rQName );
1249 virtual void StartElement(
const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList )
override;
1255XMLTableOOoTransformerContext_Impl::XMLTableOOoTransformerContext_Impl(
1257 const OUString& rQName ) :
1259 m_aElemQName( rQName )
1263void XMLTableOOoTransformerContext_Impl::StartElement(
1264 const Reference< XAttributeList >& rAttrList )
1267 Reference< XAttributeList > xAttrList( rAttrList );
1272 bool bPrintRanges(
false);
1274 sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0;
1275 for( sal_Int16 i=0;
i < nAttrCount;
i++ )
1277 const OUString& rAttrName = xAttrList->getNameByIndex( i );
1278 OUString aLocalName;
1279 sal_uInt16 nPrefix =
1280 GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName,
1285 bPrintRanges =
true;
1288 if (!bPrintRanges && pMutableAttrList)
1290 xAttrList = pMutableAttrList;
1291 pMutableAttrList->
AddAttribute(GetTransformer().GetNamespaceMap().GetQNameByKey(
1297 GetTransformer().GetDocHandler()->startElement( m_aElemQName, xAttrList );
1300void XMLTableOOoTransformerContext_Impl::EndElement()
1302 GetTransformer().GetDocHandler()->endElement( m_aElemQName );
1307 const OUString& rQName,
1312 case XML_ETACTION_DOCUMENT:
1313 return new XMLDocumentTransformerContext_Impl( *
this, rQName );
1314 case XML_ETACTION_DOCUMENT_RENAME:
1315 return new XMLDocumentTransformerContext_Impl( *
this, rQName,
1318 case XML_ETACTION_BODY:
1319 return new XMLBodyTransformerContext_Impl( *
this, rQName );
1320 case XML_ETACTION_STYLE:
1324 case XML_ETACTION_STYLE_RENAME:
1330 case XML_ETACTION_FRAME:
1332 case XML_ETACTION_EVENT:
1334 case XML_ETACTION_TAB_STOP:
1335 return new XMLTabStopOOoTContext_Impl( *
this, rQName );
1336 case XML_ETACTION_FORM_CONTROL:
1338 case XML_ETACTION_FORM_PROPERTY:
1340#if !ENABLE_WASM_STRIP_CHART
1341 case XML_ETACTION_CHART:
1343 case XML_ETACTION_CHART_PLOT_AREA:
1346 case XML_ETACTION_TRACKED_CHANGES:
1347 return new XMLTrackedChangesOOoTContext_Impl( *
this, rQName,
1350 case XML_ETACTION_TABLE:
1351 return new XMLTableOOoTransformerContext_Impl( *
this, rQName );
1353 OSL_ENSURE(
false,
"no user defined context found!" );
1557 OUString aSubServiceName )
1560 m_aImplName(std::move(aImplName)),
1561 m_aSubServiceName(std::move(aSubServiceName)),
1562 m_pEventMap(
nullptr )
1609 for(
auto & rp : m_aActions)
1625 Reference<XImporter> xThis(
this );
1630 Reference<XFilter> xThis(
this );
1635 aRet = XMLTransformerBase::queryInterface(rType);
1643 const Reference< XComponent >& xDoc )
1649 Sequence<Any> aArgs( 0 );
1653 mxModel.set( xDoc, UNO_QUERY );
1656 OSL_ENSURE( xImp.is(),
"doc handler is not an importer" );
1658 xImp->setTargetDocument( xDoc );
1663 const Sequence< PropertyValue >& aDescriptor )
1666 OSL_ENSURE( xFilter.is(),
"doc handler is not a filter" );
1668 return xFilter->filter( aDescriptor );
1676 OSL_ENSURE( xFilter.is(),
"doc handler is not a filter" );
1683 const Sequence< Any >& rArguments )
1694 Sequence<Any> aArgs( 0 );
1702 const Sequence< Any >& rArguments )
1704 OSL_ENSURE( !
GetDocHandler().is(),
"duplication initialization" );
1706 Reference< XInterface > xFilter;
1712 xContext->getServiceManager()->createInstanceWithArgumentsAndContext(
m_aSubServiceName, rArguments, xContext);
1716 SAL_WARN(
"xmloff",
"no subservice name");
1720 Sequence<Any> aArgs( 1 + rArguments.getLength() );
1721 auto pArgs = aArgs.getArray();
1722 pArgs[0] <<= xFilter;
1723 std::copy(rArguments.begin(), rArguments.end(), std::next(pArgs));
1727 "duplicate doc handler" );
1757 XMLTransformerBase::getTypes()
1763extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface*
1765 css::uno::XComponentContext* , css::uno::Sequence<css::uno::Any>
const&)
1767 return cppu::acquire(
new OOo2OasisTransformer(
"com.sun.star.comp.OOo2OasisTransformer", OUString()));
1770#define OOO_IMPORTER( xml_className_get_impl, implName, subServiceName ) \
1771extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* \
1772xml_className_get_impl( \
1773 css::uno::XComponentContext* , css::uno::Sequence<css::uno::Any> const&) \
1775 return cppu::acquire(new OOo2OasisTransformer( \
1777 subServiceName )); \
1781 "com.sun.star.comp.Writer.XMLImporter",
1782 "com.sun.star.comp.Writer.XMLOasisImporter" )
1783OOO_IMPORTER( xmloff_XMLWriterStylesImportOOO_get_implementation,
1785 "
com.sun.star.comp.
Writer.XMLOasisStylesImporter" )
1788 "
com.sun.star.comp.
Writer.XMLOasisContentImporter" )
1789OOO_IMPORTER( xmloff_XMLWriterMetaImportOOO_get_implementation,
1791 "
com.sun.star.comp.
Writer.XMLOasisMetaImporter" )
1794 "
com.sun.star.comp.
Writer.XMLOasisSettingsImporter" )
1796OOO_IMPORTER( xmloff_XMLImpressImportOOO_get_implementation,
1798 "
com.sun.star.comp.Impress.XMLOasisImporter" )
1801 "
com.sun.star.comp.Impress.XMLOasisStylesImporter" )
1802OOO_IMPORTER( xmloff_XMLImpressContentImportOOO_get_implementation,
1804 "
com.sun.star.comp.Impress.XMLOasisContentImporter" )
1807 "
com.sun.star.comp.Impress.XMLOasisMetaImporter" )
1808OOO_IMPORTER( xmloff_XMLImpressSettingsImportOOO_get_implementation,
1810 "
com.sun.star.comp.Impress.XMLOasisSettingsImporter" )
1814 "
com.sun.star.comp.Draw.XMLOasisImporter" )
1815OOO_IMPORTER( xmloff_XMLDrawStylesImportOOO_get_implementation,
1817 "
com.sun.star.comp.Draw.XMLOasisStylesImporter" )
1820 "
com.sun.star.comp.Draw.XMLOasisContentImporter" )
1821OOO_IMPORTER( xmloff_XMLDrawMetaImportOOO_get_implementation,
1823 "
com.sun.star.comp.Draw.XMLOasisMetaImporter" )
1826 "
com.sun.star.comp.Draw.XMLOasisSettingsImporter" )
1828OOO_IMPORTER( xmloff_XMLCalcImportOOO_get_implementation,
1830 "
com.sun.star.comp.Calc.XMLOasisImporter" )
1833 "
com.sun.star.comp.Calc.XMLOasisStylesImporter" )
1834OOO_IMPORTER( xmloff_XMLCalcContentImportOOO_get_implementation,
1836 "
com.sun.star.comp.Calc.XMLOasisContentImporter" )
1839 "
com.sun.star.comp.Calc.XMLOasisMetaImporter" )
1840OOO_IMPORTER( xmloff_XMLCalcSettingsImportOOO_get_implementation,
1842 "
com.sun.star.comp.Calc.XMLOasisSettingsImporter" )
1846 "
com.sun.star.comp.Chart.XMLOasisImporter" )
1847OOO_IMPORTER( xmloff_XMLChartStylesImportOOO_get_implementation,
1849 "
com.sun.star.comp.Chart.XMLOasisStylesImporter" )
1852 "
com.sun.star.comp.Chart.XMLOasisContentImporter" )
1854OOO_IMPORTER( xmloff_XMLMathMetaImportOOO_get_implementation,
1856 "
com.sun.star.comp.Math.XMLOasisMetaImporter" )
1859 "
com.sun.star.comp.Math.XMLOasisSettingsImporter" )
1861OOO_IMPORTER( xmloff_XMLMetaImportOOO_get_implementation,
1863 "
com.sun.star.document.XMLOasisMetaImporter" )
1865OOO_IMPORTER( xmloff_XMLAutoTextEventImportOOO_get_implementation,
1866 "
com.sun.star.comp.
Writer.XMLAutotextEventsImporter",
1867 "
com.sun.star.comp.
Writer.XMLOasisAutotextEventsImporter" )
@ OOO_CONFIG_ITEM_SET_ACTIONS
@ OOO_TABLE_VALUE_TYPE_ACTIONS
@ OOO_FORM_COLUMN_ACTIONS
@ OOO_TEXT_VALUE_TYPE_ACTIONS
@ OOO_CHANGE_INFO_ACTIONS
@ OOO_MASTER_PAGE_ACTIONS
@ OOO_DDE_CONV_MODE_ACTIONS
@ OOO_DATAPILOT_LEVEL_ACTIONS
@ OOO_DDE_CONNECTION_DECL_ACTIONS
@ OOO_DRAW_AREA_POLYGON_ACTIONS
@ OOO_DATAPILOT_MEMBER_ACTIONS
@ OOO_ALPHABETICAL_INDEX_MARK_ACTIONS
@ OOO_INDEX_ENTRY_TAB_STOP_ACTIONS
@ OOO_FOOTNOTE_SEP_ACTIONS
@ OOO_SOURCE_SERVICE_ACTIONS
@ OOO_FORM_CONTROL_ACTIONS
@ OOO_LINENUMBERING_ACTIONS
@ OOO_BACKGROUND_IMAGE_ACTIONS
@ OOO_ERROR_MACRO_ACTIONS
@ XML_FAMILY_TYPE_PAGE_LAYOUT
@ XML_FAMILY_TYPE_FILL_IMAGE
@ XML_FAMILY_TYPE_GRADIENT
@ XML_FAMILY_TYPE_STROKE_DASH
@ XML_FAMILY_TYPE_HEADER_FOOTER
XMLTransformerActionInit const aErrorMacroActionTable[]
#define ENTRY2(n, l, a, p1, p2)
XMLTransformerActionInit const aConnectorActionTable[]
#define ENTRY1Q(n, l, a, n1, l1)
com sun star comp Writer com sun star comp Writer XMLOasisStylesImporter com sun star comp Writer com sun star comp Writer XMLOasisMetaImporter com sun star comp Impress com sun star comp Impress XMLOasisImporter com sun star comp Impress XMLContentImporter
XMLTransformerActionInit const aScriptActionTable[]
XMLTransformerActionInit const aTextValueTypeActionTable[]
XMLTransformerActionInit const aFormControlActionTable[]
XMLTransformerActionInit const aConfigItemSetActionTable[]
XMLTransformerActionInit const aDDEConnectionDeclActionTable[]
XMLTransformerActionInit const aBackgroundImageActionTable[]
XMLTransformerActionInit const aFrameAttrActionTable[]
XMLTransformerActionInit const aFormulaActionTable[]
XMLTransformerActionInit const aAnnotationActionTable[]
XMLTransformerActionInit const aDataPilotLevelActionTable[]
XMLTransformerActionInit const aFrameElemActionTable[]
#define ENTRY1(n, l, a, p1)
XMLTransformerActionInit const aFontDeclActionTable[]
XMLTransformerActionInit const aDDEConvModeActionTable[]
XMLTransformerActionInit const aStyleActionTable[]
XMLTransformerActionInit const aDrawAreaPolygonActionTable[]
XMLTransformerActionInit const aXLinkActionTable[]
SAL_DLLPUBLIC_EXPORT css::uno::XInterface * xmloff_OOo2OasisTransformer_get_implementation(css::uno::XComponentContext *, css::uno::Sequence< css::uno::Any > const &)
#define ENTRY3QQN(n, l, a, n1, l1, n2, l2, p3)
XMLTransformerActionInit const aParaActionTable[]
XMLTokenEnum const aTokenMap[]
#define OOO_IMPORTER(xml_className_get_impl, implName, subServiceName)
XMLTransformerActionInit const aMasterPageActionTable[]
com sun star comp Writer com sun star comp Writer XMLOasisStylesImporter com sun star comp Writer com sun star comp Writer XMLOasisMetaImporter com sun star comp Impress com sun star comp Impress XMLOasisImporter com sun star comp Impress com sun star comp Impress XMLOasisContentImporter com sun star comp Impress XMLSettingsImporter
XMLTransformerActionInit const aSourceServiceActionTable[]
XMLTransformerActionInit const aAlphabeticalIndexMarkActionTable[]
XMLTransformerActionInit const aDropCapActionTable[]
XMLTransformerActionInit const aFootnoteSepActionTable[]
XMLTransformerActionInit const aTabStopActionTable[]
XMLTransformerActionInit const aDataPilotMemberActionTable[]
XMLTransformerActionInit const aChartActionTable[]
XMLTransformerActionInit const aEventActionTable[]
XMLTransformerActionInit const aStyleRefActionTable[]
com sun star comp Writer com sun star comp Writer XMLOasisStylesImporter com sun star comp Writer XMLMetaImporter
XMLTransformerActionInit const aLineNumberingActionTable[]
XMLTransformerActionInit const aActionTable[]
XMLTransformerActionInit const aAnimationsActionTable[]
XMLTransformerActionInit const aIndexEntryTabStopActionTable[]
XMLTransformerActionInit const aFormPropActionTable[]
XMLTransformerActionInit const aChangeInfoActionTable[]
XMLTransformerActionInit const aShapeActionTable[]
com sun star comp Writer com sun star comp Writer XMLOasisStylesImporter com sun star comp Writer com sun star comp Writer XMLOasisMetaImporter com sun star comp Impress XMLImporter
XMLTransformerActionInit const aColumnsActionTable[]
com sun star comp Writer XMLStylesImporter
XMLTransformerActionInit const aTableValueTypeActionTable[]
XMLTransformerActionInit const aFormColumnActionTable[]
static constexpr sal_Int32 RENAME_ENTRY(XMLTokenEnum f, XMLTokenEnum s)
XMLTransformerActionInit const aWriterBackgroundImageActionTable[]
#define ENTRY2QN(n, l, a, n1, l1, p2)
@ XML_ATACTION_WRITER_BACK_GRAPHIC_TRANSPARENCY
OUString GetQNameByKey(sal_uInt16 nKey, const OUString &rLocalName, bool bCache=true) const
static sal_uInt16 GetEventName(const OUString &rName, OUString &rNewName, XMLTransformerOOoEventMap_Impl &rMap)
static XMLTransformerOOoEventMap_Impl * CreateEventMap()
static void FlushEventMap(XMLTransformerOOoEventMap_Impl *p)
void AddAttribute(const OUString &sName, const OUString &sValue)
virtual void StartElement(const css::uno::Reference< css::xml::sax::XAttributeList > &xAttrList) override
static XMLTransformerActions * CreateTransformerActions(sal_uInt16 nType)
virtual void StartElement(const css::uno::Reference< css::xml::sax::XAttributeList > &xAttrList)
virtual void EndElement()
static void decode(css::uno::Sequence< sal_Int8 > &aPass, std::u16string_view sBuffer)
css::uno::Sequence< css::uno::Type > SAL_CALL getTypes()
#define SAL_WARN_IF(condition, area, stream)
#define SAL_WARN(area, stream)
Reference< XComponentContext > getProcessComponentContext()
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
const sal_uInt16 XML_NAMESPACE_UNKNOWN
const sal_uInt16 XML_NAMESPACE_XMLNS
Handling of tokens in XML:
XMLTokenEnum
The enumeration of all XML tokens.
@ XML_ALPHABETICAL_INDEX_MARK
@ XML_PRESENTATION_PAGE_LAYOUT
@ XML_MAIN_ENTRY_STYLE_NAME
@ XML_INDEX_ENTRY_TAB_STOP
@ XML_LIST_LEVEL_STYLE_IMAGE
@ XML_LIST_LEVEL_STYLE_NUMBER
@ XML_CONTENT_VALIDATION_NAME
@ XML_ALPHABETICAL_INDEX_AUTO_MARK_FILE
@ XML_INDEX_ENTRY_BIBLIOGRAPHY
@ XML_ALPHABETICAL_INDEX_MARK_START
@ XML_INDEX_ENTRY_LINK_START
@ XML_ALPHABETICAL_INDEX_ENTRY_TEMPLATE
@ XML_BIBLIOGRAPHY_ENTRY_TEMPLATE
@ XML_DDE_CONNECTION_DECL
@ XML_ILLUSTRATION_INDEX_ENTRY_TEMPLATE
@ XML_ENDNOTES_CONFIGURATION
@ XML_INDEX_TITLE_TEMPLATE
@ XML_DATABASE_ROW_SELECT
@ XML_DEFAULT_CELL_STYLE_NAME
@ XML_TABLE_OF_CONTENT_ENTRY_TEMPLATE
@ XML_PRESENTATION_PAGE_LAYOUT_NAME
@ XML_INDEX_ENTRY_PAGE_NUMBER
@ XML_OBJECT_INDEX_ENTRY_TEMPLATE
@ XML_COUNT_IN_FLOATING_FRAMES
@ XML_LINENUMBERING_CONFIGURATION
@ XML_COUNT_IN_TEXT_BOXES
@ XML_CITATION_BODY_STYLE_NAME
@ XML_NOTES_CONFIGURATION
@ XML_INDEX_ENTRY_CHAPTER_NUMBER
@ XML_INDEX_ENTRY_CHAPTER
@ XML_LIST_LEVEL_STYLE_BULLET
@ XML_DISTANCE_BEFORE_SEP
@ XML_OUTLINE_LEVEL_STYLE
@ XML_INDEX_ENTRY_LINK_END
@ XML_CONTROL_IMPLEMENTATION
@ XML_FOOTNOTES_CONFIGURATION
@ XML_USER_INDEX_ENTRY_TEMPLATE
@ XML_CHANGE_TRACK_TABLE_CELL
@ XML_TABLE_INDEX_ENTRY_TEMPLATE
@ XML_CITATION_STYLE_NAME
bool IsXMLToken(std::u16string_view rString, enum XMLTokenEnum eToken)
compare eToken to the string
const OUString & GetXMLToken(enum XMLTokenEnum eToken)
return the OUString representation for eToken
constexpr sal_uInt16 XML_NAMESPACE_DRAW
constexpr sal_uInt16 XML_NAMESPACE_META
constexpr sal_uInt16 XML_NAMESPACE_DC
constexpr sal_uInt16 XML_NAMESPACE_XLINK
constexpr sal_uInt16 XML_NAMESPACE_OOOC
constexpr sal_uInt16 XML_NAMESPACE_SVG
constexpr sal_uInt16 XML_NAMESPACE_TEXT
constexpr sal_uInt16 XML_NAMESPACE_FORM
constexpr sal_uInt16 XML_NAMESPACE_DR3D
constexpr sal_uInt16 XML_NAMESPACE_CHART
constexpr sal_uInt16 XML_NAMESPACE_DOM
constexpr sal_uInt16 XML_NAMESPACE_TABLE
constexpr sal_uInt16 XML_NAMESPACE_OOOW
constexpr sal_uInt16 XML_NAMESPACE_OFFICE
constexpr sal_uInt16 XML_NAMESPACE_PRESENTATION
constexpr sal_uInt16 XML_NAMESPACE_CONFIG
constexpr sal_uInt16 XML_NAMESPACE_OOO
constexpr sal_uInt16 XML_NAMESPACE_STYLE
constexpr sal_uInt16 XML_NAMESPACE_SCRIPT
constexpr sal_uInt16 XML_NAMESPACE_FO
constexpr sal_uInt16 XML_NAMESPACE_NUMBER