diff options
Diffstat (limited to 'filter/source/xsltdialog/typedetectionexport.cxx')
-rw-r--r-- | filter/source/xsltdialog/typedetectionexport.cxx | 75 |
1 files changed, 34 insertions, 41 deletions
diff --git a/filter/source/xsltdialog/typedetectionexport.cxx b/filter/source/xsltdialog/typedetectionexport.cxx index 65cd250790c3..7d53a7db8726 100644 --- a/filter/source/xsltdialog/typedetectionexport.cxx +++ b/filter/source/xsltdialog/typedetectionexport.cxx @@ -119,20 +119,13 @@ void TypeDetectionExporter::doExport( const Reference< XOutputStream >& xOS, co pAttrList->AddAttribute( sName, sCdataAttribute, filter->maType ); xHandler->ignorableWhitespace ( sWhiteSpace ); xHandler->startElement( sNode, xAttrList ); - OUString sValue("0"); - sValue += sComma; - sValue += sComma; + OUString sValue = "0" + sComma + sComma; if( !filter->maDocType.isEmpty() ) { - sValue += sDocTypePrefix; - sValue += filter->maDocType; + sValue += sDocTypePrefix + filter->maDocType; } - sValue += sComma; - sValue += sComma; - sValue += filter->maExtension; - sValue += sComma; - sValue += OUString::number( filter->mnDocumentIconID ); - sValue += sComma; + sValue += sComma + sComma + filter->maExtension + sComma + + OUString::number( filter->mnDocumentIconID ) + sComma; addProperty( xHandler, sData, sValue ); addLocaleProperty( xHandler, sUIName, filter->maInterfaceName ); @@ -159,39 +152,39 @@ void TypeDetectionExporter::doExport( const Reference< XOutputStream >& xOS, co xHandler->startElement( sNode, xAttrList ); addLocaleProperty( xHandler, sUIName, filter->maInterfaceName ); - OUString sValue("0"); - sValue += sComma; - sValue += filter->maType; - sValue += sComma; - sValue += filter->maDocumentService; - sValue += sComma; - sValue += sFilterAdaptorService; - sValue += sComma; - sValue += OUString::number( filter->maFlags ); - sValue += sComma; - sValue += sXSLTFilterService; - sValue += sDelim; - sValue += OUString::boolean( filter->mbNeedsXSLT2 ); - sValue += sDelim; + OUStringBuffer sValue("0" + + sComma + + filter->maType + + sComma + + filter->maDocumentService + + sComma + + sFilterAdaptorService + + sComma + + OUString::number( filter->maFlags ) + + sComma + + sXSLTFilterService + + sDelim + + OUString::boolean( filter->mbNeedsXSLT2 ) + + sDelim); const application_info_impl* pAppInfo = getApplicationInfo( filter->maExportService ); - sValue += pAppInfo->maXMLImporter; - sValue += sDelim; - sValue += pAppInfo->maXMLExporter; - sValue += sDelim; - - sValue += createRelativeURL( filter->maFilterName, filter->maImportXSLT ); - sValue += sDelim; - sValue += createRelativeURL( filter->maFilterName, filter->maExportXSLT ); - sValue += sDelim; + sValue.append(pAppInfo->maXMLImporter + + sDelim + + pAppInfo->maXMLExporter + + sDelim); + + sValue.append(createRelativeURL( filter->maFilterName, filter->maImportXSLT )); + sValue.append(sDelim); + sValue.append(createRelativeURL( filter->maFilterName, filter->maExportXSLT )); + sValue.append(sDelim); // entry DTD obsolete and removed, but delimiter kept - sValue += sDelim; - sValue += filter->maComment; - sValue += sComma; - sValue += "0"; - sValue += sComma; - sValue += createRelativeURL( filter->maFilterName, filter->maImportTemplate ); - addProperty( xHandler, sData, sValue ); + sValue.append(sDelim); + sValue.append(filter->maComment); + sValue.append(sComma); + sValue.append("0"); + sValue.append(sComma); + sValue.append(createRelativeURL( filter->maFilterName, filter->maImportTemplate )); + addProperty( xHandler, sData, sValue.makeStringAndClear() ); xHandler->ignorableWhitespace ( sWhiteSpace ); xHandler->endElement( sNode ); } |