summaryrefslogtreecommitdiff
path: root/sax
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@suse.cz>2013-04-07 12:06:47 +0200
committerLuboš Luňák <l.lunak@suse.cz>2013-04-07 14:23:11 +0200
commit1946794ae09ba732022fe6a74ea45e304ab70b84 (patch)
treee32bd7ba61fa021ecc7f8c85959df8ca837d6e81 /sax
parent5b08c6e7a21dda94d5b755eea0b1ed1e9c199bec (diff)
mass removal of rtl:: prefixes for O(U)String*
Modules sal, salhelper, cppu, cppuhelper, codemaker (selectively) and odk have kept them, in order not to break external API (the automatic using declaration is LO-internal). Change-Id: I588fc9e0c45b914f824f91c0376980621d730f09
Diffstat (limited to 'sax')
-rw-r--r--sax/inc/sax/fastattribs.hxx22
-rw-r--r--sax/inc/sax/fshelper.hxx4
-rw-r--r--sax/inc/sax/tools/converter.hxx75
-rw-r--r--sax/inc/sax/tools/documenthandleradapter.hxx24
-rw-r--r--sax/inc/xml2utf.hxx8
-rw-r--r--sax/qa/cppunit/test_converter.cxx52
-rw-r--r--sax/source/expatwrap/attrlistimpl.hxx14
-rw-r--r--sax/source/expatwrap/sax_expat.cxx2
-rw-r--r--sax/source/expatwrap/saxwriter.cxx20
-rw-r--r--sax/source/expatwrap/xml2utf.cxx1
-rw-r--r--sax/source/fastparser/facreg.cxx1
-rw-r--r--sax/source/fastparser/fastparser.cxx5
-rw-r--r--sax/source/fastparser/fastparser.hxx30
-rw-r--r--sax/source/tools/converter.cxx60
-rw-r--r--sax/source/tools/fastattribs.cxx2
-rw-r--r--sax/source/tools/fastserializer.cxx6
-rw-r--r--sax/source/tools/fastserializer.hxx6
-rw-r--r--sax/source/tools/fshelper.cxx16
18 files changed, 165 insertions, 183 deletions
diff --git a/sax/inc/sax/fastattribs.hxx b/sax/inc/sax/fastattribs.hxx
index 615e5c0f19e4..f31be4b142f6 100644
--- a/sax/inc/sax/fastattribs.hxx
+++ b/sax/inc/sax/fastattribs.hxx
@@ -36,18 +36,18 @@ namespace sax_fastparser
struct UnknownAttribute
{
- ::rtl::OUString maNamespaceURL;
- ::rtl::OString maName;
- ::rtl::OString maValue;
+ OUString maNamespaceURL;
+ OString maName;
+ OString maValue;
- UnknownAttribute( const ::rtl::OUString& rNamespaceURL, const ::rtl::OString& rName, const ::rtl::OString& rValue );
+ UnknownAttribute( const OUString& rNamespaceURL, const OString& rName, const OString& rValue );
- UnknownAttribute( const ::rtl::OString& rName, const ::rtl::OString& rValue );
+ UnknownAttribute( const OString& rName, const OString& rValue );
void FillAttribute( ::com::sun::star::xml::Attribute* pAttrib ) const;
};
-typedef std::map< sal_Int32, ::rtl::OString > FastAttributeMap;
+typedef std::map< sal_Int32, OString > FastAttributeMap;
typedef std::vector< UnknownAttribute > UnknownAttributeList;
class SAX_DLLPUBLIC FastAttributeList : public ::cppu::WeakImplHelper1< ::com::sun::star::xml::sax::XFastAttributeList >
@@ -57,16 +57,16 @@ public:
virtual ~FastAttributeList();
void clear();
- void add( sal_Int32 nToken, const ::rtl::OString& rValue );
- void addUnknown( const ::rtl::OUString& rNamespaceURL, const ::rtl::OString& rName, const ::rtl::OString& rValue );
- void addUnknown( const ::rtl::OString& rName, const ::rtl::OString& rValue );
+ void add( sal_Int32 nToken, const OString& rValue );
+ void addUnknown( const OUString& rNamespaceURL, const OString& rName, const OString& rValue );
+ void addUnknown( const OString& rName, const OString& rValue );
// XFastAttributeList
virtual ::sal_Bool SAL_CALL hasAttribute( ::sal_Int32 Token ) throw (::com::sun::star::uno::RuntimeException);
virtual ::sal_Int32 SAL_CALL getValueToken( ::sal_Int32 Token ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException);
virtual ::sal_Int32 SAL_CALL getOptionalValueToken( ::sal_Int32 Token, ::sal_Int32 Default ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getValue( ::sal_Int32 Token ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getOptionalValue( ::sal_Int32 Token ) throw (::com::sun::star::uno::RuntimeException);
+ virtual OUString SAL_CALL getValue( ::sal_Int32 Token ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException);
+ virtual OUString SAL_CALL getOptionalValue( ::sal_Int32 Token ) throw (::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Sequence< ::com::sun::star::xml::Attribute > SAL_CALL getUnknownAttributes( ) throw (::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Sequence< ::com::sun::star::xml::FastAttribute > SAL_CALL getFastAttributes() throw (::com::sun::star::uno::RuntimeException);
diff --git a/sax/inc/sax/fshelper.hxx b/sax/inc/sax/fshelper.hxx
index 2e9d07b7ce26..e0945fc07ddf 100644
--- a/sax/inc/sax/fshelper.hxx
+++ b/sax/inc/sax/fshelper.hxx
@@ -125,13 +125,13 @@ public:
{ startElement( FSNS( namespaceTokenId, elementTokenId ), xAttrList ); }
FastSerializerHelper* write(const char* value);
- FastSerializerHelper* write(const rtl::OUString& value);
+ FastSerializerHelper* write(const OUString& value);
FastSerializerHelper* write(sal_Int32 value);
FastSerializerHelper* write(sal_Int64 value);
FastSerializerHelper* write(double value);
FastSerializerHelper* writeEscaped(const char* value);
- FastSerializerHelper* writeEscaped(const rtl::OUString& value);
+ FastSerializerHelper* writeEscaped(const OUString& value);
FastSerializerHelper* writeId(sal_Int32 tokenId);
diff --git a/sax/inc/sax/tools/converter.hxx b/sax/inc/sax/tools/converter.hxx
index 30aaea614bf6..615308c9e418 100644
--- a/sax/inc/sax/tools/converter.hxx
+++ b/sax/inc/sax/tools/converter.hxx
@@ -23,17 +23,12 @@
#include "sax/saxdllapi.h"
#include <sal/types.h>
-
+#include <rtl/ustring.hxx>
+#include <rtl/ustrbuf.hxx>
#include <com/sun/star/uno/Sequence.h>
#include <com/sun/star/util/MeasureUnit.hpp>
-namespace rtl
-{
-class OUString;
-class OUStringBuffer;
-}
-
namespace com { namespace sun { namespace star {
namespace uno {
class Any;
@@ -60,114 +55,114 @@ class SAX_DLLPUBLIC Converter
public:
/** convert string to measure using optional min and max values*/
static bool convertMeasure( sal_Int32& rValue,
- const ::rtl::OUString& rString,
+ const OUString& rString,
sal_Int16 nTargetUnit = ::com::sun::star::util::MeasureUnit::MM_100TH,
sal_Int32 nMin = SAL_MIN_INT32,
sal_Int32 nMax = SAL_MAX_INT32 );
/** convert measure to string */
- static void convertMeasure( ::rtl::OUStringBuffer& rBuffer,
+ static void convertMeasure( OUStringBuffer& rBuffer,
sal_Int32 nMeasure,
sal_Int16 SourceUnit = ::com::sun::star::util::MeasureUnit::MM_100TH,
sal_Int16 nTargetUnit = ::com::sun::star::util::MeasureUnit::INCH );
/** convert string to boolean */
static bool convertBool( bool& rBool,
- const ::rtl::OUString& rString );
+ const OUString& rString );
/** convert boolean to string */
- static void convertBool( ::rtl::OUStringBuffer& rBuffer,
+ static void convertBool( OUStringBuffer& rBuffer,
bool bValue );
/** convert string to percent */
static bool convertPercent( sal_Int32& rValue,
- const ::rtl::OUString& rString );
+ const OUString& rString );
/** convert percent to string */
- static void convertPercent( ::rtl::OUStringBuffer& rBuffer,
+ static void convertPercent( OUStringBuffer& rBuffer,
sal_Int32 nValue );
/** convert string to pixel measure unite */
static bool convertMeasurePx( sal_Int32& rValue,
- const ::rtl::OUString& rString );
+ const OUString& rString );
/** convert pixel measure unit to string */
- static void convertMeasurePx( ::rtl::OUStringBuffer& rBuffer,
+ static void convertMeasurePx( OUStringBuffer& rBuffer,
sal_Int32 nValue );
/** convert string to rgb color */
static bool convertColor( sal_Int32& rColor,
- const ::rtl::OUString&rValue );
+ const OUString&rValue );
/** convert color to string */
- static void convertColor( ::rtl::OUStringBuffer &rBuffer,
+ static void convertColor( OUStringBuffer &rBuffer,
sal_Int32 nColor );
/** convert number to string */
- static void convertNumber( ::rtl::OUStringBuffer& rBuffer,
+ static void convertNumber( OUStringBuffer& rBuffer,
sal_Int32 nNumber );
/** convert string to number with optional min and max values */
static bool convertNumber( sal_Int32& rValue,
- const ::rtl::OUString& rString,
+ const OUString& rString,
sal_Int32 nMin = SAL_MIN_INT32,
sal_Int32 nMax = SAL_MAX_INT32 );
/** convert string to number with optional min and max values */
static bool convertNumber64(sal_Int64& rValue,
- const ::rtl::OUString& rString,
+ const OUString& rString,
sal_Int64 nMin = SAL_MIN_INT64,
sal_Int64 nMax = SAL_MAX_INT64);
/** convert double number to string (using ::rtl::math) and
DO convert from source unit to target unit */
- static void convertDouble( ::rtl::OUStringBuffer& rBuffer,
+ static void convertDouble( OUStringBuffer& rBuffer,
double fNumber,
bool bWriteUnits,
sal_Int16 nSourceUnit,
sal_Int16 nTargetUnit );
/** convert double number to string (using ::rtl::math) without unit conversion */
- static void convertDouble( ::rtl::OUStringBuffer& rBuffer, double fNumber);
+ static void convertDouble( OUStringBuffer& rBuffer, double fNumber);
/** convert string to double number (using ::rtl::math) and DO convert from
source unit to target unit. */
static bool convertDouble( double& rValue,
- const ::rtl::OUString& rString,
+ const OUString& rString,
sal_Int16 nSourceUnit,
sal_Int16 nTargetUnit );
/** convert string to double number (using ::rtl::math) without unit conversion */
- static bool convertDouble(double& rValue, const ::rtl::OUString& rString);
+ static bool convertDouble(double& rValue, const OUString& rString);
/** convert double to ISO "duration" string; negative durations allowed */
- static void convertDuration(::rtl::OUStringBuffer& rBuffer,
+ static void convertDuration(OUStringBuffer& rBuffer,
const double fTime);
/** convert util::Duration to ISO "duration" string */
- static void convertDuration(::rtl::OUStringBuffer& rBuffer,
+ static void convertDuration(OUStringBuffer& rBuffer,
const ::com::sun::star::util::Duration& rDuration);
/** convert ISO "duration" string to double; negative durations allowed */
static bool convertDuration(double & rfTime,
- const ::rtl::OUString& rString);
+ const OUString& rString);
/** convert ISO "duration" string to util::Duration */
static bool convertDuration(::com::sun::star::util::Duration& rDuration,
- const ::rtl::OUString& rString);
+ const OUString& rString);
/** convert util::Date to ISO "date" string */
- static void convertDate( ::rtl::OUStringBuffer& rBuffer,
+ static void convertDate( OUStringBuffer& rBuffer,
const com::sun::star::util::Date& rDate );
/** convert util::DateTime to ISO "date" or "dateTime" string */
- static void convertDateTime( ::rtl::OUStringBuffer& rBuffer,
+ static void convertDateTime( OUStringBuffer& rBuffer,
const com::sun::star::util::DateTime& rDateTime,
bool bAddTimeIf0AM = false );
/** convert ISO "date" or "dateTime" string to util::DateTime */
static bool convertDateTime( com::sun::star::util::DateTime& rDateTime,
- const ::rtl::OUString& rString );
+ const OUString& rString );
/** convert ISO "date" or "dateTime" string to util::DateTime or
util::Date */
@@ -175,31 +170,31 @@ public:
com::sun::star::util::Date & rDate,
com::sun::star::util::DateTime & rDateTime,
bool & rbDateTime,
- const ::rtl::OUString & rString );
+ const OUString & rString );
/** gets the position of the first comma after npos in the string
rStr. Commas inside '"' pairs are not matched */
- static sal_Int32 indexOfComma( const ::rtl::OUString& rStr,
+ static sal_Int32 indexOfComma( const OUString& rStr,
sal_Int32 nPos );
/** encodes the given byte sequence into Base64 */
- static void encodeBase64(rtl::OUStringBuffer& aStrBuffer, const com::sun::star::uno::Sequence<sal_Int8>& aPass);
+ static void encodeBase64(OUStringBuffer& aStrBuffer, const com::sun::star::uno::Sequence<sal_Int8>& aPass);
// Decode a base 64 encoded string into a sequence of bytes. The first
// version can be used for attribute values only, bacause it does not
// return any chars left from conversion.
// For text submitted throgh the SAX characters call, the later method
// must be used!
- static void decodeBase64(com::sun::star::uno::Sequence<sal_Int8>& aPass, const rtl::OUString& sBuffer);
+ static void decodeBase64(com::sun::star::uno::Sequence<sal_Int8>& aPass, const OUString& sBuffer);
- static sal_Int32 decodeBase64SomeChars(com::sun::star::uno::Sequence<sal_Int8>& aPass, const rtl::OUString& sBuffer);
+ static sal_Int32 decodeBase64SomeChars(com::sun::star::uno::Sequence<sal_Int8>& aPass, const OUString& sBuffer);
- static double GetConversionFactor(::rtl::OUStringBuffer& rUnit, sal_Int16 nSourceUnit, sal_Int16 nTargetUnit);
- static sal_Int16 GetUnitFromString(const ::rtl::OUString& rString, sal_Int16 nDefaultUnit);
+ static double GetConversionFactor(OUStringBuffer& rUnit, sal_Int16 nSourceUnit, sal_Int16 nTargetUnit);
+ static sal_Int16 GetUnitFromString(const OUString& rString, sal_Int16 nDefaultUnit);
/** convert an Any to string (typesafe) */
- static bool convertAny(::rtl::OUStringBuffer& rsValue,
- ::rtl::OUStringBuffer& rsType ,
+ static bool convertAny(OUStringBuffer& rsValue,
+ OUStringBuffer& rsType ,
const ::com::sun::star::uno::Any& rValue);
};
diff --git a/sax/inc/sax/tools/documenthandleradapter.hxx b/sax/inc/sax/tools/documenthandleradapter.hxx
index 3e8705c6f951..5867bbbb9cac 100644
--- a/sax/inc/sax/tools/documenthandleradapter.hxx
+++ b/sax/inc/sax/tools/documenthandleradapter.hxx
@@ -61,7 +61,7 @@ namespace sax
}
virtual void SAL_CALL
- startElement(const ::rtl::OUString& aName,
+ startElement(const OUString& aName,
const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList > & xAttribs)
throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException)
{
@@ -69,27 +69,27 @@ namespace sax
}
virtual void SAL_CALL
- endElement(const ::rtl::OUString& aName) throw (::com::sun::star::xml::sax::SAXException,
+ endElement(const OUString& aName) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->endElement(aName);
}
virtual void SAL_CALL
- characters(const ::rtl::OUString& aChars) throw (::com::sun::star::xml::sax::SAXException,
+ characters(const OUString& aChars) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->characters(aChars);
}
virtual void SAL_CALL
- ignorableWhitespace(const ::rtl::OUString& aWhitespaces) throw (::com::sun::star::xml::sax::SAXException,
+ ignorableWhitespace(const OUString& aWhitespaces) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->ignorableWhitespace(aWhitespaces);
}
virtual void SAL_CALL
- processingInstruction(const ::rtl::OUString& aTarget, const ::rtl::OUString& aData)
+ processingInstruction(const OUString& aTarget, const OUString& aData)
throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException)
{
m_handler->processingInstruction(aTarget, aData);
@@ -153,7 +153,7 @@ namespace sax
}
virtual void SAL_CALL
- startElement(const ::rtl::OUString& aName,
+ startElement(const OUString& aName,
const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList > & xAttribs)
throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException)
{
@@ -161,27 +161,27 @@ namespace sax
}
virtual void SAL_CALL
- endElement(const ::rtl::OUString& aName) throw (::com::sun::star::xml::sax::SAXException,
+ endElement(const OUString& aName) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->endElement(aName);
}
virtual void SAL_CALL
- characters(const ::rtl::OUString& aChars) throw (::com::sun::star::xml::sax::SAXException,
+ characters(const OUString& aChars) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->characters(aChars);
}
virtual void SAL_CALL
- ignorableWhitespace(const ::rtl::OUString& aWhitespaces) throw (::com::sun::star::xml::sax::SAXException,
+ ignorableWhitespace(const OUString& aWhitespaces) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->ignorableWhitespace(aWhitespaces);
}
virtual void SAL_CALL
- processingInstruction(const ::rtl::OUString& aTarget, const ::rtl::OUString& aData)
+ processingInstruction(const OUString& aTarget, const OUString& aData)
throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException)
{
m_handler->processingInstruction(aTarget, aData);
@@ -204,13 +204,13 @@ namespace sax
m_handler->endCDATA();
}
virtual void SAL_CALL
- comment(const ::rtl::OUString& sComment) throw (::com::sun::star::xml::sax::SAXException,
+ comment(const OUString& sComment) throw (::com::sun::star::xml::sax::SAXException,
::com::sun::star::uno::RuntimeException)
{
m_handler->comment(sComment);
}
virtual void SAL_CALL
- unknown(const ::rtl::OUString& sString) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException)
+ unknown(const OUString& sString) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException)
{
m_handler->unknown(sString);
}
diff --git a/sax/inc/xml2utf.hxx b/sax/inc/xml2utf.hxx
index 9a6ee23e6ca3..bb1f6aca2dee 100644
--- a/sax/inc/xml2utf.hxx
+++ b/sax/inc/xml2utf.hxx
@@ -25,7 +25,7 @@ class Text2UnicodeConverter
{
public:
- Text2UnicodeConverter( const ::rtl::OString & sEncoding );
+ Text2UnicodeConverter( const OString & sEncoding );
~Text2UnicodeConverter();
::com::sun::star::uno::Sequence < sal_Unicode > convert( const ::com::sun::star::uno::Sequence<sal_Int8> & );
@@ -53,7 +53,7 @@ public:
Unicode2TextConverter( rtl_TextEncoding encoding );
~Unicode2TextConverter();
- inline ::com::sun::star::uno::Sequence<sal_Int8> convert( const ::rtl::OUString &s )
+ inline ::com::sun::star::uno::Sequence<sal_Int8> convert( const OUString &s )
{
return convert( s.getStr() , s.getLength() );
}
@@ -90,7 +90,7 @@ public:
~XMLFile2UTFConverter();
void setInputStream( ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > &r ) { m_in = r; }
- void setEncoding( const ::rtl::OString &s ) { m_sEncoding = s; }
+ void setEncoding( const OString &s ) { m_sEncoding = s; }
@@ -124,7 +124,7 @@ private:
::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > m_in;
sal_Bool m_bStarted;
- ::rtl::OString m_sEncoding;
+ OString m_sEncoding;
Text2UnicodeConverter *m_pText2Unicode;
Unicode2TextConverter *m_pUnicode2Text;
diff --git a/sax/qa/cppunit/test_converter.cxx b/sax/qa/cppunit/test_converter.cxx
index 7860092bf323..84d4da03db75 100644
--- a/sax/qa/cppunit/test_converter.cxx
+++ b/sax/qa/cppunit/test_converter.cxx
@@ -97,12 +97,12 @@ static void doTest(util::Duration const & rid, char const*const pis,
{
char const*const pos((i_pos) ? i_pos : pis);
util::Duration od;
- ::rtl::OUString is(::rtl::OUString::createFromAscii(pis));
+ OUString is(OUString::createFromAscii(pis));
bool bSuccess = Converter::convertDuration(od, is);
SAL_INFO("sax.cppunit","" << od.Negative << " " << od.Years << "Y " << od.Months << "M " << od.Days << "D " << od.Hours << "H " << od.Minutes << "M " << od.Seconds << "S " << od.MilliSeconds << "m");
CPPUNIT_ASSERT(bSuccess);
CPPUNIT_ASSERT(eqDuration(rid, od));
- ::rtl::OUStringBuffer buf;
+ OUStringBuffer buf;
Converter::convertDuration(buf, od);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT(buf.makeStringAndClear().equalsAscii(pos));
@@ -112,7 +112,7 @@ static void doTestDurationF(char const*const pis)
{
util::Duration od;
bool bSuccess = Converter::convertDuration(od,
- ::rtl::OUString::createFromAscii(pis));
+ OUString::createFromAscii(pis));
SAL_INFO("sax.cppunit","" << od.Negative << " " << od.Years << "Y " << od.Months << "M " << od.Days << "D " << od.Hours << "H " << od.Minutes << "M " << od.Seconds << "S " << od.MilliSeconds << "H");
CPPUNIT_ASSERT(!bSuccess);
}
@@ -162,13 +162,13 @@ static void doTest(util::DateTime const & rdt, char const*const pis,
char const*const i_pos = 0)
{
char const*const pos((i_pos) ? i_pos : pis);
- ::rtl::OUString is(::rtl::OUString::createFromAscii(pis));
+ OUString is(OUString::createFromAscii(pis));
util::DateTime odt;
bool bSuccess( Converter::convertDateTime(odt, is) );
SAL_INFO("sax.cppunit","Y:" << odt.Year << " M:" << odt.Month << " D:" << odt.Day << " H:" << odt.Hours << " M:" << odt.Minutes << " S:" << odt.Seconds << " H:" << odt.HundredthSeconds);
CPPUNIT_ASSERT(bSuccess);
CPPUNIT_ASSERT(eqDateTime(rdt, odt));
- ::rtl::OUStringBuffer buf;
+ OUStringBuffer buf;
Converter::convertDateTime(buf, odt, true);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT(buf.makeStringAndClear().equalsAscii(pos));
@@ -178,7 +178,7 @@ static void doTestDateTimeF(char const*const pis)
{
util::DateTime odt;
bool bSuccess = Converter::convertDateTime(odt,
- ::rtl::OUString::createFromAscii(pis));
+ OUString::createFromAscii(pis));
SAL_INFO("sax.cppunit","Y:" << odt.Year << " M:" << odt.Month << " D:" << odt.Day << " H:" << odt.Hours << "H M:" << odt.Minutes << " S:" << odt.Seconds << " H:" << odt.HundredthSeconds);
CPPUNIT_ASSERT(!bSuccess);
}
@@ -251,13 +251,13 @@ void ConverterTest::testDateTime()
void doTestDouble(char const*const pis, double const rd,
sal_Int16 const nSourceUnit, sal_Int16 const nTargetUnit)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
double od;
bool bSuccess(Converter::convertDouble(od, is, nSourceUnit, nTargetUnit));
SAL_INFO("sax.cppunit","" << od);
CPPUNIT_ASSERT(bSuccess);
CPPUNIT_ASSERT_DOUBLES_EQUAL(rd, od, 0.00000001);
- ::rtl::OUStringBuffer buf;
+ OUStringBuffer buf;
Converter::convertDouble(buf, od, true, nTargetUnit, nSourceUnit);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -317,7 +317,7 @@ void ConverterTest::testDouble()
void doTestStringToMeasure(sal_Int32 rValue, char const*const pis, sal_Int16 nTargetUnit, sal_Int32 nMin, sal_Int32 nMax)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
sal_Int32 nVal;
bool bSuccess(Converter::convertMeasure(nVal, is, nTargetUnit, nMin, nMax));
SAL_INFO("sax.cppunit","" << nVal);
@@ -327,8 +327,8 @@ void doTestStringToMeasure(sal_Int32 rValue, char const*const pis, sal_Int16 nTa
void doTestMeasureToString(char const*const pis, sal_Int32 nMeasure, sal_Int16 const nSourceUnit, sal_Int16 const nTargetUnit)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
- ::rtl::OUStringBuffer buf;
+ OUString const is(OUString::createFromAscii(pis));
+ OUStringBuffer buf;
Converter::convertMeasure(buf, nMeasure, nSourceUnit, nTargetUnit);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -380,7 +380,7 @@ void ConverterTest::testMeasure()
void doTestStringToBool(bool bBool, char const*const pis)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
bool bTemp;
bool bSuccess(Converter::convertBool(bTemp, is));
SAL_INFO("sax.cppunit","" << bTemp);
@@ -391,8 +391,8 @@ void doTestStringToBool(bool bBool, char const*const pis)
void doTestBoolToString(char const*const pis, bool bValue )
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
- ::rtl::OUStringBuffer buf;
+ OUString const is(OUString::createFromAscii(pis));
+ OUStringBuffer buf;
Converter::convertBool(buf, bValue);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -408,7 +408,7 @@ void ConverterTest::testBool()
void doTestStringToPercent(sal_Int32 nValue, char const*const pis)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
sal_Int32 nTemp;
bool bSuccess(Converter::convertPercent(nTemp, is));
SAL_INFO("sax.cppunit","" << nTemp);
@@ -418,8 +418,8 @@ void doTestStringToPercent(sal_Int32 nValue, char const*const pis)
void doTestPercentToString(char const*const pis, sal_Int32 nValue)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
- ::rtl::OUStringBuffer buf;
+ OUString const is(OUString::createFromAscii(pis));
+ OUStringBuffer buf;
Converter::convertPercent(buf, nValue);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -440,7 +440,7 @@ void ConverterTest::testPercent()
void doTestStringToColor(sal_Int32 nValue, char const*const pis)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
sal_Int32 nTemp;
bool bSuccess(Converter::convertColor(nTemp, is));
SAL_INFO("sax.cppunit","" << nTemp);
@@ -450,8 +450,8 @@ void doTestStringToColor(sal_Int32 nValue, char const*const pis)
void doTestColorToString(char const*const pis, sal_Int32 nValue)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
- ::rtl::OUStringBuffer buf;
+ OUString const is(OUString::createFromAscii(pis));
+ OUStringBuffer buf;
Converter::convertColor(buf, nValue);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -471,7 +471,7 @@ void ConverterTest::testColor()
void doTestStringToNumber(sal_Int32 nValue, char const*const pis, sal_Int32 nMin, sal_Int32 nMax)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
sal_Int32 nTemp;
bool bSuccess(Converter::convertNumber(nTemp, is, nMin, nMax));
SAL_INFO("sax.cppunit","" << nTemp);
@@ -481,8 +481,8 @@ void doTestStringToNumber(sal_Int32 nValue, char const*const pis, sal_Int32 nMin
void doTestNumberToString(char const*const pis, sal_Int32 nValue)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
- ::rtl::OUStringBuffer buf;
+ OUString const is(OUString::createFromAscii(pis));
+ OUStringBuffer buf;
Converter::convertNumber(buf, nValue);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -504,8 +504,8 @@ void ConverterTest::testNumber()
void doTestEncodeBase64(char const*const pis, const uno::Sequence<sal_Int8> aPass)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
- ::rtl::OUStringBuffer buf;
+ OUString const is(OUString::createFromAscii(pis));
+ OUStringBuffer buf;
Converter::encodeBase64(buf, aPass);
SAL_INFO("sax.cppunit","" << buf.getStr());
CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear());
@@ -513,7 +513,7 @@ void doTestEncodeBase64(char const*const pis, const uno::Sequence<sal_Int8> aPas
void doTestDecodeBase64(const uno::Sequence<sal_Int8> aPass, char const*const pis)
{
- ::rtl::OUString const is(::rtl::OUString::createFromAscii(pis));
+ OUString const is(OUString::createFromAscii(pis));
uno::Sequence< sal_Int8 > tempSequence;
Converter::decodeBase64(tempSequence, is);
SAL_INFO("sax.cppunit","" << is.getStr());
diff --git a/sax/source/expatwrap/attrlistimpl.hxx b/sax/source/expatwrap/attrlistimpl.hxx
index 52187f9826cd..2828651ad19a 100644
--- a/sax/source/expatwrap/attrlistimpl.hxx
+++ b/sax/source/expatwrap/attrlistimpl.hxx
@@ -42,22 +42,22 @@ public:
AttributeList( const AttributeList & );
virtual ~AttributeList();
- void addAttribute( const ::rtl::OUString &sName ,
- const ::rtl::OUString &sType , const ::rtl::OUString &sValue );
+ void addAttribute( const OUString &sName ,
+ const OUString &sType , const OUString &sValue );
void clear();
public:
// XAttributeList
virtual sal_Int16 SAL_CALL getLength(void)
throw(::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getNameByIndex(sal_Int16 i)
+ virtual OUString SAL_CALL getNameByIndex(sal_Int16 i)
throw(::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getTypeByIndex(sal_Int16 i)
+ virtual OUString SAL_CALL getTypeByIndex(sal_Int16 i)
throw(::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getTypeByName(const ::rtl::OUString& aName)
+ virtual OUString SAL_CALL getTypeByName(const OUString& aName)
throw(::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getValueByIndex(sal_Int16 i)
+ virtual OUString SAL_CALL getValueByIndex(sal_Int16 i)
throw(::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getValueByName(const ::rtl::OUString& aName)
+ virtual OUString SAL_CALL getValueByName(const OUString& aName)
throw( ::com::sun::star::uno::RuntimeException);
// XCloneable
diff --git a/sax/source/expatwrap/sax_expat.cxx b/sax/source/expatwrap/sax_expat.cxx
index 72b84e2ffae0..4661256854c4 100644
--- a/sax/source/expatwrap/sax_expat.cxx
+++ b/sax/source/expatwrap/sax_expat.cxx
@@ -199,7 +199,7 @@ Reference< XInterface > SAL_CALL SaxExpatParser_CreateInstance(
Sequence< OUString > SaxExpatParser::getSupportedServiceNames_Static(void) throw ()
{
Sequence<OUString> aRet(1);
- aRet.getArray()[0] = ::rtl::OUString( SERVICE_NAME );
+ aRet.getArray()[0] = OUString( SERVICE_NAME );
return aRet;
}
diff --git a/sax/source/expatwrap/saxwriter.cxx b/sax/source/expatwrap/saxwriter.cxx
index cfdf61982adb..20660eb150d8 100644
--- a/sax/source/expatwrap/saxwriter.cxx
+++ b/sax/source/expatwrap/saxwriter.cxx
@@ -118,7 +118,7 @@ public:
// returns whether it works correct or invalid characters were in the string
// If there are invalid characters in the string it returns sal_False.
// Than the calling method has to throw the needed Exception.
- inline sal_Bool writeString(const rtl::OUString& rWriteOutString,
+ inline sal_Bool writeString(const OUString& rWriteOutString,
sal_Bool bDoNormalization,
sal_Bool bNormalizeWhitespace) throw( SAXException );
@@ -130,26 +130,26 @@ public:
// returns whether it works correct or invalid characters were in the strings
// If there are invalid characters in one of the strings it returns sal_False.
// Than the calling method has to throw the needed Exception.
- inline SaxInvalidCharacterError startElement(const rtl::OUString& rName, const Reference< XAttributeList >& xAttribs) throw( SAXException );
+ inline SaxInvalidCharacterError startElement(const OUString& rName, const Reference< XAttributeList >& xAttribs) throw( SAXException );
inline sal_Bool FinishEmptyElement() throw( SAXException );
// returns whether it works correct or invalid characters were in the string
// If there are invalid characters in the string it returns sal_False.
// Than the calling method has to throw the needed Exception.
- inline sal_Bool endElement(const rtl::OUString& rName) throw( SAXException );
+ inline sal_Bool endElement(const OUString& rName) throw( SAXException );
inline void endDocument() throw( SAXException );
// returns whether it works correct or invalid characters were in the strings
// If there are invalid characters in the string it returns sal_False.
// Than the calling method has to throw the needed Exception.
- inline sal_Bool processingInstruction(const rtl::OUString& rTarget, const rtl::OUString& rData) throw( SAXException );
+ inline sal_Bool processingInstruction(const OUString& rTarget, const OUString& rData) throw( SAXException );
inline void startCDATA() throw( SAXException );
inline void endCDATA() throw( SAXException );
// returns whether it works correct or invalid characters were in the strings
// If there are invalid characters in the string it returns sal_False.
// Than the calling method has to throw the needed Exception.
- inline sal_Bool comment(const rtl::OUString& rComment) throw( SAXException );
+ inline sal_Bool comment(const OUString& rComment) throw( SAXException );
inline void clearBuffer() throw( SAXException );
};
@@ -503,7 +503,7 @@ inline void SaxWriterHelper::insertIndentation(sal_uInt32 m_nLevel) throw( SAXEx
}
}
-inline sal_Bool SaxWriterHelper::writeString( const rtl::OUString& rWriteOutString,
+inline sal_Bool SaxWriterHelper::writeString( const OUString& rWriteOutString,
sal_Bool bDoNormalization,
sal_Bool bNormalizeWhitespace ) throw( SAXException )
{
@@ -538,7 +538,7 @@ inline void SaxWriterHelper::startDocument() throw( SAXException )
nCurrentPos = writeSequence();
}
-inline SaxInvalidCharacterError SaxWriterHelper::startElement(const rtl::OUString& rName, const Reference< XAttributeList >& xAttribs) throw( SAXException )
+inline SaxInvalidCharacterError SaxWriterHelper::startElement(const OUString& rName, const Reference< XAttributeList >& xAttribs) throw( SAXException )
{
FinishStartElement();
mp_Sequence[nCurrentPos] = '<';
@@ -605,7 +605,7 @@ inline sal_Bool SaxWriterHelper::FinishEmptyElement() throw( SAXException )
return sal_True;
}
-inline sal_Bool SaxWriterHelper::endElement(const rtl::OUString& rName) throw( SAXException )
+inline sal_Bool SaxWriterHelper::endElement(const OUString& rName) throw( SAXException )
{
FinishStartElement();
mp_Sequence[nCurrentPos] = '<';
@@ -650,7 +650,7 @@ inline void SaxWriterHelper::clearBuffer() throw( SAXException )
}
}
-inline sal_Bool SaxWriterHelper::processingInstruction(const rtl::OUString& rTarget, const rtl::OUString& rData) throw( SAXException )
+inline sal_Bool SaxWriterHelper::processingInstruction(const OUString& rTarget, const OUString& rData) throw( SAXException )
{
FinishStartElement();
mp_Sequence[nCurrentPos] = '<';
@@ -712,7 +712,7 @@ inline void SaxWriterHelper::endCDATA() throw( SAXException )
nCurrentPos = writeSequence();
}
-inline sal_Bool SaxWriterHelper::comment(const rtl::OUString& rComment) throw( SAXException )
+inline sal_Bool SaxWriterHelper::comment(const OUString& rComment) throw( SAXException )
{
FinishStartElement();
mp_Sequence[nCurrentPos] = '<';
diff --git a/sax/source/expatwrap/xml2utf.cxx b/sax/source/expatwrap/xml2utf.cxx
index 69065c64720e..76713d99ef84 100644
--- a/sax/source/expatwrap/xml2utf.cxx
+++ b/sax/source/expatwrap/xml2utf.cxx
@@ -30,7 +30,6 @@
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::io;
-using ::rtl::OString;
#include "xml2utf.hxx"
diff --git a/sax/source/fastparser/facreg.cxx b/sax/source/fastparser/facreg.cxx
index b0b5848544b4..fbf746f680fd 100644
--- a/sax/source/fastparser/facreg.cxx
+++ b/sax/source/fastparser/facreg.cxx
@@ -27,7 +27,6 @@ using namespace sax_fastparser;
using namespace ::cppu;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::registry;
-using ::rtl::OUString;
using namespace ::com::sun::star::lang;
namespace sax_fastparser
diff --git a/sax/source/fastparser/fastparser.cxx b/sax/source/fastparser/fastparser.cxx
index 601905b80e26..1a80ed1ab65a 100644
--- a/sax/source/fastparser/fastparser.cxx
+++ b/sax/source/fastparser/fastparser.cxx
@@ -31,9 +31,6 @@
#include <string.h>
-using ::rtl::OString;
-using ::rtl::OUString;
-using ::rtl::OUStringBuffer;
using namespace ::std;
using namespace ::osl;
using namespace ::cppu;
@@ -557,7 +554,7 @@ void FastSaxParser::setLocale( const Locale & Locale ) throw (RuntimeException)
Sequence< OUString > FastSaxParser::getSupportedServiceNames_Static(void)
{
Sequence<OUString> aRet(1);
- aRet.getArray()[0] = ::rtl::OUString( PARSER_SERVICE_NAME );
+ aRet.getArray()[0] = OUString( PARSER_SERVICE_NAME );
return aRet;
}
diff --git a/sax/source/fastparser/fastparser.hxx b/sax/source/fastparser/fastparser.hxx
index d72b7ffd6095..dab438f81422 100644
--- a/sax/source/fastparser/fastparser.hxx
+++ b/sax/source/fastparser/fastparser.hxx
@@ -48,8 +48,8 @@ struct SaxContextImpl;
typedef ::boost::shared_ptr< SaxContextImpl > SaxContextImplPtr;
typedef ::boost::shared_ptr< NamespaceDefine > NamespaceDefineRef;
-typedef ::boost::unordered_map< ::rtl::OUString, sal_Int32,
- ::rtl::OUStringHash, ::std::equal_to< ::rtl::OUString > > NamespaceMap;
+typedef ::boost::unordered_map< OUString, sal_Int32,
+ OUStringHash, ::std::equal_to< OUString > > NamespaceMap;
// --------------------------------------------------------------------
@@ -96,22 +96,22 @@ public:
virtual ~FastSaxParser();
// The implementation details
- static ::com::sun::star::uno::Sequence< ::rtl::OUString > getSupportedServiceNames_Static(void);
+ static ::com::sun::star::uno::Sequence< OUString > getSupportedServiceNames_Static(void);
// XFastParser
virtual void SAL_CALL parseStream( const ::com::sun::star::xml::sax::InputSource& aInputSource ) throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL setFastDocumentHandler( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XFastDocumentHandler >& Handler ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL setTokenHandler( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XFastTokenHandler >& Handler ) throw (::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL registerNamespace( const ::rtl::OUString& NamespaceURL, sal_Int32 NamespaceToken ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
- virtual ::rtl::OUString SAL_CALL getNamespaceURL( const ::rtl::OUString& rPrefix ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
+ virtual void SAL_CALL registerNamespace( const OUString& NamespaceURL, sal_Int32 NamespaceToken ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
+ virtual OUString SAL_CALL getNamespaceURL( const OUString& rPrefix ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL setErrorHandler( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XErrorHandler >& Handler ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL setEntityResolver( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XEntityResolver >& Resolver ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL setLocale( const ::com::sun::star::lang::Locale& rLocale ) throw (::com::sun::star::uno::RuntimeException);
// XServiceInfo
- virtual ::rtl::OUString SAL_CALL getImplementationName( ) throw (::com::sun::star::uno::RuntimeException);
- virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames( ) throw (::com::sun::star::uno::RuntimeException);
+ virtual OUString SAL_CALL getImplementationName( ) throw (::com::sun::star::uno::RuntimeException);
+ virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) throw (::com::sun::star::uno::RuntimeException);
// called by the C callbacks of the expat parser
void callbackStartElement( const XML_Char* name, const XML_Char** atts );
@@ -130,15 +130,15 @@ public:
private:
void parse();
- sal_Int32 GetToken( const ::rtl::OString& rToken );
+ sal_Int32 GetToken( const OString& rToken );
sal_Int32 GetToken( const sal_Char* pToken, sal_Int32 nTokenLen = 0 );
- sal_Int32 GetTokenWithPrefix( const ::rtl::OString& rPrefix, const ::rtl::OString& rName ) throw (::com::sun::star::xml::sax::SAXException);
+ sal_Int32 GetTokenWithPrefix( const OString& rPrefix, const OString& rName ) throw (::com::sun::star::xml::sax::SAXException);
sal_Int32 GetTokenWithPrefix( const sal_Char*pPrefix, int nPrefixLen, const sal_Char* pName, int nNameLen ) throw (::com::sun::star::xml::sax::SAXException);
- ::rtl::OUString GetNamespaceURL( const ::rtl::OString& rPrefix ) throw (::com::sun::star::xml::sax::SAXException);
- ::rtl::OUString GetNamespaceURL( const sal_Char*pPrefix, int nPrefixLen ) throw (::com::sun::star::xml::sax::SAXException);
- sal_Int32 GetNamespaceToken( const ::rtl::OUString& rNamespaceURL );
- sal_Int32 GetTokenWithNamespaceURL( const ::rtl::OUString& rNamespaceURL, const sal_Char* pName, int nNameLen );
- void DefineNamespace( const ::rtl::OString& rPrefix, const sal_Char* pNamespaceURL );
+ OUString GetNamespaceURL( const OString& rPrefix ) throw (::com::sun::star::xml::sax::SAXException);
+ OUString GetNamespaceURL( const sal_Char*pPrefix, int nPrefixLen ) throw (::com::sun::star::xml::sax::SAXException);
+ sal_Int32 GetNamespaceToken( const OUString& rNamespaceURL );
+ sal_Int32 GetTokenWithNamespaceURL( const OUString& rNamespaceURL, const sal_Char* pName, int nNameLen );
+ void DefineNamespace( const OString& rPrefix, const sal_Char* pNamespaceURL );
sal_Int32 CreateCustomToken( const sal_Char* pToken, int len = 0 );
void pushContext();
diff --git a/sax/source/tools/converter.cxx b/sax/source/tools/converter.cxx
index af36a027f5fb..22fa9060b154 100644
--- a/sax/source/tools/converter.cxx
+++ b/sax/source/tools/converter.cxx
@@ -34,8 +34,6 @@ using namespace com::sun::star::uno;
using namespace com::sun::star::util;
using namespace ::com::sun::star::i18n;
-using ::rtl::OUString;
-using ::rtl::OUStringBuffer;
namespace sax {
@@ -603,14 +601,14 @@ void Converter::convertDouble( OUStringBuffer& rBuffer,
}
/** convert double number to string (using ::rtl::math) */
-void Converter::convertDouble( ::rtl::OUStringBuffer& rBuffer, double fNumber)
+void Converter::convertDouble( OUStringBuffer& rBuffer, double fNumber)
{
::rtl::math::doubleToUStringBuffer( rBuffer, fNumber, rtl_math_StringFormat_Automatic, rtl_math_DecimalPlaces_Max, '.', true);
}
/** convert string to double number (using ::rtl::math) */
bool Converter::convertDouble(double& rValue,
- const ::rtl::OUString& rString, sal_Int16 nSourceUnit, sal_Int16 nTargetUnit)
+ const OUString& rString, sal_Int16 nSourceUnit, sal_Int16 nTargetUnit)
{
rtl_math_ConversionStatus eStatus;
rValue = ::rtl::math::stringToDouble( rString, (sal_Unicode)('.'), (sal_Unicode)(','), &eStatus, NULL );
@@ -629,7 +627,7 @@ bool Converter::convertDouble(double& rValue,
}
/** convert string to double number (using ::rtl::math) */
-bool Converter::convertDouble(double& rValue, const ::rtl::OUString& rString)
+bool Converter::convertDouble(double& rValue, const OUString& rString)
{
rtl_math_ConversionStatus eStatus;
rValue = ::rtl::math::stringToDouble( rString, (sal_Unicode)('.'), (sal_Unicode)(','), &eStatus, NULL );
@@ -637,7 +635,7 @@ bool Converter::convertDouble(double& rValue, const ::rtl::OUString& rString)
}
/** convert double to ISO "duration" string; negative durations allowed */
-void Converter::convertDuration(::rtl::OUStringBuffer& rBuffer,
+void Converter::convertDuration(OUStringBuffer& rBuffer,
const double fTime)
{
double fValue = fTime;
@@ -695,7 +693,7 @@ void Converter::convertDuration(::rtl::OUStringBuffer& rBuffer,
rBuffer.append( sal_Int32( fSecsValue));
if (f100SecsValue > 0.0)
{
- ::rtl::OUString a100th( ::rtl::math::doubleToUString( fValue,
+ OUString a100th( ::rtl::math::doubleToUString( fValue,
rtl_math_StringFormat_F, XML_MAXDIGITSCOUNT_TIME - 5, '.',
true));
if ( a100th.getLength() > 2 )
@@ -709,9 +707,9 @@ void Converter::convertDuration(::rtl::OUStringBuffer& rBuffer,
/** convert ISO "duration" string to double; negative durations allowed */
bool Converter::convertDuration(double& rfTime,
- const ::rtl::OUString& rString)
+ const OUString& rString)
{
- rtl::OUString aTrimmed = rString.trim().toAsciiUpperCase();
+ OUString aTrimmed = rString.trim().toAsciiUpperCase();
const sal_Unicode* pStr = aTrimmed.getStr();
// negative time duration?
@@ -725,7 +723,7 @@ bool Converter::convertDuration(double& rfTime,
if ( *(pStr++) != sal_Unicode('P') ) // duration must start with "P"
return false;
- rtl::OUString sDoubleStr;
+ OUString sDoubleStr;
bool bSuccess = true;
bool bDone = false;
bool bTimePart = false;
@@ -838,7 +836,7 @@ bool Converter::convertDuration(double& rfTime,
}
/** convert util::Duration to ISO "duration" string */
-void Converter::convertDuration(::rtl::OUStringBuffer& rBuffer,
+void Converter::convertDuration(OUStringBuffer& rBuffer,
const ::util::Duration& rDuration)
{
if (rDuration.Negative)
@@ -926,7 +924,7 @@ void Converter::convertDuration(::rtl::OUStringBuffer& rBuffer,
enum Result { R_NOTHING, R_OVERFLOW, R_SUCCESS };
static Result
-readUnsignedNumber(const ::rtl::OUString & rString,
+readUnsignedNumber(const OUString & rString,
sal_Int32 & io_rnPos, sal_Int32 & o_rNumber)
{
bool bOverflow(false);
@@ -964,7 +962,7 @@ readUnsignedNumber(const ::rtl::OUString & rString,
}
static bool
-readDurationT(const ::rtl::OUString & rString, sal_Int32 & io_rnPos)
+readDurationT(const OUString & rString, sal_Int32 & io_rnPos)
{
if ((io_rnPos < rString.getLength()) &&
(rString[io_rnPos] == sal_Unicode('T')))
@@ -976,7 +974,7 @@ readDurationT(const ::rtl::OUString & rString, sal_Int32 & io_rnPos)
}
static bool
-readDurationComponent(const ::rtl::OUString & rString,
+readDurationComponent(const OUString & rString,
sal_Int32 & io_rnPos, sal_Int32 & io_rnTemp, bool & io_rbTimePart,
sal_Int32 & o_rnTarget, const sal_Unicode c)
{
@@ -1007,9 +1005,9 @@ readDurationComponent(const ::rtl::OUString & rString,
/** convert ISO "duration" string to util::Duration */
bool Converter::convertDuration(util::Duration& rDuration,
- const ::rtl::OUString& rString)
+ const OUString& rString)
{
- const ::rtl::OUString string = rString.trim().toAsciiUpperCase();
+ const OUString string = rString.trim().toAsciiUpperCase();
sal_Int32 nPos(0);
bool bIsNegativeDuration(false);
@@ -1175,7 +1173,7 @@ bool Converter::convertDuration(util::Duration& rDuration,
/** convert util::Date to ISO "date" string */
void Converter::convertDate(
- ::rtl::OUStringBuffer& i_rBuffer,
+ OUStringBuffer& i_rBuffer,
const util::Date& i_rDate)
{
const util::DateTime dt(
@@ -1185,7 +1183,7 @@ void Converter::convertDate(
/** convert util::DateTime to ISO "date" or "dateTime" string */
void Converter::convertDateTime(
- ::rtl::OUStringBuffer& i_rBuffer,
+ OUStringBuffer& i_rBuffer,
const com::sun::star::util::DateTime& i_rDateTime,
bool i_bAddTimeIf0AM )
{
@@ -1247,7 +1245,7 @@ void Converter::convertDateTime(
/** convert ISO "date" or "dateTime" string to util::DateTime */
bool Converter::convertDateTime( util::DateTime& rDateTime,
- const ::rtl::OUString& rString )
+ const OUString& rString )
{
bool isDateTime;
util::Date date;
@@ -1272,7 +1270,7 @@ bool Converter::convertDateTime( util::DateTime& rDateTime,
}
static bool
-readDateTimeComponent(const ::rtl::OUString & rString,
+readDateTimeComponent(const OUString & rString,
sal_Int32 & io_rnPos, sal_Int32 & o_rnTarget,
const sal_Int32 nMinLength, const bool bExactLength)
{
@@ -1314,11 +1312,11 @@ lcl_MaxDaysPerMonth(const sal_Int32 nMonth, const sal_Int32 nYear)
/** convert ISO "date" or "dateTime" string to util::DateTime or util::Date */
bool Converter::convertDateOrDateTime(
util::Date & rDate, util::DateTime & rDateTime,
- bool & rbDateTime, const ::rtl::OUString & rString )
+ bool & rbDateTime, const OUString & rString )
{
bool bSuccess = true;
- const ::rtl::OUString string = rString.trim().toAsciiUpperCase();
+ const OUString string = rString.trim().toAsciiUpperCase();
sal_Int32 nPos(0);
if (string.getLength() > nPos)
{
@@ -1618,7 +1616,7 @@ const
-void ThreeByteToFourByte (const sal_Int8* pBuffer, const sal_Int32 nStart, const sal_Int32 nFullLen, rtl::OUStringBuffer& sBuffer)
+void ThreeByteToFourByte (const sal_Int8* pBuffer, const sal_Int32 nStart, const sal_Int32 nFullLen, OUStringBuffer& sBuffer)
{
sal_Int32 nLen(nFullLen - nStart);
if (nLen > 3)
@@ -1671,7 +1669,7 @@ void ThreeByteToFourByte (const sal_Int8* pBuffer, const sal_Int32 nStart, const
sBuffer.append(buf, SAL_N_ELEMENTS(buf));
}
-void Converter::encodeBase64(rtl::OUStringBuffer& aStrBuffer, const uno::Sequence<sal_Int8>& aPass)
+void Converter::encodeBase64(OUStringBuffer& aStrBuffer, const uno::Sequence<sal_Int8>& aPass)
{
sal_Int32 i(0);
sal_Int32 nBufferLength(aPass.getLength());
@@ -1683,7 +1681,7 @@ void Converter::encodeBase64(rtl::OUStringBuffer& aStrBuffer, const uno::Sequenc
}
}
-void Converter::decodeBase64(uno::Sequence<sal_Int8>& aBuffer, const rtl::OUString& sBuffer)
+void Converter::decodeBase64(uno::Sequence<sal_Int8>& aBuffer, const OUString& sBuffer)
{
#if OSL_DEBUG_LEVEL > 0
sal_Int32 nCharsDecoded =
@@ -1694,7 +1692,7 @@ void Converter::decodeBase64(uno::Sequence<sal_Int8>& aBuffer, const rtl::OUStri
sal_Int32 Converter::decodeBase64SomeChars(
uno::Sequence<sal_Int8>& rOutBuffer,
- const rtl::OUString& rInBuffer)
+ const OUString& rInBuffer)
{
sal_Int32 nInBufferLen = rInBuffer.getLength();
sal_Int32 nMinOutBufferLen = (nInBufferLen / 4) * 3;
@@ -1762,7 +1760,7 @@ sal_Int32 Converter::decodeBase64SomeChars(
return nCharsDecoded;
}
-double Converter::GetConversionFactor(::rtl::OUStringBuffer& rUnit, sal_Int16 nSourceUnit, sal_Int16 nTargetUnit)
+double Converter::GetConversionFactor(OUStringBuffer& rUnit, sal_Int16 nSourceUnit, sal_Int16 nTargetUnit)
{
double fRetval(1.0);
rUnit.setLength(0L);
@@ -2117,7 +2115,7 @@ double Converter::GetConversionFactor(::rtl::OUStringBuffer& rUnit, sal_Int16 nS
return fRetval;
}
-sal_Int16 Converter::GetUnitFromString(const ::rtl::OUString& rString, sal_Int16 nDefaultUnit)
+sal_Int16 Converter::GetUnitFromString(const OUString& rString, sal_Int16 nDefaultUnit)
{
sal_Int32 nPos = 0L;
sal_Int32 nLen = rString.getLength();
@@ -2203,8 +2201,8 @@ sal_Int16 Converter::GetUnitFromString(const ::rtl::OUString& rString, sal_Int16
}
-bool Converter::convertAny(::rtl::OUStringBuffer& rsValue,
- ::rtl::OUStringBuffer& rsType ,
+bool Converter::convertAny(OUStringBuffer& rsValue,
+ OUStringBuffer& rsType ,
const com::sun::star::uno::Any& rValue)
{
bool bConverted = false;
@@ -2257,7 +2255,7 @@ bool Converter::convertAny(::rtl::OUStringBuffer& rsValue,
case com::sun::star::uno::TypeClass_STRING :
{
- ::rtl::OUString sTempValue;
+ OUString sTempValue;
if (rValue >>= sTempValue)
{
rsType.appendAscii("string");
diff --git a/sax/source/tools/fastattribs.cxx b/sax/source/tools/fastattribs.cxx
index fdf9066ab3f4..bb348a4cc61c 100644
--- a/sax/source/tools/fastattribs.cxx
+++ b/sax/source/tools/fastattribs.cxx
@@ -21,8 +21,6 @@
#include <sax/fastattribs.hxx>
-using ::rtl::OUString;
-using ::rtl::OString;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::xml;
using namespace ::com::sun::star::xml::sax;
diff --git a/sax/source/tools/fastserializer.cxx b/sax/source/tools/fastserializer.cxx
index 9966b856265e..eba4548ee6c5 100644
--- a/sax/source/tools/fastserializer.cxx
+++ b/sax/source/tools/fastserializer.cxx
@@ -33,10 +33,6 @@
#endif
using ::comphelper::SequenceAsVector;
-using ::rtl::OString;
-using ::rtl::OUString;
-using ::rtl::OUStringBuffer;
-using ::rtl::OUStringToOString;
using ::com::sun::star::uno::Reference;
using ::com::sun::star::uno::RuntimeException;
using ::com::sun::star::uno::Sequence;
@@ -82,7 +78,7 @@ namespace sax_fastparser {
OUString FastSaxSerializer::escapeXml( const OUString& s )
{
- ::rtl::OUStringBuffer sBuf( s.getLength() );
+ OUStringBuffer sBuf( s.getLength() );
const sal_Unicode* pStr = s.getStr();
sal_Int32 nLen = s.getLength();
for( sal_Int32 i = 0; i < nLen; ++i)
diff --git a/sax/source/tools/fastserializer.hxx b/sax/source/tools/fastserializer.hxx
index 4e9f87115e6d..38c8e89f4e59 100644
--- a/sax/source/tools/fastserializer.hxx
+++ b/sax/source/tools/fastserializer.hxx
@@ -100,7 +100,7 @@ public:
throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException);
/// receives notification of character data.
- void SAL_CALL characters( const ::rtl::OUString& aChars )
+ void SAL_CALL characters( const OUString& aChars )
throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException);
void SAL_CALL setOutputStream( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream >& xOutputStream )
@@ -112,7 +112,7 @@ public:
// C++ helpers
void SAL_CALL writeId( ::sal_Int32 Element );
- static ::rtl::OUString escapeXml( const ::rtl::OUString& s );
+ static OUString escapeXml( const OUString& s );
public:
/** From now on, don't write directly to the stream, but to top of a stack.
@@ -208,7 +208,7 @@ private:
::std::stack< boost::shared_ptr< ForMerge > > maSavedMarkStack;
void writeFastAttributeList( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XFastAttributeList >& Attribs );
- void write( const ::rtl::OUString& s );
+ void write( const OUString& s );
protected:
rtl::ByteSequence maClosingBracket;
diff --git a/sax/source/tools/fshelper.cxx b/sax/source/tools/fshelper.cxx
index 314e60b007d8..888ed7df52a7 100644
--- a/sax/source/tools/fshelper.cxx
+++ b/sax/source/tools/fshelper.cxx
@@ -33,7 +33,7 @@ FastSerializerHelper::FastSerializerHelper(const Reference< io::XOutputStream >&
{
Reference< XComponentContext > xContext( ::comphelper::getProcessComponentContext(), UNO_SET_THROW );
Reference< lang::XMultiComponentFactory > xFactory( xContext->getServiceManager(), UNO_SET_THROW );
- mxTokenHandler.set( xFactory->createInstanceWithContext( rtl::OUString( "com.sun.star.xml.sax.FastTokenHandler"), xContext ), UNO_QUERY_THROW );
+ mxTokenHandler.set( xFactory->createInstanceWithContext( OUString( "com.sun.star.xml.sax.FastTokenHandler"), xContext ), UNO_QUERY_THROW );
mpSerializer->setFastTokenHandler( mxTokenHandler );
mpSerializer->setOutputStream( xOutputStream );
@@ -107,10 +107,10 @@ void FastSerializerHelper::singleElement(sal_Int32 elementTokenId, XFastAttribut
FastSerializerHelper* FastSerializerHelper::write(const char* value)
{
- return write(rtl::OUString::createFromAscii(value));
+ return write(OUString::createFromAscii(value));
}
-FastSerializerHelper* FastSerializerHelper::write(const rtl::OUString& value)
+FastSerializerHelper* FastSerializerHelper::write(const OUString& value)
{
mpSerializer->characters(value);
return this;
@@ -118,25 +118,25 @@ FastSerializerHelper* FastSerializerHelper::write(const rtl::OUString& value)
FastSerializerHelper* FastSerializerHelper::write(sal_Int32 value)
{
- return write(::rtl::OUString::valueOf(value));
+ return write(OUString::valueOf(value));
}
FastSerializerHelper* FastSerializerHelper::write(sal_Int64 value)
{
- return write(::rtl::OUString::valueOf(value));
+ return write(OUString::valueOf(value));
}
FastSerializerHelper* FastSerializerHelper::write(double value)
{
- return write(::rtl::OUString::valueOf(value));
+ return write(OUString::valueOf(value));
}
FastSerializerHelper* FastSerializerHelper::writeEscaped(const char* value)
{
- return writeEscaped(::rtl::OUString::createFromAscii(value));
+ return writeEscaped(OUString::createFromAscii(value));
}
-FastSerializerHelper* FastSerializerHelper::writeEscaped(const ::rtl::OUString& value)
+FastSerializerHelper* FastSerializerHelper::writeEscaped(const OUString& value)
{
return write(FastSaxSerializer::escapeXml(value));
}