1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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/.
10 // Helper string methods
12 #ifndef INCLUDED_L10NTOOLS_INC_HELPER_HXX
13 #define INCLUDED_L10NTOOLS_INC_HELPER_HXX
15 #include <sal/config.h>
16 #include <sal/types.h>
18 #include <libxml/parser.h>
20 #include <rtl/string.hxx>
21 #include <rtl/strbuf.hxx>
26 /// Escape all given character in the text
28 const OString
& rText
, const OString
& rUnEscaped
, const OString
& rEscaped
);
29 /// Unescape all given character in the text
31 const OString
& rText
, const OString
& rEscaped
, const OString
& rUnEscaped
);
33 /// Convert special characters to XML entity references
34 OString
QuotHTML( const OString
&rString
);
35 /// Convert XML entity references to single characters
36 OString
UnQuotHTML( const OString
& rString
);
38 /// Check whether text is a valid XML expression
39 bool isWellFormedXML( OString
const & text
);
41 /// Convert xmlChar* to OString
42 OString
xmlStrToOString( const xmlChar
* pString
);
48 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */