connectivity/source/drivers/ado/APreparedStatement.cxx | 6 +++--- connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx | 6 ++---- connectivity/source/drivers/evoab2/NPreparedStatement.cxx | 2 +- connectivity/source/drivers/evoab2/NStatement.cxx | 2 +- connectivity/source/drivers/hsqldb/accesslog.hxx | 6 +++--- connectivity/source/drivers/kab/KDriver.cxx | 8 ++++---- connectivity/source/drivers/mozab/MConnection.cxx | 2 +- connectivity/source/drivers/mozab/MDatabaseMetaData.cxx | 6 ++---- connectivity/source/drivers/mozab/MResultSet.cxx | 8 ++++---- connectivity/source/drivers/mozab/mozillasrc/MDatabaseMetaDataHelper.cxx | 2 +- connectivity/source/drivers/mozab/mozillasrc/MNameMapper.cxx | 2 +- 11 files changed, 23 insertions(+), 27 deletions(-)
New commits: commit 1ece204b543e2c1bd65d02ceba43b3ed7028feae Author: LuboÅ¡ LuÅák <l.lu...@suse.cz> Date: Wed Aug 21 16:08:26 2013 +0200 valueOf is deprecated Change-Id: I8966ecd4e94c7b11af4d59b5b4461ce03a888891 diff --git a/connectivity/source/drivers/ado/APreparedStatement.cxx b/connectivity/source/drivers/ado/APreparedStatement.cxx index 062964f..14c44de 100644 --- a/connectivity/source/drivers/ado/APreparedStatement.cxx +++ b/connectivity/source/drivers/ado/APreparedStatement.cxx @@ -217,7 +217,7 @@ void OPreparedStatement::setParameter(sal_Int32 parameterIndex, const DataTypeEn if(nCount < (parameterIndex-1)) { OUString sDefaultName( "parame" ); - sDefaultName += OUString::valueOf(parameterIndex); + sDefaultName += OUString::number(parameterIndex); ADOParameter* pParam = m_Command.CreateParameter(sDefaultName,_eType,adParamInput,_nSize,_Val); if(pParam) { @@ -433,7 +433,7 @@ void SAL_CALL OPreparedStatement::setObject( sal_Int32 parameterIndex, const Any { const OUString sError( m_pConnection->getResources().getResourceStringWithSubstitution( STR_UNKNOWN_PARA_TYPE, - "$position$", OUString::valueOf(parameterIndex) + "$position$", OUString::number(parameterIndex) ) ); ::dbtools::throwGenericSQLException(sError,*this); } @@ -542,7 +542,7 @@ void OPreparedStatement::replaceParameterNodeName(OSQLParseNode* _pNode, OSQLParseNode* pNewNode = new OSQLParseNode(OUString(":") ,SQL_NODE_PUNCTUATION,0); delete pChildNode->replace(pChildNode->getChild(0),pNewNode); OUString sParameterName = _sDefaultName; - sParameterName += OUString::valueOf(++_rParameterCount); + sParameterName += OUString::number(++_rParameterCount); pChildNode->append(new OSQLParseNode( sParameterName,SQL_NODE_NAME,0)); } else diff --git a/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx b/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx index 59369b2..adb1783 100644 --- a/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx +++ b/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx @@ -814,14 +814,12 @@ OUString SAL_CALL OEvoabDatabaseMetaData::getDriverName( ) throw(SQLException, // ------------------------------------------------------------------------- OUString SAL_CALL OEvoabDatabaseMetaData::getDriverVersion() throw(SQLException, RuntimeException) { - OUString aValue = OUString::valueOf((sal_Int32)1); - return aValue; + return OUString( "1" ); } // ------------------------------------------------------------------------- OUString SAL_CALL OEvoabDatabaseMetaData::getDatabaseProductVersion( ) throw(SQLException, RuntimeException) { - OUString aValue = OUString::valueOf((sal_Int32)0); - return aValue; + return OUString( "0" ); } // ------------------------------------------------------------------------- OUString SAL_CALL OEvoabDatabaseMetaData::getDatabaseProductName( ) throw(SQLException, RuntimeException) diff --git a/connectivity/source/drivers/evoab2/NPreparedStatement.cxx b/connectivity/source/drivers/evoab2/NPreparedStatement.cxx index e067c8d..6118a16 100644 --- a/connectivity/source/drivers/evoab2/NPreparedStatement.cxx +++ b/connectivity/source/drivers/evoab2/NPreparedStatement.cxx @@ -272,7 +272,7 @@ void SAL_CALL OEvoabPreparedStatement::setObject( sal_Int32 parameterIndex, cons { const OUString sError( getOwnConnection()->getResources().getResourceStringWithSubstitution( STR_UNKNOWN_PARA_TYPE, - "$position$", OUString::valueOf(parameterIndex) + "$position$", OUString::number(parameterIndex) ) ); ::dbtools::throwGenericSQLException(sError,*this); } diff --git a/connectivity/source/drivers/evoab2/NStatement.cxx b/connectivity/source/drivers/evoab2/NStatement.cxx index e490ebb..3d89b92 100644 --- a/connectivity/source/drivers/evoab2/NStatement.cxx +++ b/connectivity/source/drivers/evoab2/NStatement.cxx @@ -367,7 +367,7 @@ EBookQuery *OCommonStatement::whereAnalysis( const OSQLParseNode* parseTree ) aMatchString = pAtom->getTokenValue(); // Determine where '%' character is... - if( aMatchString.equals( OUString::valueOf( WILDCARD ) ) ) + if( aMatchString.equals( OUString( WILDCARD ) ) ) { // String containing only a '%' and nothing else matches everything pResult = createTest( aColumnName, E_BOOK_QUERY_CONTAINS, diff --git a/connectivity/source/drivers/hsqldb/accesslog.hxx b/connectivity/source/drivers/hsqldb/accesslog.hxx index 8175ac5..b00d618 100644 --- a/connectivity/source/drivers/hsqldb/accesslog.hxx +++ b/connectivity/source/drivers/hsqldb/accesslog.hxx @@ -63,7 +63,7 @@ namespace connectivity { namespace hsqldb { OString sLine( _pOp ); sLine += "( "; - sLine += OString::valueOf( _nLongArg ); + sLine += OString::number( _nLongArg ); sLine += " )"; writeString( sLine.getStr(), true ); } @@ -71,14 +71,14 @@ namespace connectivity { namespace hsqldb void logReturn( jlong _nRetVal ) { OString sLine( " -> " ); - sLine += OString::valueOf( _nRetVal ); + sLine += OString::number( _nRetVal ); writeString( sLine.getStr(), true ); } void logReturn( jint _nRetVal ) { OString sLine( " -> " ); - sLine += OString::valueOf( _nRetVal ); + sLine += OString::number( _nRetVal ); writeString( sLine.getStr(), true ); } diff --git a/connectivity/source/drivers/kab/KDriver.cxx b/connectivity/source/drivers/kab/KDriver.cxx index 12faa6a..0eedfea 100644 --- a/connectivity/source/drivers/kab/KDriver.cxx +++ b/connectivity/source/drivers/kab/KDriver.cxx @@ -221,8 +221,8 @@ void KabImplModule::impl_throwKdeTooOldException() ::connectivity::SharedResources aResources; const OUString sError( aResources.getResourceStringWithSubstitution( STR_KDE_VERSION_TOO_OLD, - "$major$",OUString::valueOf((sal_Int32)MIN_KDE_VERSION_MAJOR), - "$minor$",OUString::valueOf((sal_Int32)MIN_KDE_VERSION_MINOR) + "$major$",OUString::number(MIN_KDE_VERSION_MAJOR), + "$minor$",OUString::number(MIN_KDE_VERSION_MINOR) ) ); impl_throwGenericSQLException( sError ); } @@ -245,8 +245,8 @@ void KabImplModule::impl_throwKdeTooNewException() SQLException aError; aError.Message = aResources.getResourceStringWithSubstitution( STR_KDE_VERSION_TOO_NEW, - "$major$",OUString::valueOf((sal_Int32)MIN_KDE_VERSION_MAJOR), - "$minor$",OUString::valueOf((sal_Int32)MIN_KDE_VERSION_MINOR) + "$major$",OUString::number(MIN_KDE_VERSION_MAJOR), + "$minor$",OUString::number(MIN_KDE_VERSION_MINOR) ); aError.SQLState = OUString( "S1000" ); aError.ErrorCode = 0; diff --git a/connectivity/source/drivers/mozab/MConnection.cxx b/connectivity/source/drivers/mozab/MConnection.cxx index 4345f5c..8112a53 100644 --- a/connectivity/source/drivers/mozab/MConnection.cxx +++ b/connectivity/source/drivers/mozab/MConnection.cxx @@ -281,7 +281,7 @@ void OConnection::construct(const OUString& url,const Sequence< PropertyValue >& if ( nPortNumber > 0 ) { m_sMozillaURI += OUString( ":" ); - m_sMozillaURI += OUString::valueOf( nPortNumber ); + m_sMozillaURI += OUString::number( nPortNumber ); } if ( !sBaseDN.isEmpty() ) { diff --git a/connectivity/source/drivers/mozab/MDatabaseMetaData.cxx b/connectivity/source/drivers/mozab/MDatabaseMetaData.cxx index c9241a6..d7b6f4f 100644 --- a/connectivity/source/drivers/mozab/MDatabaseMetaData.cxx +++ b/connectivity/source/drivers/mozab/MDatabaseMetaData.cxx @@ -659,14 +659,12 @@ OUString SAL_CALL ODatabaseMetaData::getDriverName( ) throw(SQLException, Runti // ------------------------------------------------------------------------- OUString SAL_CALL ODatabaseMetaData::getDriverVersion() throw(SQLException, RuntimeException) { - OUString aValue = OUString::valueOf((sal_Int32)1); - return aValue; + return OUString( "1" ); } // ------------------------------------------------------------------------- OUString SAL_CALL ODatabaseMetaData::getDatabaseProductVersion( ) throw(SQLException, RuntimeException) { - OUString aValue = OUString::valueOf((sal_Int32)0); - return aValue; + return OUString( "0" ); } // ------------------------------------------------------------------------- OUString SAL_CALL ODatabaseMetaData::getDatabaseProductName( ) throw(SQLException, RuntimeException) diff --git a/connectivity/source/drivers/mozab/MResultSet.cxx b/connectivity/source/drivers/mozab/MResultSet.cxx index 2ae60ae..a26891b 100644 --- a/connectivity/source/drivers/mozab/MResultSet.cxx +++ b/connectivity/source/drivers/mozab/MResultSet.cxx @@ -919,7 +919,7 @@ void OResultSet::analyseWhereClause( const OSQLParseNode* parseT // Determine where '%' character is... - if ( matchString.equals( OUString::valueOf( WILDCARD ) ) ) + if ( matchString.equals( OUString( WILDCARD ) ) ) { // String containing only a '%' and nothing else op = MQueryOp::Exists; @@ -1652,7 +1652,7 @@ void OResultSet::checkPendingUpdate() throw(SQLException, RuntimeException) { const OUString sError( m_pStatement->getOwnConnection()->getResources().getResourceStringWithSubstitution( STR_COMMIT_ROW, - "$position$", OUString::valueOf(nCurrentRow) + "$position$", OUString::number(nCurrentRow) ) ); ::dbtools::throwGenericSQLException(sError,*this); } @@ -1784,7 +1784,7 @@ void SAL_CALL OResultSet::updateObject( sal_Int32 columnIndex, const Any& x ) th { const OUString sError( m_pStatement->getOwnConnection()->getResources().getResourceStringWithSubstitution( STR_COLUMN_NOT_UPDATEABLE, - "$position$", OUString::valueOf(columnIndex) + "$position$", OUString::number(columnIndex) ) ); ::dbtools::throwGenericSQLException(sError,*this); } // if (!::dbtools::implUpdateObject(this, columnIndex, x)) @@ -1797,7 +1797,7 @@ void SAL_CALL OResultSet::updateNumericObject( sal_Int32 columnIndex, const Any& { const OUString sError( m_pStatement->getOwnConnection()->getResources().getResourceStringWithSubstitution( STR_COLUMN_NOT_UPDATEABLE, - "$position$", OUString::valueOf(columnIndex) + "$position$", OUString::number(columnIndex) ) ); ::dbtools::throwGenericSQLException(sError,*this); } diff --git a/connectivity/source/drivers/mozab/mozillasrc/MDatabaseMetaDataHelper.cxx b/connectivity/source/drivers/mozab/mozillasrc/MDatabaseMetaDataHelper.cxx index 087d541..dc77784 100644 --- a/connectivity/source/drivers/mozab/mozillasrc/MDatabaseMetaDataHelper.cxx +++ b/connectivity/source/drivers/mozab/mozillasrc/MDatabaseMetaDataHelper.cxx @@ -759,7 +759,7 @@ sal_Bool MDatabaseMetaDataHelper::NewAddressBook(OConnection* _pCon,const OUStri } else if (NS_FAILED(rv)) { - m_aError.set( STR_COULD_NOT_CREATE_ADDRESSBOOK, 0, OUString::valueOf( sal_Int32(rv), 16 ) ); + m_aError.set( STR_COULD_NOT_CREATE_ADDRESSBOOK, 0, OUString::number( sal_Int32(rv), 16 ) ); } OSL_TRACE( "OUT MDatabaseMetaDataHelper::NewAddressBook()" ); return( NS_SUCCEEDED(rv) ? sal_True : sal_False ); diff --git a/connectivity/source/drivers/mozab/mozillasrc/MNameMapper.cxx b/connectivity/source/drivers/mozab/mozillasrc/MNameMapper.cxx index f10b41f..d13e735 100644 --- a/connectivity/source/drivers/mozab/mozillasrc/MNameMapper.cxx +++ b/connectivity/source/drivers/mozab/mozillasrc/MNameMapper.cxx @@ -98,7 +98,7 @@ MNameMapper::add( OUString& str, nsIAbDirectory* abook ) long count =1; while ( mDirMap->find( tempStr ) != mDirMap->end() ) { - tempStr = str + OUString::valueOf(count); + tempStr = str + OUString::number(count); count ++; } str = tempStr;
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits