[Libreoffice-commits] .: io/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Sat Dec 1 06:45:55 PST 2012


 io/source/TextInputStream/TextInputStream.cxx   |    6 +++---
 io/source/TextOutputStream/TextOutputStream.cxx |    6 +++---
 io/source/stm/odata.cxx                         |   16 ++++++++--------
 io/source/stm/omark.cxx                         |   18 +++++++++---------
 io/source/stm/opipe.cxx                         |   18 +++++++++---------
 io/source/stm/opump.cxx                         |   10 +++++-----
 6 files changed, 37 insertions(+), 37 deletions(-)

New commits:
commit f73201e54af8c3e36342811653dd5fbcafb291fb
Author: José Guilherme Vanz <guilherme.sft at gmail.com>
Date:   Fri Nov 30 22:00:48 2012 -0200

    Removal ::rtl:: prefixes and macros in IO
    
    This commit removes some ::rtl:: prefixes and RTL_CONSTASCII_STRINGPARAM,
     RTL_CONSTASCII_USTRINGPARAM macros in IO.
    
    Change-Id: I410016990579e4a05843cfe396832a5fc8435e70
    Signed-off-by: José Guilherme Vanz <guilherme.sft at gmail.com>
    Reviewed-on: https://gerrit.libreoffice.org/1210
    Reviewed-by: Olivier Hallot <olivier.hallot at alta.org.br>
    Tested-by: Olivier Hallot <olivier.hallot at alta.org.br>

diff --git a/io/source/TextInputStream/TextInputStream.cxx b/io/source/TextInputStream/TextInputStream.cxx
index 5e87cf6..a2fe774 100644
--- a/io/source/TextInputStream/TextInputStream.cxx
+++ b/io/source/TextInputStream/TextInputStream.cxx
@@ -180,7 +180,7 @@ OUString OTextInputStream::implReadString( const Sequence< sal_Unicode >& Delimi
     OUString aRetStr;
     if( !mbEncodingInitialized )
     {
-        OUString aUtf8Str( RTL_CONSTASCII_USTRINGPARAM("utf8") );
+        OUString aUtf8Str("utf8");
         setEncoding( aUtf8Str );
     }
     if( !mbEncodingInitialized )
@@ -439,13 +439,13 @@ Reference< XInterface > SAL_CALL TextInputStream_CreateInstance(
 
 OUString TextInputStream_getImplementationName()
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( IMPLEMENTATION_NAME ) );
+    return OUString ( IMPLEMENTATION_NAME );
 }
 
 Sequence< OUString > TextInputStream_getSupportedServiceNames()
 {
     Sequence< OUString > seqNames(1);
-    seqNames.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( SERVICE_NAME ) );
+    seqNames.getArray()[0] = SERVICE_NAME;
     return seqNames;
 }
 
diff --git a/io/source/TextOutputStream/TextOutputStream.cxx b/io/source/TextOutputStream/TextOutputStream.cxx
index beabc01..a9916b6 100644
--- a/io/source/TextOutputStream/TextOutputStream.cxx
+++ b/io/source/TextOutputStream/TextOutputStream.cxx
@@ -167,7 +167,7 @@ void OTextOutputStream::writeString( const OUString& aString )
 {
     if( !mbEncodingInitialized )
     {
-        OUString aUtf8Str( RTL_CONSTASCII_USTRINGPARAM("utf8") );
+        OUString aUtf8Str("utf8");
         setEncoding( aUtf8Str );
     }
     if( !mbEncodingInitialized )
@@ -236,14 +236,14 @@ Reference< XInterface > SAL_CALL TextOutputStream_CreateInstance(
 
 OUString TextOutputStream_getImplementationName() SAL_THROW(  () )
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( IMPLEMENTATION_NAME ) );
+    return OUString( IMPLEMENTATION_NAME );
 }
 
 
 Sequence< OUString > TextOutputStream_getSupportedServiceNames()
 {
     Sequence< OUString > seqNames(1);
-    seqNames.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( SERVICE_NAME ) );
+    seqNames.getArray()[0] =  SERVICE_NAME;
     return seqNames;
 }
 
diff --git a/io/source/stm/odata.cxx b/io/source/stm/odata.cxx
index 51c7d39..c928de0 100644
--- a/io/source/stm/odata.cxx
+++ b/io/source/stm/odata.cxx
@@ -496,13 +496,13 @@ Reference< XInterface > SAL_CALL ODataInputStream_CreateInstance(
 
 OUString ODataInputStream_getImplementationName()
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.stm.DataInputStream" ) );
+    return OUString("com.sun.star.comp.io.stm.DataInputStream");
 }
 
 Sequence<OUString> ODataInputStream_getSupportedServiceNames(void)
 {
     Sequence<OUString> aRet(1);
-    aRet.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.DataInputStream" ) );
+    aRet.getArray()[0] = "com.sun.star.io.DataInputStream";
     return aRet;
 }
 
@@ -904,13 +904,13 @@ Reference< XInterface > SAL_CALL ODataOutputStream_CreateInstance(
 
 OUString ODataOutputStream_getImplementationName()
 {
-    return OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.stm.DataOutputStream" ) );
+    return OUString("com.sun.star.comp.io.stm.DataOutputStream");
 }
 
 Sequence<OUString> ODataOutputStream_getSupportedServiceNames(void)
 {
     Sequence<OUString> aRet(1);
-    aRet.getArray()[0] =  OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.DataOutputStream" ) );
+    aRet.getArray()[0] =  "com.sun.star.io.DataOutputStream";
     return aRet;
 }
 
@@ -1182,13 +1182,13 @@ Reference< XInterface > SAL_CALL OObjectOutputStream_CreateInstance(
 
 OUString OObjectOutputStream_getImplementationName()
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.stm.ObjectOutputStream" ) );
+    return OUString("com.sun.star.comp.io.stm.ObjectOutputStream");
 }
 
 Sequence<OUString> OObjectOutputStream_getSupportedServiceNames(void)
 {
     Sequence<OUString> aRet(1);
-    aRet.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.ObjectOutputStream" ) );
+    aRet.getArray()[0] = "com.sun.star.io.ObjectOutputStream";
     return aRet;
 }
 
@@ -1505,13 +1505,13 @@ Reference< XInterface > SAL_CALL OObjectInputStream_CreateInstance( const Refere
 
 OUString OObjectInputStream_getImplementationName()
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.stm.ObjectInputStream" ) );
+    return OUString("com.sun.star.comp.io.stm.ObjectInputStream");
 }
 
 Sequence<OUString> OObjectInputStream_getSupportedServiceNames(void)
 {
     Sequence<OUString> aRet(1);
-    aRet.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.ObjectInputStream" ) );
+    aRet.getArray()[0] = "com.sun.star.io.ObjectInputStream";
     return aRet;
 }
 
diff --git a/io/source/stm/omark.cxx b/io/source/stm/omark.cxx
index 91ecdc0..8c1f6d3 100644
--- a/io/source/stm/omark.cxx
+++ b/io/source/stm/omark.cxx
@@ -466,13 +466,13 @@ Reference< XInterface > SAL_CALL OMarkableOutputStream_CreateInstance(
 
 OUString    OMarkableOutputStream_getImplementationName()
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.stm.MarkableOutputStream" ));
+    return OUString("com.sun.star.comp.io.stm.MarkableOutputStream");
 }
 
 Sequence<OUString> OMarkableOutputStream_getSupportedServiceNames(void)
 {
     Sequence<OUString> aRet(1);
-    aRet.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.MarkableOutputStream" ) );
+    aRet.getArray()[0] = "com.sun.star.io.MarkableOutputStream";
 
     return aRet;
 }
@@ -643,7 +643,7 @@ sal_Int32 OMarkableInputStream::readBytes(Sequence< sal_Int8 >& aData, sal_Int32
     }
     else {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM("MarkableInputStream::readBytes NotConnectedException")) ,
+            OUString("MarkableInputStream::readBytes NotConnectedException") ,
             *this );
     }
     return nBytesRead;
