diff options
author | Chr. Rossmanith <ChrRossmanith@gmx.de> | 2013-03-19 23:07:53 +0100 |
---|---|---|
committer | Noel Power <noel.power@suse.com> | 2013-03-20 12:10:09 +0000 |
commit | 9d548d56cf19b01273f719b52a45f48ab13ed45a (patch) | |
tree | 8b60dd5d056f93cb38bcd25c124b97e26c09a3f5 /unotools | |
parent | 77c87c18697e19cb4606717af0e4b0e5ab2139bc (diff) |
Replace String with OUString (unotools)
Change-Id: I9a0677cb36805d0a27514824c937901f73fee1c8
Reviewed-on: https://gerrit.libreoffice.org/2864
Reviewed-by: Noel Power <noel.power@suse.com>
Tested-by: Noel Power <noel.power@suse.com>
Diffstat (limited to 'unotools')
-rw-r--r-- | unotools/inc/unotools/localfilehelper.hxx | 4 | ||||
-rw-r--r-- | unotools/source/ucbhelper/localfilehelper.cxx | 18 |
2 files changed, 11 insertions, 11 deletions
diff --git a/unotools/inc/unotools/localfilehelper.hxx b/unotools/inc/unotools/localfilehelper.hxx index 99831f76f6ed..963b6cadbb7d 100644 --- a/unotools/inc/unotools/localfilehelper.hxx +++ b/unotools/inc/unotools/localfilehelper.hxx @@ -36,7 +36,7 @@ namespace utl Returning sal_True and an empty URL means that the URL doesn't point to a local file. */ static bool ConvertPhysicalNameToURL(const rtl::OUString& rName, rtl::OUString& rReturn); - static sal_Bool ConvertSystemPathToURL( const String& rName, const String& rBaseURL, String& rReturn ); + static sal_Bool ConvertSystemPathToURL( const OUString& rName, const OUString& rBaseURL, OUString& rReturn ); /** Converts a "UCB compatible" URL into a "physical" file name. @@ -45,7 +45,7 @@ namespace utl file system is present ( watch: this doesn't mean that this file really exists! ) */ static bool ConvertURLToPhysicalName( const rtl::OUString& rName, rtl::OUString& rReturn ); - static sal_Bool ConvertURLToSystemPath( const String& rName, String& rReturn ); + static sal_Bool ConvertURLToSystemPath( const OUString& rName, OUString& rReturn ); static sal_Bool IsLocalFile(const rtl::OUString& rName); static sal_Bool IsFileContent(const rtl::OUString& rName); diff --git a/unotools/source/ucbhelper/localfilehelper.cxx b/unotools/source/ucbhelper/localfilehelper.cxx index ef0acbecde90..e02da35de73d 100644 --- a/unotools/source/ucbhelper/localfilehelper.cxx +++ b/unotools/source/ucbhelper/localfilehelper.cxx @@ -37,9 +37,9 @@ using namespace ::com::sun::star::ucb; namespace utl { -sal_Bool LocalFileHelper::ConvertSystemPathToURL( const String& rName, const String& rBaseURL, String& rReturn ) +sal_Bool LocalFileHelper::ConvertSystemPathToURL( const OUString& rName, const OUString& rBaseURL, OUString& rReturn ) { - rReturn = ::rtl::OUString(); + rReturn = ""; Reference< XUniversalContentBroker > pBroker( UniversalContentBroker::create( @@ -53,12 +53,12 @@ sal_Bool LocalFileHelper::ConvertSystemPathToURL( const String& rName, const Str return sal_False; } - return ( rReturn.Len() != 0 ); + return !rReturn.isEmpty(); } -sal_Bool LocalFileHelper::ConvertURLToSystemPath( const String& rName, String& rReturn ) +sal_Bool LocalFileHelper::ConvertURLToSystemPath( const OUString& rName, OUString& rReturn ) { - rReturn = ::rtl::OUString(); + rReturn = ""; Reference< XUniversalContentBroker > pBroker( UniversalContentBroker::create( comphelper::getProcessComponentContext() ) ); @@ -70,7 +70,7 @@ sal_Bool LocalFileHelper::ConvertURLToSystemPath( const String& rName, String& r { } - return ( rReturn.Len() != 0 ); + return !rReturn.isEmpty(); } bool LocalFileHelper::ConvertPhysicalNameToURL(const rtl::OUString& rName, rtl::OUString& rReturn) @@ -93,7 +93,7 @@ bool LocalFileHelper::ConvertPhysicalNameToURL(const rtl::OUString& rName, rtl:: bool LocalFileHelper::ConvertURLToPhysicalName(const rtl::OUString& rName, rtl::OUString& rReturn) { - rReturn = ::rtl::OUString(); + rReturn = ""; Reference< XUniversalContentBroker > pBroker( UniversalContentBroker::create( comphelper::getProcessComponentContext() ) ); @@ -119,7 +119,7 @@ sal_Bool LocalFileHelper::IsLocalFile(const rtl::OUString& rName) sal_Bool LocalFileHelper::IsFileContent(const rtl::OUString& rName) { - String aTmp; + OUString aTmp; return ConvertURLToSystemPath(rName, aTmp); } @@ -136,7 +136,7 @@ typedef ::std::vector< ::rtl::OUString* > StringList_Impl; Reference< ::com::sun::star::sdbc::XResultSet > xResultSet; ::com::sun::star::uno::Sequence< ::rtl::OUString > aProps(1); ::rtl::OUString* pProps = aProps.getArray(); - pProps[0] = ::rtl::OUString("Url"); + pProps[0] = "Url"; try { |