@@ -705,7 +705,7 @@ sal_Int32 OMarkableInputStream::readSomeBytes(Sequence< sal_Int8 >& aData, sal_I
     else
     {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM("MarkableInputStream::readSomeBytes NotConnectedException")) ,
+            OUString("MarkableInputStream::readSomeBytes NotConnectedException") ,
             *this );
     }
     return nBytesRead;
@@ -721,7 +721,7 @@ void OMarkableInputStream::skipBytes(sal_Int32 nBytesToSkip)
 {
     if ( nBytesToSkip < 0 )
         throw BufferSizeExceededException(
-            ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("precondition not met: XInputStream::skipBytes: non-negative integer required!")),
+            OUString("precondition not met: XInputStream::skipBytes: non-negative integer required!"),
             *this
         );
 
@@ -740,7 +740,7 @@ sal_Int32 OMarkableInputStream::available(void) throw (NotConnectedException, Ru
     else
     {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "MarkableInputStream::available NotConnectedException" ) ) ,
+            OUString("MarkableInputStream::available NotConnectedException") ,
             *this );
     }
 
@@ -766,7 +766,7 @@ void OMarkableInputStream::closeInput(void) throw (NotConnectedException, Runtim
     }
     else {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "MarkableInputStream::closeInput NotConnectedException" ) ) ,
+            OUString("MarkableInputStream::closeInput NotConnectedException") ,
             *this );
     }
 }
@@ -993,13 +993,13 @@ Reference < XInterface > SAL_CALL OMarkableInputStream_CreateInstance(
 
 OUString    OMarkableInputStream_getImplementationName()
 {
-    return OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.stm.MarkableInputStream" ));
+    return OUString("com.sun.star.comp.io.stm.MarkableInputStream");
 }
 
 Sequence<OUString> OMarkableInputStream_getSupportedServiceNames(void)
 {
     Sequence<OUString> aRet(1);
-    aRet.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.MarkableInputStream" ));
+    aRet.getArray()[0] = "com.sun.star.io.MarkableInputStream";
     return aRet;
 }
 
diff --git a/io/source/stm/opipe.cxx b/io/source/stm/opipe.cxx
index 9c04fe4..b6903e5 100644
--- a/io/source/stm/opipe.cxx
+++ b/io/source/stm/opipe.cxx
@@ -155,7 +155,7 @@ sal_Int32 OPipeImpl::readBytes(Sequence< sal_Int8 >& aData, sal_Int32 nBytesToRe
             if( m_bInputStreamClosed )
             {
                 throw NotConnectedException(
-                    OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::readBytes NotConnectedException" )),
+                    OUString("Pipe::readBytes NotConnectedException"),
                     *this );
             }
             sal_Int32 nOccupiedBufferLen = m_pFIFO->getSize();
@@ -194,7 +194,7 @@ sal_Int32 OPipeImpl::readSomeBytes(Sequence< sal_Int8 >& aData, sal_Int32 nMaxBy
             if( m_bInputStreamClosed )
             {
                 throw NotConnectedException(
-                    OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::readSomeBytes NotConnectedException" )),
+                    OUString("Pipe::readSomeBytes NotConnectedException"),
                     *this );
             }
             if( m_pFIFO->getSize() )
@@ -226,7 +226,7 @@ void OPipeImpl::skipBytes(sal_Int32 nBytesToSkip)
     if( m_bInputStreamClosed )
     {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::skipBytes NotConnectedException" ) ),
+            OUString("Pipe::skipBytes NotConnectedException"),
             *this );
     }
 
@@ -235,7 +235,7 @@ void OPipeImpl::skipBytes(sal_Int32 nBytesToSkip)
             > std::numeric_limits< sal_Int32 >::max() - m_nBytesToSkip) )
     {
         throw BufferSizeExceededException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::skipBytes BufferSizeExceededException" )),
+            OUString("Pipe::skipBytes BufferSizeExceededException"),
             *this );
     }
     m_nBytesToSkip += nBytesToSkip;
@@ -254,7 +254,7 @@ sal_Int32 OPipeImpl::available(void)
     if( m_bInputStreamClosed )
     {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::available NotConnectedException" ) ),
+            OUString("Pipe::available NotConnectedException"),
             *this );
     }
     return m_pFIFO->getSize();
@@ -289,14 +289,14 @@ void OPipeImpl::writeBytes(const Sequence< sal_Int8 >& aData)
     if( m_bOutputStreamClosed )
     {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::writeBytes NotConnectedException (outputstream)" )),
+            OUString("Pipe::writeBytes NotConnectedException (outputstream)"),
             *this );
     }
 
     if( m_bInputStreamClosed )
     {
         throw NotConnectedException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::writeBytes NotConnectedException (inputstream)" )),
+            OUString("Pipe::writeBytes NotConnectedException (inputstream)"),
             *this );
     }
 
@@ -327,13 +327,13 @@ void OPipeImpl::writeBytes(const Sequence< sal_Int8 >& aData)
     catch ( I_FIFO_OutOfBoundsException & )
     {
         throw BufferSizeExceededException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::writeBytes BufferSizeExceededException" )),
+            OUString("Pipe::writeBytes BufferSizeExceededException"),
             *this );
     }
     catch ( I_FIFO_OutOfMemoryException & )
     {
         throw BufferSizeExceededException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pipe::writeBytes BufferSizeExceededException" )),
+            OUString("Pipe::writeBytes BufferSizeExceededException"),
             *this );
     }
 
diff --git a/io/source/stm/opump.cxx b/io/source/stm/opump.cxx
index cc207aa..74b3869 100644
--- a/io/source/stm/opump.cxx
+++ b/io/source/stm/opump.cxx
@@ -272,7 +272,7 @@ void Pump::run()
             if( ! rInput.is() )
             {
                 NotConnectedException exception(
-                    OUString(RTL_CONSTASCII_USTRINGPARAM("no input stream set")) , Reference<XInterface>((OWeakObject*)this) );
+                    OUString("no input stream set") , Reference<XInterface>((OWeakObject*)this) );
                 throw exception;
             }
             Sequence< sal_Int8 > aData;
@@ -281,7 +281,7 @@ void Pump::run()
                 if( ! rOutput.is() )
                 {
                     NotConnectedException exception(
-                        OUString(RTL_CONSTASCII_USTRINGPARAM("no output stream set")) , Reference<XInterface>( (OWeakObject*)this) );
+                        OUString("no output stream set") , Reference<XInterface>( (OWeakObject*)this) );
                     throw exception;
                 }
                 rOutput->writeBytes( aData );
@@ -382,7 +382,7 @@ void Pump::start() throw( RuntimeException )
     else
     {
         throw RuntimeException(
-            OUString( RTL_CONSTASCII_USTRINGPARAM( "Pump::start Couldn't create worker thread" )),
+            OUString("Pump::start Couldn't create worker thread"),
             *this);
     }
 }
@@ -485,12 +485,12 @@ Reference< XInterface > SAL_CALL OPumpImpl_CreateInstance(
 
 OUString OPumpImpl_getImplementationName()
 {
-    return OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.io.Pump") );
+    return OUString("com.sun.star.comp.io.Pump");
 }
 
 Sequence<OUString> OPumpImpl_getSupportedServiceNames(void)
 {
-    OUString s( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.io.Pump" ) );
+    OUString s("com.sun.star.io.Pump");
     Sequence< OUString > seq( &s , 1 );
     return seq;
 }


More information about the Libreoffice-commits mailing list