diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2010-10-15 12:10:06 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2010-10-25 19:55:33 -0500 |
commit | d3756b8b7318ecae4eaf0552aea3cde940e91490 (patch) | |
tree | 266d82b888950bf415cf6aeddce2c1bdb7329591 /connectivity/source | |
parent | 7d22ff57241f19213453ecd0c98d67fb579a3803 (diff) |
merge vosremoval-reference.diff
Diffstat (limited to 'connectivity/source')
75 files changed, 195 insertions, 188 deletions
diff --git a/connectivity/source/commontools/FDatabaseMetaDataResultSet.cxx b/connectivity/source/commontools/FDatabaseMetaDataResultSet.cxx index ff9e735a1a3f..9afa80803867 100644 --- a/connectivity/source/commontools/FDatabaseMetaDataResultSet.cxx +++ b/connectivity/source/commontools/FDatabaseMetaDataResultSet.cxx @@ -463,7 +463,7 @@ sal_Bool SAL_CALL ODatabaseMetaDataResultSet::wasNull( ) throw(SQLException, Ru checkDisposed(ODatabaseMetaDataResultSet_BASE::rBHelper.bDisposed ); - if(m_aRowsIter == m_aRows.end() || !(*m_aRowsIter)[m_nColPos].isValid()) + if(m_aRowsIter == m_aRows.end() || !(*m_aRowsIter)[m_nColPos].is()) return sal_True; return (*m_aRowsIter)[m_nColPos]->getValue().isNull(); @@ -642,7 +642,7 @@ const ORowSetValue& ODatabaseMetaDataResultSet::getValue(sal_Int32 columnIndex) checkIndex(columnIndex ); m_nColPos = columnIndex; - if(m_aRowsIter != m_aRows.end() && (*m_aRowsIter)[columnIndex].isValid()) + if(m_aRowsIter != m_aRows.end() && (*m_aRowsIter)[columnIndex].is()) return *(*m_aRowsIter)[columnIndex]; return m_aEmptyValue; } diff --git a/connectivity/source/commontools/TSortIndex.cxx b/connectivity/source/commontools/TSortIndex.cxx index 348cf7719f1b..6f9022dd0b8a 100644 --- a/connectivity/source/commontools/TSortIndex.cxx +++ b/connectivity/source/commontools/TSortIndex.cxx @@ -86,11 +86,11 @@ struct TKeyValueFunc : ::std::binary_function<OSortIndex::TIntValuePairVector::v }; // ----------------------------------------------------------------------------- -::vos::ORef<OKeySet> OSortIndex::CreateKeySet() +::rtl::Reference<OKeySet> OSortIndex::CreateKeySet() { Freeze(); - ::vos::ORef<OKeySet> pKeySet = new OKeySet(); + ::rtl::Reference<OKeySet> pKeySet = new OKeySet(); pKeySet->get().reserve(m_aKeyValues.size()); ::std::transform(m_aKeyValues.begin() ,m_aKeyValues.end() diff --git a/connectivity/source/cpool/ZConnectionPool.hxx b/connectivity/source/cpool/ZConnectionPool.hxx index 02f46d68ed17..c184cebc5560 100644 --- a/connectivity/source/cpool/ZConnectionPool.hxx +++ b/connectivity/source/cpool/ZConnectionPool.hxx @@ -38,7 +38,7 @@ #include <comphelper/stl_types.hxx> #include <osl/mutex.hxx> #include <salhelper/timer.hxx> -#include <vos/ref.hxx> +#include <rtl/ref.hxx> #include <rtl/digest.h> namespace connectivity @@ -116,7 +116,7 @@ namespace connectivity TActiveConnectionMap m_aActiveConnections; // the currently active connections ::osl::Mutex m_aMutex; - ::vos::ORef<OPoolTimer> m_xInvalidator; // invalidates the conntection pool when shot + ::rtl::Reference<OPoolTimer> m_xInvalidator; // invalidates the conntection pool when shot ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDriver > m_xDriver; // the one and only driver for this connectionpool ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > m_xDriverNode; // config node entry diff --git a/connectivity/source/dbtools/makefile.mk b/connectivity/source/dbtools/makefile.mk index af4ac13e54cc..aab8fc545457 100644 --- a/connectivity/source/dbtools/makefile.mk +++ b/connectivity/source/dbtools/makefile.mk @@ -59,6 +59,7 @@ SHL1STDLIBS=\ $(CPPUHELPERLIB) \ $(VOSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(JVMACCESSLIB) \ $(UNOTOOLSLIB) \ $(TOOLSLIB) \ diff --git a/connectivity/source/drivers/adabas/BConnection.cxx b/connectivity/source/drivers/adabas/BConnection.cxx index ee59dcdaa33a..a594083f6e75 100644 --- a/connectivity/source/drivers/adabas/BConnection.cxx +++ b/connectivity/source/drivers/adabas/BConnection.cxx @@ -251,9 +251,9 @@ Sequence< sal_Int8 > OAdabasConnection::getUnoTunnelImplementationId() return new OAdabasConnection(m_pDriverHandleCopy,m_pDriver); } // ----------------------------------------------------------------------------- -::vos::ORef<OSQLColumns> OAdabasConnection::createSelectColumns(const ::rtl::OUString& _rSql) +::rtl::Reference<OSQLColumns> OAdabasConnection::createSelectColumns(const ::rtl::OUString& _rSql) { - ::vos::ORef<OSQLColumns> aRet; + ::rtl::Reference<OSQLColumns> aRet; OSQLParser aParser(getDriver()->getORB()); ::rtl::OUString sErrorMessage; OSQLParseNode* pNode = aParser.parseTree(sErrorMessage,_rSql); diff --git a/connectivity/source/drivers/adabas/BResultSetMetaData.cxx b/connectivity/source/drivers/adabas/BResultSetMetaData.cxx index b245f61fa0b8..18605f519549 100644 --- a/connectivity/source/drivers/adabas/BResultSetMetaData.cxx +++ b/connectivity/source/drivers/adabas/BResultSetMetaData.cxx @@ -39,7 +39,7 @@ using namespace com::sun::star::uno; using namespace connectivity::adabas; using namespace connectivity; -OAdabasResultSetMetaData::OAdabasResultSetMetaData(odbc::OConnection* _pConnection, SQLHANDLE _pStmt,const ::vos::ORef<OSQLColumns>& _rSelectColumns ) +OAdabasResultSetMetaData::OAdabasResultSetMetaData(odbc::OConnection* _pConnection, SQLHANDLE _pStmt,const ::rtl::Reference<OSQLColumns>& _rSelectColumns ) : OAdabasResultSetMetaData_BASE(_pConnection,_pStmt) ,m_aSelectColumns(_rSelectColumns) { @@ -63,7 +63,7 @@ sal_Int32 SAL_CALL OAdabasResultSetMetaData::isNullable( sal_Int32 column ) thro { sal_Int32 nValue = 0; sal_Bool bFound = sal_False; - if ( m_aSelectColumns.isValid() && column > 0 && column <= (sal_Int32)m_aSelectColumns->get().size() ) + if ( m_aSelectColumns.is() && column > 0 && column <= (sal_Int32)m_aSelectColumns->get().size() ) bFound = (m_aSelectColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_ISNULLABLE)) >>= nValue; if ( !bFound ) @@ -73,7 +73,7 @@ sal_Int32 SAL_CALL OAdabasResultSetMetaData::isNullable( sal_Int32 column ) thro // ------------------------------------------------------------------------- sal_Bool SAL_CALL OAdabasResultSetMetaData::isAutoIncrement( sal_Int32 column ) throw(SQLException, RuntimeException) { - if ( m_aSelectColumns.isValid() && column > 0 && column <= (sal_Int32)m_aSelectColumns->get().size() ) + if ( m_aSelectColumns.is() && column > 0 && column <= (sal_Int32)m_aSelectColumns->get().size() ) { sal_Bool bAutoIncrement = sal_False; (m_aSelectColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_ISAUTOINCREMENT)) >>= bAutoIncrement; diff --git a/connectivity/source/drivers/adabas/makefile.mk b/connectivity/source/drivers/adabas/makefile.mk index 9268f02a3b42..c4154cbea3e9 100644 --- a/connectivity/source/drivers/adabas/makefile.mk +++ b/connectivity/source/drivers/adabas/makefile.mk @@ -82,6 +82,7 @@ SHL1STDLIBS=\ $(CPPUHELPERLIB) \ $(VOSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(TOOLSLIB) \ $(ODBCBASELIB) \ diff --git a/connectivity/source/drivers/calc/CColumns.cxx b/connectivity/source/drivers/calc/CColumns.cxx index 553771b3a64b..019361e3d12f 100644 --- a/connectivity/source/drivers/calc/CColumns.cxx +++ b/connectivity/source/drivers/calc/CColumns.cxx @@ -44,7 +44,7 @@ using namespace ::com::sun::star::container; sdbcx::ObjectType OCalcColumns::createObject(const ::rtl::OUString& _rName) { OCalcTable* pTable = (OCalcTable*)m_pTable; - ::vos::ORef<OSQLColumns> aCols = pTable->getTableColumns(); + ::rtl::Reference<OSQLColumns> aCols = pTable->getTableColumns(); OSQLColumns::Vector::const_iterator aIter = find(aCols->get().begin(),aCols->get().end(),_rName,::comphelper::UStringMixEqual(isCaseSensitive())); sdbcx::ObjectType xRet; diff --git a/connectivity/source/drivers/calc/makefile.mk b/connectivity/source/drivers/calc/makefile.mk index 8e193524aa45..04ea9e364ebf 100644 --- a/connectivity/source/drivers/calc/makefile.mk +++ b/connectivity/source/drivers/calc/makefile.mk @@ -71,6 +71,7 @@ SHL1STDLIBS=\ $(TOOLSLIB) \ $(UNOTOOLSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(DBFILELIB) \ $(COMPHELPERLIB) diff --git a/connectivity/source/drivers/dbase/DColumns.cxx b/connectivity/source/drivers/dbase/DColumns.cxx index 8474c8cbe282..c3221c69b04c 100644 --- a/connectivity/source/drivers/dbase/DColumns.cxx +++ b/connectivity/source/drivers/dbase/DColumns.cxx @@ -49,7 +49,7 @@ sdbcx::ObjectType ODbaseColumns::createObject(const ::rtl::OUString& _rName) ODbaseTable* pTable = (ODbaseTable*)m_pTable; - ::vos::ORef<OSQLColumns> aCols = pTable->getTableColumns(); + ::rtl::Reference<OSQLColumns> aCols = pTable->getTableColumns(); OSQLColumns::Vector::const_iterator aIter = find(aCols->get().begin(),aCols->get().end(),_rName,::comphelper::UStringMixEqual(isCaseSensitive())); sdbcx::ObjectType xRet; diff --git a/connectivity/source/drivers/dbase/DIndex.cxx b/connectivity/source/drivers/dbase/DIndex.cxx index 6fdd01c34f9c..1b205f08ef70 100644 --- a/connectivity/source/drivers/dbase/DIndex.cxx +++ b/connectivity/source/drivers/dbase/DIndex.cxx @@ -551,7 +551,7 @@ BOOL ODbaseIndex::CreateImpl() // Setzen der Headerinfo memset(&m_aHeader,0,sizeof(m_aHeader)); sal_Int32 nType = 0; - ::vos::ORef<OSQLColumns> aCols = m_pTable->getTableColumns(); + ::rtl::Reference<OSQLColumns> aCols = m_pTable->getTableColumns(); const Reference< XPropertySet > xTableCol(*find(aCols->get().begin(),aCols->get().end(),aName,::comphelper::UStringMixEqual(isCaseSensitive()))); xTableCol->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_TYPE)) >>= nType; diff --git a/connectivity/source/drivers/dbase/DIndexColumns.cxx b/connectivity/source/drivers/dbase/DIndexColumns.cxx index 6b68ccaa7747..3b9d1302e86b 100644 --- a/connectivity/source/drivers/dbase/DIndexColumns.cxx +++ b/connectivity/source/drivers/dbase/DIndexColumns.cxx @@ -50,7 +50,7 @@ sdbcx::ObjectType ODbaseIndexColumns::createObject(const ::rtl::OUString& _rName { const ODbaseTable* pTable = m_pIndex->getTable(); - ::vos::ORef<OSQLColumns> aCols = pTable->getTableColumns(); + ::rtl::Reference<OSQLColumns> aCols = pTable->getTableColumns(); OSQLColumns::Vector::const_iterator aIter = find(aCols->get().begin(),aCols->get().end(),_rName,::comphelper::UStringMixEqual(isCaseSensitive())); Reference< XPropertySet > xCol; diff --git a/connectivity/source/drivers/dbase/DTable.cxx b/connectivity/source/drivers/dbase/DTable.cxx index 787e14e2be9d..8b5a375a28dc 100644 --- a/connectivity/source/drivers/dbase/DTable.cxx +++ b/connectivity/source/drivers/dbase/DTable.cxx @@ -297,7 +297,7 @@ void ODbaseTable::fillColumns() m_pFileStream->Seek(STREAM_SEEK_TO_BEGIN); m_pFileStream->Seek(32L); - if(!m_aColumns.isValid()) + if(!m_aColumns.is()) m_aColumns = new OSQLColumns(); else m_aColumns->get().clear(); @@ -1729,7 +1729,7 @@ BOOL ODbaseTable::UpdateBuffer(OValueRefVector& rRow, OValueRefRow pOrgRow,const if (xIndex.is()) { // first check if the value is different to the old one and when if it conform to the index - if(pOrgRow.isValid() && (rRow.get()[nPos]->getValue().isNull() || rRow.get()[nPos] == (pOrgRow->get())[nPos])) + if(pOrgRow.is() && (rRow.get()[nPos]->getValue().isNull() || rRow.get()[nPos] == (pOrgRow->get())[nPos])) continue; else { @@ -1842,7 +1842,7 @@ BOOL ODbaseTable::UpdateBuffer(OValueRefVector& rRow, OValueRefRow pOrgRow,const ODbaseIndex* pIndex = reinterpret_cast< ODbaseIndex* >( xTunnel->getSomething(ODbaseIndex::getUnoTunnelImplementationId()) ); OSL_ENSURE(pIndex,"ODbaseTable::UpdateBuffer: No Index returned!"); // Update !! - if (pOrgRow.isValid() && !rRow.get()[nPos]->getValue().isNull() ) + if (pOrgRow.is() && !rRow.get()[nPos]->getValue().isNull() ) pIndex->Update(m_nFilePos,*(pOrgRow->get())[nPos],*rRow.get()[nPos]); else pIndex->Insert(m_nFilePos,*rRow.get()[nPos]); @@ -2549,7 +2549,7 @@ void ODbaseTable::copyData(ODbaseTable* _pNewTable,sal_Int32 _nPos) bOk = seekRow( IResultSetHelper::BOOKMARK, nRowPos+1, nCurPos ); if ( bOk ) { - bOk = fetchRow( aRow, m_aColumns.getBody(), sal_True, sal_True); + bOk = fetchRow( aRow, *m_aColumns, sal_True, sal_True); if ( bOk && !aRow->isDeleted() ) // copy only not deleted rows { // special handling when pos == 0 then we don't have to distinguish between the two rows diff --git a/connectivity/source/drivers/dbase/makefile.mk b/connectivity/source/drivers/dbase/makefile.mk index f855cf1f4554..3d77af5d66b7 100644 --- a/connectivity/source/drivers/dbase/makefile.mk +++ b/connectivity/source/drivers/dbase/makefile.mk @@ -103,6 +103,7 @@ SHL1STDLIBS=\ $(TOOLSLIB) \ $(UCBHELPERLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(DBFILELIB) \ $(UNOTOOLSLIB) \ diff --git a/connectivity/source/drivers/evoab/LColumns.cxx b/connectivity/source/drivers/evoab/LColumns.cxx index e6d5e482510a..5d69f28290b9 100644 --- a/connectivity/source/drivers/evoab/LColumns.cxx +++ b/connectivity/source/drivers/evoab/LColumns.cxx @@ -46,7 +46,7 @@ sdbcx::ObjectType OEvoabColumns::createObject(const ::rtl::OUString& _rName) { OEvoabTable* pTable = (OEvoabTable*)m_pTable; - ::vos::ORef<OSQLColumns> aCols = pTable->getTableColumns(); + ::rtl::Reference<OSQLColumns> aCols = pTable->getTableColumns(); OSQLColumns::Vector::const_iterator aIter = find(aCols->get().begin(),aCols->get().end(),_rName,::comphelper::UStringMixEqual(isCaseSensitive())); sdbcx::ObjectType xRet; if(aIter != aCols->get().end()) diff --git a/connectivity/source/drivers/evoab/LConnection.cxx b/connectivity/source/drivers/evoab/LConnection.cxx index c15c61449b32..d6bbed5b4f87 100644 --- a/connectivity/source/drivers/evoab/LConnection.cxx +++ b/connectivity/source/drivers/evoab/LConnection.cxx @@ -49,7 +49,6 @@ using namespace connectivity::evoab; using namespace connectivity::file; -using namespace vos; typedef connectivity::file::OConnection OConnection_B; diff --git a/connectivity/source/drivers/evoab/LDatabaseMetaData.cxx b/connectivity/source/drivers/evoab/LDatabaseMetaData.cxx index 5b26e707a1a1..85d0aba00b30 100644 --- a/connectivity/source/drivers/evoab/LDatabaseMetaData.cxx +++ b/connectivity/source/drivers/evoab/LDatabaseMetaData.cxx @@ -65,7 +65,6 @@ using namespace ::com::sun::star::sdbc; using namespace ::com::sun::star::container; using namespace ::com::sun::star::ucb; using namespace osl; -using namespace vos; namespace connectivity { diff --git a/connectivity/source/drivers/evoab/LFolderList.cxx b/connectivity/source/drivers/evoab/LFolderList.cxx index 70a8844286fe..b5757ca1ac37 100644 --- a/connectivity/source/drivers/evoab/LFolderList.cxx +++ b/connectivity/source/drivers/evoab/LFolderList.cxx @@ -92,7 +92,7 @@ void OEvoabFolderList::fillColumns(const ::com::sun::star::lang::Locale& _aLocal // column count xub_StrLen nFieldCount = aHeaderLine.GetTokenCount(pConnection->getFieldDelimiter(),pConnection->getStringDelimiter()); - if(!m_aColumns.isValid()) + if(!m_aColumns.is()) m_aColumns = new OSQLColumns(); else m_aColumns->get().clear(); @@ -524,7 +524,7 @@ sal_Int32 SAL_CALL OEvoabFolderList::getInt( sal_Int32 _nColumnIndex ) throw(SQL // ----------------------------------------------------------------------------- void OEvoabFolderList::initializeRow(sal_Int32 _nColumnCount) { - if(!m_aRow.isValid()) + if(!m_aRow.is()) { m_aRow = new OValueVector(_nColumnCount); (m_aRow->get())[0].setBound(sal_True); @@ -555,7 +555,7 @@ sal_Bool SAL_CALL OEvoabFolderList::next( ) throw(SQLException, RuntimeExceptio sal_Int32 SAL_CALL OEvoabFolderList::getRow( ) throw(SQLException, RuntimeException) { - sal_Bool bRet = fetchRow(m_aRow,getTableColumns().getBody()); + sal_Bool bRet = fetchRow(m_aRow,*(getTableColumns())); EVO_TRACE_STRING("OEvoabFolderList::getRow()::fetchRow() = %s\n", ::rtl::OUString::valueOf(bRet) ); return bRet; diff --git a/connectivity/source/drivers/evoab/LFolderList.hxx b/connectivity/source/drivers/evoab/LFolderList.hxx index 2941cb6bd20f..5978eec1c34b 100644 --- a/connectivity/source/drivers/evoab/LFolderList.hxx +++ b/connectivity/source/drivers/evoab/LFolderList.hxx @@ -57,7 +57,7 @@ namespace connectivity sal_Int32 m_nFilePos; // aktuelle IResultSetHelper::Movement SvStream* m_pFileStream; OEvoabConnection* m_pConnection; - ::vos::ORef<OSQLColumns> m_aColumns; + ::rtl::Reference<OSQLColumns> m_aColumns; OValueRow m_aRow; sal_Bool m_bIsNull; @@ -73,7 +73,7 @@ namespace connectivity OEvoabFolderList( OEvoabConnection* _pConnection); OEvoabConnection* getConnection() const { return m_pConnection;} - ::vos::ORef<OSQLColumns> getTableColumns() const {return m_aColumns;} + ::rtl::Reference<OSQLColumns> getTableColumns() const {return m_aColumns;} void construct(); // can throw any exception static SvStream* createStream_simpleError( const String& _rFileName, StreamMode _eOpenMode); void initializeRow(sal_Int32 _nColumnCount); diff --git a/connectivity/source/drivers/evoab/LTable.cxx b/connectivity/source/drivers/evoab/LTable.cxx index b8d760bb1473..898f445e1d3b 100644 --- a/connectivity/source/drivers/evoab/LTable.cxx +++ b/connectivity/source/drivers/evoab/LTable.cxx @@ -100,7 +100,7 @@ void OEvoabTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) // column count xub_StrLen nFieldCount = aHeaderLine.GetTokenCount(pConnection->getFieldDelimiter(),pConnection->getStringDelimiter()); - if(!m_aColumns.isValid()) + if(!m_aColumns.is()) m_aColumns = new OSQLColumns(); else m_aColumns->get().clear(); diff --git a/connectivity/source/drivers/evoab/makefile.mk b/connectivity/source/drivers/evoab/makefile.mk index c1dbc21cdf1e..81f34fc6cb24 100644 --- a/connectivity/source/drivers/evoab/makefile.mk +++ b/connectivity/source/drivers/evoab/makefile.mk @@ -81,6 +81,7 @@ SHL1STDLIBS=\ $(UNOTOOLSLIB) \ $(UCBHELPERLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(DBFILELIB) \ $(COMPHELPERLIB) diff --git a/connectivity/source/drivers/evoab2/NConnection.cxx b/connectivity/source/drivers/evoab2/NConnection.cxx index 5766a9e05542..08989dfd59c5 100644 --- a/connectivity/source/drivers/evoab2/NConnection.cxx +++ b/connectivity/source/drivers/evoab2/NConnection.cxx @@ -45,7 +45,6 @@ #include <comphelper/sequence.hxx> using namespace connectivity::evoab; -using namespace vos; using namespace dbtools; //------------------------------------------------------------------------------ diff --git a/connectivity/source/drivers/evoab2/NPreparedStatement.cxx b/connectivity/source/drivers/evoab2/NPreparedStatement.cxx index 1cd95230e079..3f1ef4b572b6 100644 --- a/connectivity/source/drivers/evoab2/NPreparedStatement.cxx +++ b/connectivity/source/drivers/evoab2/NPreparedStatement.cxx @@ -68,7 +68,7 @@ void OEvoabPreparedStatement::construct( const ::rtl::OUString& _sql ) m_aQueryData = impl_getEBookQuery_throw( m_sSqlStatement ); ENSURE_OR_THROW( m_aQueryData.getQuery(), "no EBookQuery" ); - ENSURE_OR_THROW( m_aQueryData.xSelectColumns.isValid(), "no SelectColumn" ); + ENSURE_OR_THROW( m_aQueryData.xSelectColumns.is(), "no SelectColumn" ); // create our meta data OEvoabResultSetMetaData* pMeta = new OEvoabResultSetMetaData( m_aQueryData.sTable ); diff --git a/connectivity/source/drivers/evoab2/NResultSetMetaData.cxx b/connectivity/source/drivers/evoab2/NResultSetMetaData.cxx index a11809abef2a..2265fa0f72cd 100644 --- a/connectivity/source/drivers/evoab2/NResultSetMetaData.cxx +++ b/connectivity/source/drivers/evoab2/NResultSetMetaData.cxx @@ -51,7 +51,7 @@ OEvoabResultSetMetaData::~OEvoabResultSetMetaData() { } // ------------------------------------------------------------------------- -void OEvoabResultSetMetaData::setEvoabFields(const ::vos::ORef<connectivity::OSQLColumns> &xColumns) throw(SQLException) +void OEvoabResultSetMetaData::setEvoabFields(const ::rtl::Reference<connectivity::OSQLColumns> &xColumns) throw(SQLException) { OSQLColumns::Vector::const_iterator aIter; static const ::rtl::OUString aName(::rtl::OUString::createFromAscii("Name")); diff --git a/connectivity/source/drivers/evoab2/NResultSetMetaData.hxx b/connectivity/source/drivers/evoab2/NResultSetMetaData.hxx index 95653c1ebeea..03ca91842554 100644 --- a/connectivity/source/drivers/evoab2/NResultSetMetaData.hxx +++ b/connectivity/source/drivers/evoab2/NResultSetMetaData.hxx @@ -31,7 +31,7 @@ #include <com/sun/star/sdbc/XResultSetMetaData.hpp> #include <cppuhelper/implbase1.hxx> #include "NConnection.hxx" -#include <vos/ref.hxx> +#include <rtl/ref.hxx> #include <com/sun/star/connection/XConnection.hpp> namespace connectivity { @@ -51,7 +51,7 @@ namespace connectivity virtual ~OEvoabResultSetMetaData(); public: OEvoabResultSetMetaData(const ::rtl::OUString& _aTableName); - void setEvoabFields(const ::vos::ORef<connectivity::OSQLColumns> &xColumns) throw(::com::sun::star::sdbc::SQLException); + void setEvoabFields(const ::rtl::Reference<connectivity::OSQLColumns> &xColumns) throw(::com::sun::star::sdbc::SQLException); inline sal_uInt32 fieldAtColumn(sal_Int32 columnIndex) const { return m_aEvoabFields[columnIndex - 1]; } inline sal_Int32 getFieldSize() const diff --git a/connectivity/source/drivers/evoab2/NStatement.cxx b/connectivity/source/drivers/evoab2/NStatement.cxx index cbbea5f67a75..af914aae7e87 100644 --- a/connectivity/source/drivers/evoab2/NStatement.cxx +++ b/connectivity/source/drivers/evoab2/NStatement.cxx @@ -602,7 +602,7 @@ QueryData OCommonStatement::impl_getEBookQuery_throw( const ::rtl::OUString& _rS // a postcondition of this method is that we properly determined the SELECT columns aData.xSelectColumns = m_aSQLIterator.getSelectColumns(); - if ( !aData.xSelectColumns.isValid() ) + if ( !aData.xSelectColumns.is() ) m_pConnection->throwGenericSQLException( STR_QUERY_TOO_COMPLEX, *this ); return aData; diff --git a/connectivity/source/drivers/evoab2/NStatement.hxx b/connectivity/source/drivers/evoab2/NStatement.hxx index 63c9b00d7b83..7395ec9e6438 100644 --- a/connectivity/source/drivers/evoab2/NStatement.hxx +++ b/connectivity/source/drivers/evoab2/NStatement.hxx @@ -87,7 +87,7 @@ namespace connectivity public: ::rtl::OUString sTable; QueryFilterType eFilterType; - ::vos::ORef< ::connectivity::OSQLColumns > xSelectColumns; + ::rtl::Reference< ::connectivity::OSQLColumns > xSelectColumns; SortDescriptor aSortOrder; QueryData() diff --git a/connectivity/source/drivers/evoab2/makefile.mk b/connectivity/source/drivers/evoab2/makefile.mk index e8a1cf96cddf..837ef499583a 100644 --- a/connectivity/source/drivers/evoab2/makefile.mk +++ b/connectivity/source/drivers/evoab2/makefile.mk @@ -81,6 +81,7 @@ SHL1STDLIBS=\ $(UNOTOOLSLIB) \ $(UCBHELPERLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(DBFILELIB) \ $(COMPHELPERLIB) diff --git a/connectivity/source/drivers/file/FDriver.cxx b/connectivity/source/drivers/file/FDriver.cxx index 13be82514c1d..c41a839c3fef 100644 --- a/connectivity/source/drivers/file/FDriver.cxx +++ b/connectivity/source/drivers/file/FDriver.cxx @@ -249,7 +249,7 @@ Reference< XTablesSupplier > SAL_CALL OFileDriver::getDataDefinitionByURL( const return getDataDefinitionByConnection(connect(url,info)); } // ----------------------------------------------------------------------------- -void OOperandParam::describe(const Reference< XPropertySet>& rColumn, ::vos::ORef<connectivity::OSQLColumns> rParameterColumns) +void OOperandParam::describe(const Reference< XPropertySet>& rColumn, ::rtl::Reference<connectivity::OSQLColumns> rParameterColumns) { // den alten namen beibehalten diff --git a/connectivity/source/drivers/file/FPreparedStatement.cxx b/connectivity/source/drivers/file/FPreparedStatement.cxx index 6bd8d5b6bb10..cb3fb1f78445 100644 --- a/connectivity/source/drivers/file/FPreparedStatement.cxx +++ b/connectivity/source/drivers/file/FPreparedStatement.cxx @@ -97,7 +97,7 @@ void OPreparedStatement::disposing() m_xParamColumns = NULL; m_xMetaData.clear(); - if(m_aParameterRow.isValid()) + if(m_aParameterRow.is()) { m_aParameterRow->get().clear(); m_aParameterRow = NULL; @@ -299,7 +299,7 @@ void SAL_CALL OPreparedStatement::setNull( sal_Int32 parameterIndex, sal_Int32 / ::osl::MutexGuard aGuard( m_aMutex ); checkAndResizeParameters(parameterIndex); - if ( m_aAssignValues.isValid() ) + if ( m_aAssignValues.is() ) (m_aAssignValues->get())[m_aParameterIndexes[parameterIndex]]->setNull(); else (m_aParameterRow->get())[parameterIndex]->setNull(); @@ -429,8 +429,8 @@ Reference<XResultSet> OPreparedStatement::initResultSet() Reference<XResultSet> xRs(m_pResultSet); // check if we got enough paramters - if ( (m_aParameterRow.isValid() && ( m_aParameterRow->get().size() -1 ) < m_xParamColumns->get().size()) || - (m_xParamColumns.isValid() && !m_aParameterRow.isValid() && !m_aParameterRow->get().empty()) ) + if ( (m_aParameterRow.is() && ( m_aParameterRow->get().size() -1 ) < m_xParamColumns->get().size()) || + (m_xParamColumns.is() && !m_aParameterRow.is() && !m_aParameterRow->get().empty()) ) m_pConnection->throwGenericSQLException(STR_INVALID_PARA_COUNT,*this); m_pResultSet->OpenImpl(); @@ -453,7 +453,7 @@ void OPreparedStatement::checkAndResizeParameters(sal_Int32 parameterIndex) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OPreparedStatement::checkAndResizeParameters" ); ::connectivity::checkDisposed(OStatement_BASE::rBHelper.bDisposed); - if ( m_aAssignValues.isValid() && (parameterIndex < 1 || parameterIndex >= static_cast<sal_Int32>(m_aParameterIndexes.size())) ) + if ( m_aAssignValues.is() && (parameterIndex < 1 || parameterIndex >= static_cast<sal_Int32>(m_aParameterIndexes.size())) ) throwInvalidIndexException(*this); else if ( static_cast<sal_Int32>((m_aParameterRow->get()).size()) <= parameterIndex ) { @@ -461,7 +461,7 @@ void OPreparedStatement::checkAndResizeParameters(sal_Int32 parameterIndex) (m_aParameterRow->get()).resize(parameterIndex+1); for ( ;i <= parameterIndex+1; ++i ) { - if ( !(m_aParameterRow->get())[i].isValid() ) + if ( !(m_aParameterRow->get())[i].is() ) (m_aParameterRow->get())[i] = new ORowSetValueDecorator; } } @@ -473,7 +473,7 @@ void OPreparedStatement::setParameter(sal_Int32 parameterIndex, const ORowSetVal ::osl::MutexGuard aGuard( m_aMutex ); checkAndResizeParameters(parameterIndex); - if(m_aAssignValues.isValid()) + if(m_aAssignValues.is()) *(m_aAssignValues->get())[m_aParameterIndexes[parameterIndex]] = x; else *((m_aParameterRow->get())[parameterIndex]) = x; @@ -580,7 +580,7 @@ void OPreparedStatement::initializeResultSet(OResultSet* _pResult) USHORT nParaCount=0; // gibt die aktuelle Anzahl der bisher gesetzen Parameter an // Nach zu substituierenden Parametern suchen: - size_t nCount = m_aAssignValues.isValid() ? m_aAssignValues->get().size() : 1; // 1 ist wichtig fuer die Kriterien + size_t nCount = m_aAssignValues.is() ? m_aAssignValues->get().size() : 1; // 1 ist wichtig fuer die Kriterien for (size_t j = 1; j < nCount; j++) { UINT32 nParameter = (*m_aAssignValues).getParameterIndex(j); @@ -593,19 +593,19 @@ void OPreparedStatement::initializeResultSet(OResultSet* _pResult) // (*m_aAssignValues)[j] = (*m_aParameterRow)[(UINT16)nParameter]; } - if (m_aParameterRow.isValid() && (m_xParamColumns->get().size()+1) != m_aParameterRow->get().size() ) + if (m_aParameterRow.is() && (m_xParamColumns->get().size()+1) != m_aParameterRow->get().size() ) { sal_Int32 i = m_aParameterRow->get().size(); sal_Int32 nParamColumns = m_xParamColumns->get().size()+1; m_aParameterRow->get().resize(nParamColumns); for ( ;i < nParamColumns; ++i ) { - if ( !(m_aParameterRow->get())[i].isValid() ) + if ( !(m_aParameterRow->get())[i].is() ) (m_aParameterRow->get())[i] = new ORowSetValueDecorator; } //m_aParameterRow->resize(m_xParamColumns->size()+1); } - if (m_aParameterRow.isValid() && nParaCount < m_aParameterRow->get().size() ) + if (m_aParameterRow.is() && nParaCount < m_aParameterRow->get().size() ) { m_pSQLAnalyzer->bindParameterRow(m_aParameterRow); @@ -619,7 +619,7 @@ void OPreparedStatement::parseParamterElem(const String& _sColumnName,OSQLParseN Reference<XPropertySet> xCol; m_xColNames->getByName(_sColumnName) >>= xCol; sal_Int32 nParameter = -1; - if(m_xParamColumns.isValid()) + if(m_xParamColumns.is()) { OSQLColumns::Vector::const_iterator aIter = find(m_xParamColumns->get().begin(),m_xParamColumns->get().end(),_sColumnName,::comphelper::UStringMixEqual(m_pTable->isCaseSensitive())); if(aIter != m_xParamColumns->get().end()) diff --git a/connectivity/source/drivers/file/FResultSet.cxx b/connectivity/source/drivers/file/FResultSet.cxx index c1f2a625e7e5..054fe31424b8 100644 --- a/connectivity/source/drivers/file/FResultSet.cxx +++ b/connectivity/source/drivers/file/FResultSet.cxx @@ -197,7 +197,7 @@ void OResultSet::clear() m_pFileSet = NULL; DELETEZ(m_pSortIndex); - if(m_aInsertRow.isValid()) + if(m_aInsertRow.is()) m_aInsertRow->get().clear(); m_aSkipDeletedSet.clear(); @@ -589,12 +589,12 @@ sal_Bool OResultSet::evaluate() { if(m_pEvaluationKeySet) { - bRet = m_pTable->fetchRow(m_aEvaluateRow,m_pTable->getTableColumns().getBody(),sal_True,sal_True); + bRet = m_pTable->fetchRow(m_aEvaluateRow,*(m_pTable->getTableColumns()),sal_True,sal_True); evaluate(); } else - bRet = m_pTable->fetchRow(m_aRow,m_xColumns.getBody(),sal_False,sal_True); + bRet = m_pTable->fetchRow(m_aRow,*m_xColumns,sal_False,sal_True); } } @@ -651,8 +651,8 @@ void SAL_CALL OResultSet::insertRow( ) throw(SQLException, RuntimeException) // we know that we append new rows at the end // so we have to know where the end is m_aSkipDeletedSet.skipDeleted(IResultSetHelper::LAST,1,sal_False); - m_bRowInserted = m_pTable->InsertRow(m_aInsertRow.getBody(), TRUE,m_xColsIdx); - if(m_bRowInserted && m_pFileSet.isValid()) + m_bRowInserted = m_pTable->InsertRow(*m_aInsertRow, TRUE, m_xColsIdx); + if(m_bRowInserted && m_pFileSet.is()) { sal_Int32 nPos = (m_aInsertRow->get())[0]->getValue(); m_pFileSet->get().push_back(nPos); @@ -672,7 +672,7 @@ void SAL_CALL OResultSet::updateRow( ) throw(SQLException, RuntimeException) if(!m_pTable || m_pTable->isReadOnly()) lcl_throwError(STR_TABLE_READONLY,*this); - m_bRowUpdated = m_pTable->UpdateRow(m_aInsertRow.getBody(), m_aRow,m_xColsIdx); + m_bRowUpdated = m_pTable->UpdateRow(*m_aInsertRow, m_aRow,m_xColsIdx); *(m_aInsertRow->get())[0] = (sal_Int32)(m_aRow->get())[0]->getValue(); clearInsertRow(); @@ -693,8 +693,8 @@ void SAL_CALL OResultSet::deleteRow() throw(SQLException, RuntimeException) lcl_throwError(STR_ROW_ALREADY_DELETED,*this); sal_Int32 nPos = (sal_Int32)(m_aRow->get())[0]->getValue(); - m_bRowDeleted = m_pTable->DeleteRow(m_xColumns.getBody()); - if(m_bRowDeleted && m_pFileSet.isValid()) + m_bRowDeleted = m_pTable->DeleteRow(*m_xColumns); + if(m_bRowDeleted && m_pFileSet.is()) { m_aRow->setDeleted(sal_True); // don't touch the m_pFileSet member here @@ -714,7 +714,7 @@ void SAL_CALL OResultSet::cancelRowUpdates( ) throw(SQLException, RuntimeExcept m_bRowInserted = sal_False; m_bRowDeleted = sal_False; - if(m_aInsertRow.isValid()) + if(m_aInsertRow.is()) { OValueRefVector::Vector::iterator aIter = m_aInsertRow->get().begin()+1; for(;aIter != m_aInsertRow->get().end();++aIter) @@ -919,7 +919,7 @@ BOOL OResultSet::ExecuteRow(IResultSetHelper::Movement eFirstCursorPosition, IResultSetHelper::Movement eCursorPosition = eFirstCursorPosition; INT32 nOffset = nFirstOffset; - const OSQLColumns & rTableCols = m_pTable->getTableColumns().getBody(); + const OSQLColumns & rTableCols = *(m_pTable->getTableColumns()); BOOL bHasRestriction = m_pSQLAnalyzer->hasRestriction(); again: @@ -958,7 +958,7 @@ again: return sal_False; } } - else if (m_pFileSet.isValid()) + else if (m_pFileSet.is()) { OSL_ENSURE(//!m_pFileSet->IsFrozen() && eCursorPosition == IResultSetHelper::NEXT, "Falsche CursorPosition!"); @@ -995,14 +995,14 @@ again: // Evaluate darf nur gesetzt sein, // wenn der Keyset weiter aufgebaut werden soll if (m_aSQLIterator.getStatementType() == SQL_STATEMENT_SELECT && !isCount() && - (m_pFileSet.isValid() || m_pSortIndex) && bEvaluate) + (m_pFileSet.is() || m_pSortIndex) && bEvaluate) { if (m_pSortIndex) { OKeyValue* pKeyValue = GetOrderbyKeyValue(m_aEvaluateRow); m_pSortIndex->AddKeyValue(pKeyValue); } - else if (m_pFileSet.isValid()) + else if (m_pFileSet.is()) { // OSL_ENSURE(!m_pFileSet->IsFrozen() , "Falsche CursorPosition!"); sal_uInt32 nBookmarkValue = Abs((sal_Int32)(m_aEvaluateRow->get())[0]->getValue()); @@ -1015,13 +1015,13 @@ again: if (bEvaluate) { // jetzt die eigentliche Ergebniszeile Lesen - bOK = m_pTable->fetchRow(m_aEvaluateRow, m_pTable->getTableColumns().getBody(), sal_True,TRUE); + bOK = m_pTable->fetchRow(m_aEvaluateRow, *(m_pTable->getTableColumns()), sal_True,TRUE); } if (bOK) { // Nur die zu aendernden Werte uebergeben: - if(!m_pTable->UpdateRow(m_aAssignValues.getBody(),m_aEvaluateRow,m_xColsIdx)) + if(!m_pTable->UpdateRow(*m_aAssignValues,m_aEvaluateRow, m_xColsIdx)) return sal_False; } } @@ -1030,11 +1030,11 @@ again: sal_Bool bOK = sal_True; if (bEvaluate) { - bOK = m_pTable->fetchRow(m_aEvaluateRow, m_pTable->getTableColumns().getBody(), sal_True,TRUE); + bOK = m_pTable->fetchRow(m_aEvaluateRow, *(m_pTable->getTableColumns()), sal_True,TRUE); } if (bOK) { - if(!m_pTable->DeleteRow(m_xColumns.getBody())) + if(!m_pTable->DeleteRow(*m_xColumns)) return sal_False; } } @@ -1049,13 +1049,11 @@ BOOL OResultSet::Move(IResultSetHelper::Movement eCursorPosition, INT32 nOffset, //IgnoreDeletedRows: // INT32 nTempPos = m_nRowPos; - // exclusiver zugriff auf die Tabelle - // NAMESPACE_VOS(OGuard)* pGuard = m_pTable->Lock(); if (m_aSQLIterator.getStatementType() == SQL_STATEMENT_SELECT && !isCount()) { - if (!m_pFileSet.isValid()) // kein Index verfuegbar + if (!m_pFileSet.is()) // kein Index verfuegbar { // Normales FETCH ExecuteRow(eCursorPosition,nOffset,FALSE,bRetrieveData); @@ -1151,7 +1149,7 @@ BOOL OResultSet::Move(IResultSetHelper::Movement eCursorPosition, INT32 nOffset, if (bOK) { // jetzt nochmal die Ergebnisse lesen - m_pTable->fetchRow(m_aRow, m_pTable->getTableColumns().getBody(), sal_True,bRetrieveData); + m_pTable->fetchRow(m_aRow, *(m_pTable->getTableColumns()), sal_True,bRetrieveData); // now set the bookmark for outside *(*m_aRow->get().begin()) = sal_Int32(m_nRowPos + 1); @@ -1246,7 +1244,7 @@ Error: case IResultSetHelper::ABSOLUTE: case IResultSetHelper::RELATIVE: if (nOffset > 0) - m_nRowPos = m_pFileSet.isValid() ? (sal_Int32)m_pFileSet->get().size() : -1; + m_nRowPos = m_pFileSet.is() ? (sal_Int32)m_pFileSet->get().size() : -1; else if (nOffset < 0) m_nRowPos = -1; break; @@ -1409,8 +1407,6 @@ BOOL OResultSet::OpenImpl() m_nFilePos = 0; m_nRowCountResult = -1; - // exclusiver zugriff auf die Tabelle - // NAMESPACE_VOS(OGuard)* pGuard = pTable->Lock(); m_nLastVisitedPos = m_pTable->getCurrentLastPos(); switch(m_aSQLIterator.getStatementType()) @@ -1488,7 +1484,7 @@ BOOL OResultSet::OpenImpl() if (IsSorted()) sortRows(); - if (!m_pFileSet.isValid()) + if (!m_pFileSet.is()) { m_pFileSet = new OKeySet(); @@ -1503,9 +1499,9 @@ BOOL OResultSet::OpenImpl() m_pFileSet->get().push_back(i + 1); } } - OSL_ENSURE(m_pFileSet.isValid(),"Kein KeySet vorhanden! :-("); + OSL_ENSURE(m_pFileSet.is(),"Kein KeySet vorhanden! :-("); - if(bDistinct && m_pFileSet.isValid()) // sicher ist sicher + if(bDistinct && m_pFileSet.is()) // sicher ist sicher { OValueRow aSearchRow = new OValueVector(m_aRow->get().size()); OValueRefVector::Vector::iterator aRowIter = m_aRow->get().begin(); @@ -1632,8 +1628,8 @@ BOOL OResultSet::OpenImpl() case SQL_STATEMENT_INSERT: m_nRowCountResult = 0; - OSL_ENSURE(m_aAssignValues.isValid(),"No assign values set!"); - if(!m_pTable->InsertRow(m_aAssignValues.getBody(), TRUE,m_xColsIdx)) + OSL_ENSURE(m_aAssignValues.is(),"No assign values set!"); + if(!m_pTable->InsertRow(*m_aAssignValues, TRUE,m_xColsIdx)) { m_nFilePos = 0; return sal_False; @@ -1680,7 +1676,7 @@ sal_Int64 OResultSet::getSomething( const Sequence< sal_Int8 > & rId ) throw (Ru // ----------------------------------------------------------------------------- void OResultSet::setBoundedColumns(const OValueRefRow& _rRow, const OValueRefRow& _rSelectRow, - const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns, + const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns, const Reference<XIndexAccess>& _xNames, sal_Bool _bSetColumnMapping, const Reference<XDatabaseMetaData>& _xMetaData, @@ -1847,7 +1843,7 @@ void OResultSet::clearInsertRow() void OResultSet::initializeRow(OValueRefRow& _rRow,sal_Int32 _nColumnCount) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OResultSet::initializeRow" ); - if(!_rRow.isValid()) + if(!_rRow.is()) { _rRow = new OValueRefVector(_nColumnCount); (_rRow->get())[0]->setBound(sal_True); diff --git a/connectivity/source/drivers/file/FResultSetMetaData.cxx b/connectivity/source/drivers/file/FResultSetMetaData.cxx index 0ae95479f2c6..6d75d6f67357 100644 --- a/connectivity/source/drivers/file/FResultSetMetaData.cxx +++ b/connectivity/source/drivers/file/FResultSetMetaData.cxx @@ -47,7 +47,7 @@ using namespace ::com::sun::star::container; using namespace ::com::sun::star::lang; // ------------------------------------------------------------------------- -OResultSetMetaData::OResultSetMetaData(const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns,const ::rtl::OUString& _aTableName,OFileTable* _pTable) +OResultSetMetaData::OResultSetMetaData(const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns,const ::rtl::OUString& _aTableName,OFileTable* _pTable) :m_aTableName(_aTableName) ,m_xColumns(_rxColumns) ,m_pTable(_pTable) diff --git a/connectivity/source/drivers/file/FStatement.cxx b/connectivity/source/drivers/file/FStatement.cxx index b7b9836c0221..0d504a71d2be 100644 --- a/connectivity/source/drivers/file/FStatement.cxx +++ b/connectivity/source/drivers/file/FStatement.cxx @@ -135,7 +135,7 @@ void OStatement_BASE2::disposing() if(m_pSQLAnalyzer) m_pSQLAnalyzer->dispose(); - if(m_aRow.isValid()) + if(m_aRow.is()) { m_aRow->get().clear(); m_aRow = NULL; @@ -363,7 +363,7 @@ sal_Int32 SAL_CALL OStatement::executeUpdate( const ::rtl::OUString& sql ) throw void SAL_CALL OStatement_Base::disposing(void) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OStatement_Base::disposing" ); - if(m_aEvaluateRow.isValid()) + if(m_aEvaluateRow.is()) { m_aEvaluateRow->get().clear(); m_aEvaluateRow = NULL; @@ -458,7 +458,7 @@ void OStatement_Base::setOrderbyColumn( OSQLParseNode* pColumnRef, } catch(Exception) { - ::vos::ORef<OSQLColumns> aSelectColumns = m_aSQLIterator.getSelectColumns(); + ::rtl::Reference<OSQLColumns> aSelectColumns = m_aSQLIterator.getSelectColumns(); ::comphelper::UStringMixEqual aCase; OSQLColumns::Vector::const_iterator aFind = ::connectivity::find(aSelectColumns->get().begin(),aSelectColumns->get().end(),aColumnName,aCase); if ( aFind == aSelectColumns->get().end() ) @@ -554,7 +554,7 @@ void OStatement_Base::createColumnMapping() { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OStatement_Base::createColumnMapping" ); // initialize the column index map (mapping select columns to table columns) - ::vos::ORef<connectivity::OSQLColumns> xColumns = m_aSQLIterator.getSelectColumns(); + ::rtl::Reference<connectivity::OSQLColumns> xColumns = m_aSQLIterator.getSelectColumns(); m_aColMapping.resize(xColumns->get().size() + 1); for (sal_Int32 i=0; i<(sal_Int32)m_aColMapping.size(); ++i) m_aColMapping[i] = i; @@ -598,7 +598,7 @@ void OStatement_Base::GetAssignValues() else if (SQL_ISRULE(m_pParseTree,insert_statement)) { // Row fuer die zu setzenden Werte anlegen (Referenz durch new) - if(m_aAssignValues.isValid()) + if(m_aAssignValues.is()) m_aAssignValues->get().clear(); sal_Int32 nCount = Reference<XIndexAccess>(m_xColNames,UNO_QUERY)->getCount(); m_aAssignValues = new OAssignValues(nCount); @@ -687,7 +687,7 @@ void OStatement_Base::GetAssignValues() } else if (SQL_ISRULE(m_pParseTree,update_statement_searched)) { - if(m_aAssignValues.isValid()) + if(m_aAssignValues.is()) m_aAssignValues->get().clear(); sal_Int32 nCount = Reference<XIndexAccess>(m_xColNames,UNO_QUERY)->getCount(); m_aAssignValues = new OAssignValues(nCount); diff --git a/connectivity/source/drivers/file/fanalyzer.cxx b/connectivity/source/drivers/file/fanalyzer.cxx index 842a943610e0..f55d609daf51 100644 --- a/connectivity/source/drivers/file/fanalyzer.cxx +++ b/connectivity/source/drivers/file/fanalyzer.cxx @@ -93,9 +93,9 @@ void OSQLAnalyzer::start(OSQLParseNode* pSQLParseNode) || SQL_ISRULE(pColumnRef,factor) || SQL_ISRULE(pColumnRef,set_fct_spec) ) { - ::vos::ORef<OPredicateCompiler> pCompiler = new OPredicateCompiler(this); + ::rtl::Reference<OPredicateCompiler> pCompiler = new OPredicateCompiler(this); pCompiler->setOrigColumns(m_aCompiler->getOrigColumns()); - ::vos::ORef<OPredicateInterpreter> pInterpreter = new OPredicateInterpreter(pCompiler); + ::rtl::Reference<OPredicateInterpreter> pInterpreter = new OPredicateInterpreter(pCompiler); pCompiler->execute( pColumnRef ); m_aSelectionEvaluations.push_back( TPredicates(pCompiler,pInterpreter) ); } @@ -153,7 +153,7 @@ void OSQLAnalyzer::bindSelectRow(const OValueRefRow& _pRow) OEvaluateSetList aEvaluateSetList; for ( ::std::vector< TPredicates >::iterator aIter = m_aSelectionEvaluations.begin(); aIter != m_aSelectionEvaluations.end();++aIter) { - if ( aIter->first.isValid() ) + if ( aIter->first.is() ) bindRow( aIter->first->m_aCodeList,_pRow,aEvaluateSetList); } } @@ -197,7 +197,7 @@ void OSQLAnalyzer::bindSelectRow(const OValueRefRow& _pRow) } //------------------------------------------------------------------ -void OSQLAnalyzer::describeParam(::vos::ORef<OSQLColumns> rParameterColumns) +void OSQLAnalyzer::describeParam(::rtl::Reference<OSQLColumns> rParameterColumns) { OCodeList& rCodeList = m_aCompiler->m_aCodeList; OCodeStack aCodeStack; @@ -208,7 +208,7 @@ void OSQLAnalyzer::describeParam(::vos::ORef<OSQLColumns> rParameterColumns) return; // keine Parameter // Anlegen von Columns, die eine genauere Beschreibung fuer die enthalten - ::vos::ORef<OSQLColumns> aNewParamColumns = new OSQLColumns(*rParameterColumns); + ::rtl::Reference<OSQLColumns> aNewParamColumns = new OSQLColumns(*rParameterColumns); // Anlegen einer Testzeile, wird benoetigt um die Parameter zu beschreiben @@ -278,7 +278,7 @@ BOOL OSQLAnalyzer::hasFunctions() const m_bSelectionFirstTime = sal_False; for ( ::std::vector< TPredicates >::const_iterator aIter = m_aSelectionEvaluations.begin(); aIter != m_aSelectionEvaluations.end() && !m_bHasSelectionCode ;++aIter) { - if ( aIter->first.isValid() ) + if ( aIter->first.is() ) m_bHasSelectionCode = aIter->first->hasCode(); } } @@ -290,7 +290,7 @@ void OSQLAnalyzer::setSelectionEvaluationResult(OValueRefRow& _pRow,const ::std: sal_Int32 nPos = 1; for ( ::std::vector< TPredicates >::iterator aIter = m_aSelectionEvaluations.begin(); aIter != m_aSelectionEvaluations.end();++aIter,++nPos) { - if ( aIter->second.isValid() ) + if ( aIter->second.is() ) { sal_Int32 map = nPos; // the first column (index 0) is for convenience only. The first real select column is no 1. @@ -306,7 +306,7 @@ void OSQLAnalyzer::dispose() m_aCompiler->dispose(); for ( ::std::vector< TPredicates >::iterator aIter = m_aSelectionEvaluations.begin(); aIter != m_aSelectionEvaluations.end();++aIter) { - if ( aIter->first.isValid() ) + if ( aIter->first.is() ) aIter->first->dispose(); } } @@ -316,7 +316,7 @@ void OSQLAnalyzer::setOrigColumns(const OFileColumns& rCols) m_aCompiler->setOrigColumns(rCols); for ( ::std::vector< TPredicates >::iterator aIter = m_aSelectionEvaluations.begin(); aIter != m_aSelectionEvaluations.end();++aIter) { - if ( aIter->first.isValid() ) + if ( aIter->first.is() ) aIter->first->setOrigColumns(rCols); } } diff --git a/connectivity/source/drivers/file/fcode.cxx b/connectivity/source/drivers/file/fcode.cxx index 128662b19ced..67c58ad9ca7a 100644 --- a/connectivity/source/drivers/file/fcode.cxx +++ b/connectivity/source/drivers/file/fcode.cxx @@ -102,23 +102,23 @@ OOperandRow::OOperandRow(sal_uInt16 _nPos, sal_Int32 _rType) void OOperandRow::bindValue(const OValueRefRow& _pRow) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OOperandRow::OOperandRow" ); - OSL_ENSURE(_pRow.isValid(),"NO EMPTY row allowed!"); + OSL_ENSURE(_pRow.is(),"NO EMPTY row allowed!"); m_pRow = _pRow; - OSL_ENSURE(m_pRow.isValid() && m_nRowPos < m_pRow->get().size(),"Invalid RowPos is >= vector.size()"); + OSL_ENSURE(m_pRow.is() && m_nRowPos < m_pRow->get().size(),"Invalid RowPos is >= vector.size()"); (m_pRow->get())[m_nRowPos]->setBound(sal_True); } // ----------------------------------------------------------------------------- void OOperandRow::setValue(const ORowSetValue& _rVal) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OOperandRow::setValue" ); - OSL_ENSURE(m_pRow.isValid() && m_nRowPos < m_pRow->get().size(),"Invalid RowPos is >= vector.size()"); + OSL_ENSURE(m_pRow.is() && m_nRowPos < m_pRow->get().size(),"Invalid RowPos is >= vector.size()"); (*(m_pRow->get())[m_nRowPos]) = _rVal; } //------------------------------------------------------------------ const ORowSetValue& OOperandRow::getValue() const { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "OOperandRow::getValue" ); - OSL_ENSURE(m_pRow.isValid() && m_nRowPos < m_pRow->get().size(),"Invalid RowPos is >= vector.size()"); + OSL_ENSURE(m_pRow.is() && m_nRowPos < m_pRow->get().size(),"Invalid RowPos is >= vector.size()"); return (m_pRow->get())[m_nRowPos]->getValue(); } diff --git a/connectivity/source/drivers/file/makefile.mk b/connectivity/source/drivers/file/makefile.mk index bd6a29e3aef1..16e28a3062c9 100644 --- a/connectivity/source/drivers/file/makefile.mk +++ b/connectivity/source/drivers/file/makefile.mk @@ -80,6 +80,7 @@ SHL1STDLIBS=\ $(TOOLSLIB) \ $(UCBHELPERLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(UNOTOOLSLIB) \ $(COMPHELPERLIB) diff --git a/connectivity/source/drivers/flat/EColumns.cxx b/connectivity/source/drivers/flat/EColumns.cxx index 59102986cc52..43d78e0479bf 100644 --- a/connectivity/source/drivers/flat/EColumns.cxx +++ b/connectivity/source/drivers/flat/EColumns.cxx @@ -45,7 +45,7 @@ sdbcx::ObjectType OFlatColumns::createObject(const ::rtl::OUString& _rName) { OFlatTable* pTable = (OFlatTable*)m_pTable; - ::vos::ORef<OSQLColumns> aCols = pTable->getTableColumns(); + ::rtl::Reference<OSQLColumns> aCols = pTable->getTableColumns(); OSQLColumns::Vector::const_iterator aIter = find(aCols->get().begin(),aCols->get().end(),_rName,::comphelper::UStringMixEqual(isCaseSensitive())); sdbcx::ObjectType xRet; if(aIter != aCols->get().end()) diff --git a/connectivity/source/drivers/flat/ETable.cxx b/connectivity/source/drivers/flat/ETable.cxx index 29123073fe13..622da47534f2 100644 --- a/connectivity/source/drivers/flat/ETable.cxx +++ b/connectivity/source/drivers/flat/ETable.cxx @@ -104,7 +104,7 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) // column count const xub_StrLen nFieldCount = aHeaderLine.GetTokenCount(m_cFieldDelimiter,m_cStringDelimiter); - if(!m_aColumns.isValid()) + if(!m_aColumns.is()) m_aColumns = new OSQLColumns(); else m_aColumns->get().clear(); diff --git a/connectivity/source/drivers/flat/makefile.mk b/connectivity/source/drivers/flat/makefile.mk index 2d1f99f759c7..3d134ec12d30 100644 --- a/connectivity/source/drivers/flat/makefile.mk +++ b/connectivity/source/drivers/flat/makefile.mk @@ -83,6 +83,7 @@ SHL1STDLIBS=\ $(SVLLIB) \ $(UNOTOOLSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(DBFILELIB) \ $(COMPHELPERLIB) diff --git a/connectivity/source/drivers/jdbc/makefile.mk b/connectivity/source/drivers/jdbc/makefile.mk index 46619952163b..84326eb3c097 100644 --- a/connectivity/source/drivers/jdbc/makefile.mk +++ b/connectivity/source/drivers/jdbc/makefile.mk @@ -89,6 +89,7 @@ SHL1STDLIBS=\ $(CPPUHELPERLIB) \ $(VOSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(JVMACCESSLIB) \ $(DBTOOLSLIB) \ $(UNOTOOLSLIB) \ diff --git a/connectivity/source/drivers/kab/KPreparedStatement.cxx b/connectivity/source/drivers/kab/KPreparedStatement.cxx index 2b6853fa3926..2b1c13649b01 100644 --- a/connectivity/source/drivers/kab/KPreparedStatement.cxx +++ b/connectivity/source/drivers/kab/KPreparedStatement.cxx @@ -46,7 +46,7 @@ IMPLEMENT_SERVICE_INFO(KabPreparedStatement, "com.sun.star.sdbc.drivers.KabPrepa // ------------------------------------------------------------------------- void KabPreparedStatement::checkAndResizeParameters(sal_Int32 nParams) throw(SQLException) { - if ( !m_aParameterRow.isValid() ) + if ( !m_aParameterRow.is() ) m_aParameterRow = new OValueVector(); if (nParams < 1) @@ -58,10 +58,10 @@ void KabPreparedStatement::checkAndResizeParameters(sal_Int32 nParams) throw(SQL // ------------------------------------------------------------------------- void KabPreparedStatement::setKabFields() const throw(SQLException) { - ::vos::ORef<connectivity::OSQLColumns> xColumns; // selected columns + ::rtl::Reference<connectivity::OSQLColumns> xColumns; // selected columns xColumns = m_aSQLIterator.getSelectColumns(); - if (!xColumns.isValid()) + if (!xColumns.is()) { ::connectivity::SharedResources aResources; const ::rtl::OUString sError( aResources.getResourceString( @@ -112,7 +112,7 @@ void KabPreparedStatement::disposing() { KabPreparedStatement_BASE::disposing(); - if (m_aParameterRow.isValid()) + if (m_aParameterRow.is()) { m_aParameterRow->get().clear(); m_aParameterRow = NULL; diff --git a/connectivity/source/drivers/kab/KResultSetMetaData.cxx b/connectivity/source/drivers/kab/KResultSetMetaData.cxx index 8443488e7eb0..b4739d632352 100644 --- a/connectivity/source/drivers/kab/KResultSetMetaData.cxx +++ b/connectivity/source/drivers/kab/KResultSetMetaData.cxx @@ -49,7 +49,7 @@ KabResultSetMetaData::~KabResultSetMetaData() { } // ------------------------------------------------------------------------- -void KabResultSetMetaData::setKabFields(const ::vos::ORef<connectivity::OSQLColumns> &xColumns) throw(SQLException) +void KabResultSetMetaData::setKabFields(const ::rtl::Reference<connectivity::OSQLColumns> &xColumns) throw(SQLException) { OSQLColumns::Vector::const_iterator aIter; static const ::rtl::OUString aName(::rtl::OUString::createFromAscii("Name")); diff --git a/connectivity/source/drivers/kab/KResultSetMetaData.hxx b/connectivity/source/drivers/kab/KResultSetMetaData.hxx index 2ee6ababa91a..faf20edd9a21 100644 --- a/connectivity/source/drivers/kab/KResultSetMetaData.hxx +++ b/connectivity/source/drivers/kab/KResultSetMetaData.hxx @@ -32,7 +32,7 @@ #include <connectivity/CommonTools.hxx> #include <com/sun/star/sdbc/XResultSetMetaData.hpp> #include <cppuhelper/implbase1.hxx> -#include <vos/ref.hxx> +#include <rtl/ref.hxx> namespace connectivity { @@ -60,7 +60,7 @@ namespace connectivity { return this; } void setKabFields( - const ::vos::ORef<connectivity::OSQLColumns> &xColumns) throw(::com::sun::star::sdbc::SQLException); + const ::rtl::Reference<connectivity::OSQLColumns> &xColumns) throw(::com::sun::star::sdbc::SQLException); inline sal_uInt32 fieldAtColumn(sal_Int32 columnIndex) const { return m_aKabFields[columnIndex - 1]; } diff --git a/connectivity/source/drivers/kab/KStatement.cxx b/connectivity/source/drivers/kab/KStatement.cxx index 33b8a6b0a00b..4121681255fd 100644 --- a/connectivity/source/drivers/kab/KStatement.cxx +++ b/connectivity/source/drivers/kab/KStatement.cxx @@ -311,11 +311,11 @@ sal_Bool KabCommonStatement::isTableKnown(KabResultSet *pResult) const //------------------------------------------------------------------------------ void KabCommonStatement::setKabFields(KabResultSet *pResult) const throw(SQLException) { - ::vos::ORef<connectivity::OSQLColumns> xColumns; // selected columns + ::rtl::Reference<connectivity::OSQLColumns> xColumns; // selected columns KabResultSetMetaData *pMeta; // meta information - holds the list of KAddressBook fields xColumns = m_aSQLIterator.getSelectColumns(); - if (!xColumns.isValid()) + if (!xColumns.is()) { lcl_throwError(STR_INVALID_COLUMN_SELECTION); } diff --git a/connectivity/source/drivers/kab/makefile.mk b/connectivity/source/drivers/kab/makefile.mk index 5e32a5d3365f..2e98efe9ea2a 100644 --- a/connectivity/source/drivers/kab/makefile.mk +++ b/connectivity/source/drivers/kab/makefile.mk @@ -69,7 +69,8 @@ SHL1STDLIBS=\ $(CPPULIB) \ $(CPPUHELPERLIB) \ $(DBTOOLSLIB) \ - $(SALLIB) + $(SALLIB) \ + $(SALHELPERLIB) SHL1DEPN= SHL1IMPLIB= i$(TARGET) @@ -112,6 +113,7 @@ SHL2STDLIBS=\ $(CPPUHELPERLIB) \ $(VOSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(COMPHELPERLIB) diff --git a/connectivity/source/drivers/macab/MacabPreparedStatement.cxx b/connectivity/source/drivers/macab/MacabPreparedStatement.cxx index aaefdfc0811d..aa94353e72cd 100644 --- a/connectivity/source/drivers/macab/MacabPreparedStatement.cxx +++ b/connectivity/source/drivers/macab/MacabPreparedStatement.cxx @@ -47,7 +47,7 @@ IMPLEMENT_SERVICE_INFO(MacabPreparedStatement, "com.sun.star.sdbc.drivers.MacabP // ------------------------------------------------------------------------- void MacabPreparedStatement::checkAndResizeParameters(sal_Int32 nParams) throw(SQLException) { - if ( !m_aParameterRow.isValid() ) + if ( !m_aParameterRow.is() ) m_aParameterRow = new OValueVector(); if (nParams < 1) @@ -59,10 +59,10 @@ void MacabPreparedStatement::checkAndResizeParameters(sal_Int32 nParams) throw(S // ------------------------------------------------------------------------- void MacabPreparedStatement::setMacabFields() const throw(SQLException) { - ::vos::ORef<connectivity::OSQLColumns> xColumns; // selected columns + ::rtl::Reference<connectivity::OSQLColumns> xColumns; // selected columns xColumns = m_aSQLIterator.getSelectColumns(); - if (!xColumns.isValid()) + if (!xColumns.is()) { ::connectivity::SharedResources aResources; const ::rtl::OUString sError( aResources.getResourceString( @@ -114,7 +114,7 @@ void MacabPreparedStatement::disposing() { MacabPreparedStatement_BASE::disposing(); - if (m_aParameterRow.isValid()) + if (m_aParameterRow.is()) { m_aParameterRow->get().clear(); m_aParameterRow = NULL; diff --git a/connectivity/source/drivers/macab/MacabResultSetMetaData.cxx b/connectivity/source/drivers/macab/MacabResultSetMetaData.cxx index af9ccdb3809e..21cd4e9727c5 100644 --- a/connectivity/source/drivers/macab/MacabResultSetMetaData.cxx +++ b/connectivity/source/drivers/macab/MacabResultSetMetaData.cxx @@ -52,7 +52,7 @@ MacabResultSetMetaData::~MacabResultSetMetaData() { } // ------------------------------------------------------------------------- -void MacabResultSetMetaData::setMacabFields(const ::vos::ORef<connectivity::OSQLColumns> &xColumns) throw(SQLException) +void MacabResultSetMetaData::setMacabFields(const ::rtl::Reference<connectivity::OSQLColumns> &xColumns) throw(SQLException) { OSQLColumns::Vector::const_iterator aIter; static const ::rtl::OUString aName(::rtl::OUString::createFromAscii("Name")); diff --git a/connectivity/source/drivers/macab/MacabResultSetMetaData.hxx b/connectivity/source/drivers/macab/MacabResultSetMetaData.hxx index b79fc93a8408..262e23d655a6 100644 --- a/connectivity/source/drivers/macab/MacabResultSetMetaData.hxx +++ b/connectivity/source/drivers/macab/MacabResultSetMetaData.hxx @@ -33,7 +33,7 @@ #include <com/sun/star/sdbc/XResultSetMetaData.hpp> #include <cppuhelper/implbase1.hxx> #include <connectivity/dbexception.hxx> -#include <vos/ref.hxx> +#include <rtl/ref.hxx> namespace connectivity { @@ -62,7 +62,7 @@ namespace connectivity { return this; } void setMacabFields( - const ::vos::ORef<connectivity::OSQLColumns> &xColumns) throw(::com::sun::star::sdbc::SQLException); + const ::rtl::Reference<connectivity::OSQLColumns> &xColumns) throw(::com::sun::star::sdbc::SQLException); inline sal_uInt32 fieldAtColumn(sal_Int32 columnIndex) const { return m_aMacabFields[columnIndex - 1]; } diff --git a/connectivity/source/drivers/macab/MacabStatement.cxx b/connectivity/source/drivers/macab/MacabStatement.cxx index 2332de2d9bc3..583dc62910b6 100644 --- a/connectivity/source/drivers/macab/MacabStatement.cxx +++ b/connectivity/source/drivers/macab/MacabStatement.cxx @@ -313,11 +313,11 @@ MacabOrder *MacabCommonStatement::analyseOrderByClause(const OSQLParseNode *pPar //------------------------------------------------------------------------------ void MacabCommonStatement::setMacabFields(MacabResultSet *pResult) const throw(SQLException) { - ::vos::ORef<connectivity::OSQLColumns> xColumns; // selected columns + ::rtl::Reference<connectivity::OSQLColumns> xColumns; // selected columns MacabResultSetMetaData *pMeta; // meta information - holds the list of AddressBook fields xColumns = m_aSQLIterator.getSelectColumns(); - if (!xColumns.isValid()) + if (!xColumns.is()) { ::connectivity::SharedResources aResources; const ::rtl::OUString sError( aResources.getResourceString( diff --git a/connectivity/source/drivers/mozab/MPreparedStatement.cxx b/connectivity/source/drivers/mozab/MPreparedStatement.cxx index 9b80eb864f14..f8d417bf60da 100644 --- a/connectivity/source/drivers/mozab/MPreparedStatement.cxx +++ b/connectivity/source/drivers/mozab/MPreparedStatement.cxx @@ -90,7 +90,7 @@ void SAL_CALL OPreparedStatement::disposing() OCommonStatement::disposing(); m_xMetaData.clear(); - if(m_aParameterRow.isValid()) + if(m_aParameterRow.is()) { m_aParameterRow->get().clear(); m_aParameterRow = NULL; @@ -395,7 +395,7 @@ void OPreparedStatement::checkAndResizeParameters(sal_Int32 parameterIndex) { ::connectivity::checkDisposed(OCommonStatement_IBASE::rBHelper.bDisposed); - if ( !m_aParameterRow.isValid() ) { + if ( !m_aParameterRow.is() ) { m_aParameterRow = new OValueVector(); m_aParameterRow->get().push_back(sal_Int32(0)); } diff --git a/connectivity/source/drivers/mozab/MPreparedStatement.hxx b/connectivity/source/drivers/mozab/MPreparedStatement.hxx index f9da0a0f3d5f..110ea71c13c6 100644 --- a/connectivity/source/drivers/mozab/MPreparedStatement.hxx +++ b/connectivity/source/drivers/mozab/MPreparedStatement.hxx @@ -75,7 +75,7 @@ namespace connectivity ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSetMetaData > m_xMetaData; sal_Bool m_bPrepared; ::rtl::Reference< OResultSet > m_pResultSet; - ::vos::ORef<connectivity::OSQLColumns> m_xParamColumns; // the parameter columns + ::rtl::Reference<connectivity::OSQLColumns> m_xParamColumns; // the parameter columns OValueRow m_aParameterRow; diff --git a/connectivity/source/drivers/mozab/MResultSet.cxx b/connectivity/source/drivers/mozab/MResultSet.cxx index 4a013d47c467..50aee9f216ea 100644 --- a/connectivity/source/drivers/mozab/MResultSet.cxx +++ b/connectivity/source/drivers/mozab/MResultSet.cxx @@ -427,7 +427,7 @@ const ORowSetValue& OResultSet::getValue(sal_Int32 cardNumber, sal_Int32 columnI { ResultSetEntryGuard aGuard( *this ); - OSL_ENSURE(m_xColumns.isValid(), "Need the Columns!!"); + OSL_ENSURE(m_xColumns.is(), "Need the Columns!!"); OSL_ENSURE(columnIndex <= (sal_Int32)m_xColumns->get().size(), "Trying to access invalid columns number"); checkIndex( columnIndex ); @@ -722,7 +722,7 @@ void SAL_CALL OResultSet::release() throw() // ----------------------------------------------------------------------------- void OResultSet::initializeRow(OValueRow& _rRow,sal_Int32 _nColumnCount) { - if(!_rRow.isValid()) + if(!_rRow.is()) { _rRow = new OValueVector(_nColumnCount); (_rRow->get())[0].setBound(sal_True); @@ -750,7 +750,7 @@ void OResultSet::parseParameter( const OSQLParseNode* pNode, rtl::OUString& rMat m_nParamIndex ++; OSL_TRACE("Parameter name [%d]: %s\n", m_nParamIndex,OUtoCStr(aParameterName) ); - if ( m_aParameterRow.isValid() ) { + if ( m_aParameterRow.is() ) { OSL_ENSURE( m_nParamIndex < (sal_Int32)m_aParameterRow->get().size() + 1, "More parameters than values found" ); rMatchString = (m_aParameterRow->get())[(sal_uInt16)m_nParamIndex]; #if OSL_DEBUG_LEVEL > 0 @@ -775,8 +775,8 @@ void OResultSet::analyseWhereClause( const OSQLParseNode* parseT return; if ( m_pSQLIterator->getParseTree() != NULL ) { - ::vos::ORef<OSQLColumns> xColumns = m_pSQLIterator->getParameters(); - if(xColumns.isValid()) + ::rtl::Reference<OSQLColumns> xColumns = m_pSQLIterator->getParameters(); + if(xColumns.is()) { ::rtl::OUString aTabName,aColName,aParameterName,aParameterValue; OSQLColumns::Vector::iterator aIter = xColumns->get().begin(); @@ -785,7 +785,7 @@ void OResultSet::analyseWhereClause( const OSQLParseNode* parseT { (*aIter)->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_NAME)) >>= aColName; OSL_TRACE("Prop Column Name : %s\n", OUtoCStr( aColName ) ); - if ( m_aParameterRow.isValid() ) { + if ( m_aParameterRow.is() ) { aParameterValue = (m_aParameterRow->get())[(sal_uInt16)i]; #if OSL_DEBUG_LEVEL > 0 OSL_TRACE("Prop Value : %s\n", OUtoCStr( aParameterValue ) ); @@ -1065,7 +1065,7 @@ void OResultSet::fillRowData() OConnection* xConnection = static_cast<OConnection*>(m_pStatement->getConnection().get()); m_xColumns = m_pSQLIterator->getSelectColumns(); - OSL_ENSURE(m_xColumns.isValid(), "Need the Columns!!"); + OSL_ENSURE(m_xColumns.is(), "Need the Columns!!"); OSQLColumns::Vector::const_iterator aIter = m_xColumns->get().begin(); const ::rtl::OUString sProprtyName = OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_NAME); @@ -1166,7 +1166,7 @@ sal_Int32 OResultSet::getRowForCardNumber(sal_Int32 nCardNum) { OSL_TRACE("In/Out: OResultSet::getRowForCardNumber, nCardNum = %u", nCardNum ); - if ( m_pKeySet.isValid() ) + if ( m_pKeySet.is() ) { sal_Int32 nPos; for(nPos=0;nPos < (sal_Int32)m_pKeySet->get().size();nPos++) @@ -1204,7 +1204,7 @@ void SAL_CALL OResultSet::executeQuery() throw( ::com::sun::star::sdbc::SQLExcep fillRowData(); - OSL_ENSURE(m_xColumns.isValid(), "Need the Columns!!"); + OSL_ENSURE(m_xColumns.is(), "Need the Columns!!"); // sal_Int32 nColumnCount = m_xColumns->size(); // initializeRow(m_aRow,nColumnCount); @@ -1329,7 +1329,7 @@ void SAL_CALL OResultSet::executeQuery() throw( ::com::sun::star::sdbc::SQLExcep m_pKeySet = new OKeySet(); // Handle the DISTINCT case - if ( bDistinct && m_pKeySet.isValid() ) + if ( bDistinct && m_pKeySet.is() ) { OValueRow aSearchRow = new OValueVector( m_aRow->get().size() ); @@ -1369,7 +1369,7 @@ void SAL_CALL OResultSet::executeQuery() throw( ::com::sun::star::sdbc::SQLExcep // ----------------------------------------------------------------------------- void OResultSet::setBoundedColumns(const OValueRow& _rRow, - const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns, + const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns, const Reference<XIndexAccess>& _xNames, sal_Bool _bSetColumnMapping, const Reference<XDatabaseMetaData>& _xMetaData, @@ -1516,7 +1516,7 @@ sal_Int32 OResultSet::deletedCount() sal_Bool OResultSet::seekRow( eRowPosition pos, sal_Int32 nOffset ) { ResultSetEntryGuard aGuard( *this ); - if ( !m_pKeySet.isValid() ) + if ( !m_pKeySet.is() ) m_pStatement->getOwnConnection()->throwSQLException( STR_ILLEGAL_MOVEMENT, *this ); sal_Int32 nNumberOfRecords = m_aQuery.getRealRowCount(); @@ -1662,7 +1662,7 @@ sal_Int32 OResultSet::hashBookmark( const ::com::sun::star::uno::Any& bookmark ) sal_Int32 OResultSet::getCurrentCardNumber() { - if ( ( m_nRowPos == 0 ) || !m_pKeySet.isValid() ) + if ( ( m_nRowPos == 0 ) || !m_pKeySet.is() ) return 0; if (m_pKeySet->get().size() < m_nRowPos) return 0; diff --git a/connectivity/source/drivers/mozab/MResultSet.hxx b/connectivity/source/drivers/mozab/MResultSet.hxx index d089d827168e..e98a5f850006 100644 --- a/connectivity/source/drivers/mozab/MResultSet.hxx +++ b/connectivity/source/drivers/mozab/MResultSet.hxx @@ -244,7 +244,7 @@ protected: ::std::vector< ::rtl::OUString> m_aAttributeStrings; sal_Int32 m_nParamIndex; sal_Bool m_bIsAlwaysFalseQuery; - ::vos::ORef<OKeySet> m_pKeySet; + ::rtl::Reference<OKeySet> m_pKeySet; OSortIndex* m_pSortIndex; sal_Int32 m_nNewRow; //inserted row sal_Int32 m_nUpdatedRow; //updated row @@ -252,8 +252,8 @@ protected: sal_Int32 m_bIsReadOnly; inline void resetParameters() { m_nParamIndex = 0; } - ::vos::ORef<connectivity::OSQLColumns> m_xColumns; // this are the select columns - ::vos::ORef<connectivity::OSQLColumns> m_xParamColumns; + ::rtl::Reference<connectivity::OSQLColumns> m_xColumns; // this are the select columns + ::rtl::Reference<connectivity::OSQLColumns> m_xParamColumns; void parseParameter( const OSQLParseNode* pNode, rtl::OUString& rMatchString ); void fillRowData() throw( ::com::sun::star::sdbc::SQLException ); @@ -301,7 +301,7 @@ public: void setParameterRow(const OValueRow& _rParaRow) { m_aParameterRow = _rParaRow; } - void setParameterColumns(const ::vos::ORef<connectivity::OSQLColumns>& _xParamColumns) + void setParameterColumns(const ::rtl::Reference<connectivity::OSQLColumns>& _xParamColumns) { m_xParamColumns = _xParamColumns; } void setBindingRow(const OValueRow& _aRow) @@ -319,7 +319,7 @@ public: static void setBoundedColumns( const OValueRow& _rRow, - const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns, + const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns, const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess>& _xNames, sal_Bool _bSetColumnMapping, const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData>& _xMetaData, @@ -331,7 +331,7 @@ public: private: inline void impl_ensureKeySet() { - if ( !m_pKeySet.isValid() ) + if ( !m_pKeySet.is() ) m_pKeySet = new OKeySet(); } diff --git a/connectivity/source/drivers/mozab/MResultSetMetaData.hxx b/connectivity/source/drivers/mozab/MResultSetMetaData.hxx index 50ff8e6c6ffe..1e2a7c2ff139 100644 --- a/connectivity/source/drivers/mozab/MResultSetMetaData.hxx +++ b/connectivity/source/drivers/mozab/MResultSetMetaData.hxx @@ -30,7 +30,7 @@ #include <com/sun/star/sdbc/XResultSetMetaData.hpp> #include <cppuhelper/implbase1.hxx> #include <vector> -#include <vos/ref.hxx> +#include <rtl/ref.hxx> #include "MConnection.hxx" #include "MTable.hxx" @@ -46,7 +46,7 @@ namespace connectivity class OResultSetMetaData : public OResultSetMetaData_BASE { ::rtl::OUString m_aTableName; - ::vos::ORef<connectivity::OSQLColumns> m_xColumns; + ::rtl::Reference<connectivity::OSQLColumns> m_xColumns; OTable* m_pTable; sal_Bool m_bReadOnly; @@ -55,7 +55,7 @@ namespace connectivity public: // ein Konstruktor, der fuer das Returnen des Objektes benoetigt wird: // OResultSetMetaData(OConnection* _pConnection) : m_pConnection(_pConnection){} - OResultSetMetaData(const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns, + OResultSetMetaData(const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns, const ::rtl::OUString& _aTableName,OTable* _pTable,sal_Bool aReadOnly ) :m_aTableName(_aTableName) diff --git a/connectivity/source/drivers/mozab/MStatement.cxx b/connectivity/source/drivers/mozab/MStatement.cxx index 79758c1f613e..709676b21966 100644 --- a/connectivity/source/drivers/mozab/MStatement.cxx +++ b/connectivity/source/drivers/mozab/MStatement.cxx @@ -147,14 +147,14 @@ void OCommonStatement::createTable( ) throw ( SQLException, RuntimeException ) { if(m_pParseTree) { - ::vos::ORef<connectivity::OSQLColumns> xCreateColumn; + ::rtl::Reference<connectivity::OSQLColumns> xCreateColumn; if (m_pSQLIterator->getStatementType() == SQL_STATEMENT_CREATE_TABLE) { const OSQLTables& xTabs = m_pSQLIterator->getTables(); OSL_ENSURE( !xTabs.empty(), "Need a Table"); ::rtl::OUString ouTableName=xTabs.begin()->first; xCreateColumn = m_pSQLIterator->getCreateColumns(); - OSL_ENSURE(xCreateColumn.isValid(), "Need the Columns!!"); + OSL_ENSURE(xCreateColumn.is(), "Need the Columns!!"); const OColumnAlias& aColumnAlias = m_pConnection->getColumnAlias(); @@ -491,7 +491,7 @@ void OCommonStatement::createColumnMapping() size_t i; // initialize the column index map (mapping select columns to table columns) - ::vos::ORef<connectivity::OSQLColumns> xColumns = m_pSQLIterator->getSelectColumns(); + ::rtl::Reference<connectivity::OSQLColumns> xColumns = m_pSQLIterator->getSelectColumns(); m_aColMapping.resize(xColumns->get().size() + 1); for (i=0; i<m_aColMapping.size(); ++i) m_aColMapping[i] = i; diff --git a/connectivity/source/drivers/mozab/makefile.mk b/connectivity/source/drivers/mozab/makefile.mk index b1e12fde6f8a..bb3878d352c0 100644 --- a/connectivity/source/drivers/mozab/makefile.mk +++ b/connectivity/source/drivers/mozab/makefile.mk @@ -154,6 +154,7 @@ SHL2STDLIBS=\ $(CPPUHELPERLIB) \ $(VOSLIB) \ $(SALLIB) \ + $(SALHELPERLIB) \ $(DBTOOLSLIB) \ $(COMPHELPERLIB) \ $(MOZ_LIB_XPCOM) diff --git a/connectivity/source/drivers/odbc/makefile.mk b/connectivity/source/drivers/odbc/makefile.mk index 508cbfb6df63..a13837224b93 100644 --- a/connectivity/source/drivers/odbc/makefile.mk +++ b/connectivity/source/drivers/odbc/makefile.mk @@ -64,7 +64,8 @@ SHL1STDLIBS=\ $(ODBCBASELIB) \ $(CPPUHELPERLIB) \ $(CPPULIB) \ - $(SALLIB) + $(SALLIB) \ + $(SALHELPERLIB) SHL1IMPLIB= i$(ODBC_TARGET) diff --git a/connectivity/source/drivers/odbcbase/makefile.mk b/connectivity/source/drivers/odbcbase/makefile.mk index 798517c8f948..0f83addab970 100644 --- a/connectivity/source/drivers/odbcbase/makefile.mk +++ b/connectivity/source/drivers/odbcbase/makefile.mk @@ -67,7 +67,8 @@ SHL1STDLIBS=\ $(CPPUHELPERLIB) \ $(CPPULIB) \ $(VOSLIB) \ - $(SALLIB) + $(SALLIB) \ + $(SALHELPERLIB) SHL1DEPN= SHL1IMPLIB= i$(ODBC2_TARGET) diff --git a/connectivity/source/inc/FDatabaseMetaDataResultSet.hxx b/connectivity/source/inc/FDatabaseMetaDataResultSet.hxx index 134e7e5dfca1..a941d2046eee 100644 --- a/connectivity/source/inc/FDatabaseMetaDataResultSet.hxx +++ b/connectivity/source/inc/FDatabaseMetaDataResultSet.hxx @@ -46,7 +46,7 @@ #include "connectivity/FValue.hxx" #include "connectivity/dbtoolsdllapi.hxx" #include <comphelper/broadcasthelper.hxx> -#include <vos/refernce.hxx> +#include <salhelper/simplereferenceobject.hxx> namespace connectivity { diff --git a/connectivity/source/inc/TSortIndex.hxx b/connectivity/source/inc/TSortIndex.hxx index 51a978121ca1..65e8b33371e7 100644 --- a/connectivity/source/inc/TSortIndex.hxx +++ b/connectivity/source/inc/TSortIndex.hxx @@ -98,7 +98,7 @@ namespace connectivity CreateKeySet creates the keyset which vaalues could be used to travel in your table/result The returned keyset is frozen. */ - ::vos::ORef<OKeySet> CreateKeySet(); + ::rtl::Reference<OKeySet> CreateKeySet(); diff --git a/connectivity/source/inc/adabas/BConnection.hxx b/connectivity/source/inc/adabas/BConnection.hxx index 678eb2e61049..16b88305f0b7 100644 --- a/connectivity/source/inc/adabas/BConnection.hxx +++ b/connectivity/source/inc/adabas/BConnection.hxx @@ -31,7 +31,7 @@ #include "odbc/OConnection.hxx" #include <com/sun/star/sdbcx/XTablesSupplier.hpp> #include <cppuhelper/weakref.hxx> -#include <vos/ref.hxx> +#include <rtl/ref.hxx> namespace connectivity { @@ -70,7 +70,7 @@ namespace connectivity virtual sal_Int64 SAL_CALL getSomething( const ::com::sun::star::uno::Sequence< sal_Int8 >& aIdentifier ) throw (::com::sun::star::uno::RuntimeException); static ::com::sun::star::uno::Sequence< sal_Int8 > getUnoTunnelImplementationId(); - ::vos::ORef<OSQLColumns> createSelectColumns(const ::rtl::OUString& _rSql); + ::rtl::Reference<OSQLColumns> createSelectColumns(const ::rtl::OUString& _rSql); }; } } diff --git a/connectivity/source/inc/adabas/BPreparedStatement.hxx b/connectivity/source/inc/adabas/BPreparedStatement.hxx index a5cfac1666e4..4ccfc813bdfc 100644 --- a/connectivity/source/inc/adabas/BPreparedStatement.hxx +++ b/connectivity/source/inc/adabas/BPreparedStatement.hxx @@ -36,7 +36,7 @@ namespace connectivity { class OAdabasPreparedStatement : public ::connectivity::odbc::OPreparedStatement { - ::vos::ORef<OSQLColumns> m_aSelectColumns; + ::rtl::Reference<OSQLColumns> m_aSelectColumns; protected: virtual odbc::OResultSet* createResulSet(); virtual void setResultSetConcurrency(sal_Int32 _par0) ; diff --git a/connectivity/source/inc/adabas/BResultSet.hxx b/connectivity/source/inc/adabas/BResultSet.hxx index 46dbf5684484..51625c5777ea 100644 --- a/connectivity/source/inc/adabas/BResultSet.hxx +++ b/connectivity/source/inc/adabas/BResultSet.hxx @@ -35,9 +35,9 @@ namespace connectivity { class OAdabasResultSet : public ::connectivity::odbc::OResultSet { - ::vos::ORef<OSQLColumns> m_aSelectColumns; + ::rtl::Reference<OSQLColumns> m_aSelectColumns; public: - OAdabasResultSet(SQLHANDLE _pStatementHandle,::connectivity::odbc::OStatement_Base* pStmt,const ::vos::ORef<OSQLColumns>& _rSelectColumns) + OAdabasResultSet(SQLHANDLE _pStatementHandle,::connectivity::odbc::OStatement_Base* pStmt,const ::rtl::Reference<OSQLColumns>& _rSelectColumns) : ::connectivity::odbc::OResultSet( _pStatementHandle,pStmt) ,m_aSelectColumns(_rSelectColumns) {} diff --git a/connectivity/source/inc/adabas/BResultSetMetaData.hxx b/connectivity/source/inc/adabas/BResultSetMetaData.hxx index 1cbb328bcf1e..882256a2fe9c 100644 --- a/connectivity/source/inc/adabas/BResultSetMetaData.hxx +++ b/connectivity/source/inc/adabas/BResultSetMetaData.hxx @@ -28,7 +28,7 @@ #define CONNECTIVITY_ADABAS_RESULTSETMETADATA_HXX #include "odbc/OResultSetMetaData.hxx" -#include <vos/ref.hxx> +#include <rtl/ref.hxx> namespace connectivity { @@ -41,10 +41,10 @@ namespace connectivity typedef odbc::OResultSetMetaData OAdabasResultSetMetaData_BASE; class OAdabasResultSetMetaData : public OAdabasResultSetMetaData_BASE { - ::vos::ORef<OSQLColumns> m_aSelectColumns; + ::rtl::Reference<OSQLColumns> m_aSelectColumns; public: // ein Konstruktor, der fuer das Returnen des Objektes benoetigt wird: - OAdabasResultSetMetaData(odbc::OConnection* _pConnection, SQLHANDLE _pStmt ,const ::vos::ORef<OSQLColumns>& _rSelectColumns); + OAdabasResultSetMetaData(odbc::OConnection* _pConnection, SQLHANDLE _pStmt ,const ::rtl::Reference<OSQLColumns>& _rSelectColumns); virtual ~OAdabasResultSetMetaData(); virtual sal_Int32 SAL_CALL getColumnType( sal_Int32 column ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException); diff --git a/connectivity/source/inc/adabas/BStatement.hxx b/connectivity/source/inc/adabas/BStatement.hxx index 3e30639cd4e1..ae2834a3ee0d 100644 --- a/connectivity/source/inc/adabas/BStatement.hxx +++ b/connectivity/source/inc/adabas/BStatement.hxx @@ -30,7 +30,7 @@ #include "odbc/OStatement.hxx" #include "adabas/BConnection.hxx" #include "connectivity/CommonTools.hxx" -#include <vos/ref.hxx> +#include <rtl/ref.hxx> namespace connectivity { @@ -39,7 +39,7 @@ namespace connectivity class OAdabasStatement : public ::connectivity::odbc::OStatement { OAdabasConnection* m_pOwnConnection; - ::vos::ORef<OSQLColumns> m_aSelectColumns; + ::rtl::Reference<OSQLColumns> m_aSelectColumns; protected: virtual odbc::OResultSet* createResulSet(); virtual void setResultSetConcurrency(sal_Int32 _par0); diff --git a/connectivity/source/inc/dbase/DIndexPage.hxx b/connectivity/source/inc/dbase/DIndexPage.hxx index bd161c334760..87dc00dca500 100644 --- a/connectivity/source/inc/dbase/DIndexPage.hxx +++ b/connectivity/source/inc/dbase/DIndexPage.hxx @@ -28,7 +28,7 @@ #ifndef _CONNECTIVITY_DBASE_INDEXPAGE_HXX_ #define _CONNECTIVITY_DBASE_INDEXPAGE_HXX_ -#include <vos/ref.hxx> +#include <rtl/ref.hxx> #include <tools/stream.hxx> #ifndef _VECTOR_ #include <vector> diff --git a/connectivity/source/inc/file/FPreparedStatement.hxx b/connectivity/source/inc/file/FPreparedStatement.hxx index 9528ca16a508..b0109cecc917 100644 --- a/connectivity/source/inc/file/FPreparedStatement.hxx +++ b/connectivity/source/inc/file/FPreparedStatement.hxx @@ -59,7 +59,7 @@ namespace connectivity ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSetMetaData> m_xMetaData; OResultSet* m_pResultSet; - ::vos::ORef<connectivity::OSQLColumns> m_xParamColumns; // the parameter columns + ::rtl::Reference<connectivity::OSQLColumns> m_xParamColumns; // the parameter columns // factory method for resultset's virtual OResultSet* createResultSet(); diff --git a/connectivity/source/inc/file/FResultSet.hxx b/connectivity/source/inc/file/FResultSet.hxx index 778fb6dc0808..699e34b796e2 100644 --- a/connectivity/source/inc/file/FResultSet.hxx +++ b/connectivity/source/inc/file/FResultSet.hxx @@ -101,14 +101,14 @@ namespace connectivity // ::std::vector<TInt2IntMap::iterator> m_aBookmarksPositions;// vector of iterators to bookmark map, the order is the logical position OSkipDeletedSet m_aSkipDeletedSet; - ::vos::ORef<OKeySet> m_pFileSet; + ::rtl::Reference<OKeySet> m_pFileSet; OKeySet::Vector::iterator m_aFileSetIter; OSortIndex* m_pSortIndex; - ::vos::ORef<connectivity::OSQLColumns> m_xColumns; // this are the select columns - ::vos::ORef<connectivity::OSQLColumns> m_xParamColumns; + ::rtl::Reference<connectivity::OSQLColumns> m_xColumns; // this are the select columns + ::rtl::Reference<connectivity::OSQLColumns> m_xParamColumns; OFileTable* m_pTable; connectivity::OSQLParseNode* m_pParseTree; @@ -290,7 +290,7 @@ namespace connectivity inline sal_Int32 getRowCountResult() const { return m_nRowCountResult; } inline void setParameterRow(const OValueRefRow& _rParaRow) { m_aParameterRow = _rParaRow; } inline void setEvaluationRow(const OValueRefRow& _aRow) { m_aEvaluateRow = _aRow; } - inline void setParameterColumns(const ::vos::ORef<connectivity::OSQLColumns>& _xParamColumns) { m_xParamColumns = _xParamColumns; } + inline void setParameterColumns(const ::rtl::Reference<connectivity::OSQLColumns>& _xParamColumns) { m_xParamColumns = _xParamColumns; } inline void setAssignValues(const ORefAssignValues& _aAssignValues) { m_aAssignValues = _aAssignValues; } inline void setBindingRow(const OValueRefRow& _aRow) { m_aRow = _aRow; } inline void setSelectRow(const OValueRefRow& _rRow) @@ -310,7 +310,7 @@ namespace connectivity void clear(); static void setBoundedColumns(const OValueRefRow& _rRow, const OValueRefRow& _rSelectRow, - const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns, + const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns, const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess>& _xNames, sal_Bool _bSetColumnMapping, const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData>& _xMetaData, diff --git a/connectivity/source/inc/file/FResultSetMetaData.hxx b/connectivity/source/inc/file/FResultSetMetaData.hxx index 60bd3b179709..1e97418c2230 100644 --- a/connectivity/source/inc/file/FResultSetMetaData.hxx +++ b/connectivity/source/inc/file/FResultSetMetaData.hxx @@ -31,7 +31,7 @@ #include <com/sun/star/sdbc/XResultSetMetaData.hpp> #include <cppuhelper/implbase1.hxx> #include "connectivity/CommonTools.hxx" -#include <vos/ref.hxx> +#include <rtl/ref.hxx> #include "file/filedllapi.hxx" namespace connectivity @@ -48,7 +48,7 @@ namespace connectivity public OResultSetMetaData_BASE { ::rtl::OUString m_aTableName; - ::vos::ORef<connectivity::OSQLColumns> m_xColumns; + ::rtl::Reference<connectivity::OSQLColumns> m_xColumns; OFileTable* m_pTable; void checkColumnIndex(sal_Int32 column) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException); @@ -56,7 +56,7 @@ namespace connectivity virtual ~OResultSetMetaData(); public: // ein Konstruktor, der fuer das Returnen des Objektes benoetigt wird: - OResultSetMetaData(const ::vos::ORef<connectivity::OSQLColumns>& _rxColumns,const ::rtl::OUString& _aTableName,OFileTable* _pTable); + OResultSetMetaData(const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns,const ::rtl::OUString& _aTableName,OFileTable* _pTable); /// Avoid ambigous cast error from the compiler. inline operator ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSetMetaData > () throw() diff --git a/connectivity/source/inc/file/FTable.hxx b/connectivity/source/inc/file/FTable.hxx index 775704f4ff18..0380d17fa145 100644 --- a/connectivity/source/inc/file/FTable.hxx +++ b/connectivity/source/inc/file/FTable.hxx @@ -48,7 +48,7 @@ namespace connectivity protected: OConnection* m_pConnection; SvStream* m_pFileStream; - ::vos::ORef<OSQLColumns> m_aColumns; + ::rtl::Reference<OSQLColumns> m_aColumns; sal_Int32 m_nFilePos; // aktuelle IResultSetHelper::Movement sal_uInt8* m_pBuffer; sal_uInt16 m_nBufferSize; // Groesse des ReadBuffer, wenn pBuffer != NULL @@ -84,7 +84,7 @@ namespace connectivity virtual sal_Bool seekRow(IResultSetHelper::Movement eCursorPosition, sal_Int32 nOffset, sal_Int32& nCurPos) = 0; virtual sal_Bool fetchRow(OValueRefRow& _rRow,const OSQLColumns& _rCols, sal_Bool _bUseTableDefs,sal_Bool bRetrieveData) = 0; - ::vos::ORef<OSQLColumns> getTableColumns() const {return m_aColumns;} + ::rtl::Reference<OSQLColumns> getTableColumns() const {return m_aColumns;} virtual BOOL InsertRow(OValueRefVector& rRow, BOOL bFlush,const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess>& _xCols); virtual BOOL DeleteRow(const OSQLColumns& _rCols); virtual BOOL UpdateRow(OValueRefVector& rRow, OValueRefRow& pOrgRow,const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess>& _xCols); diff --git a/connectivity/source/inc/file/fanalyzer.hxx b/connectivity/source/inc/file/fanalyzer.hxx index c882b760765a..010cd08138ce 100644 --- a/connectivity/source/inc/file/fanalyzer.hxx +++ b/connectivity/source/inc/file/fanalyzer.hxx @@ -39,11 +39,11 @@ namespace connectivity class OOO_DLLPUBLIC_FILE OSQLAnalyzer { typedef ::std::list<OEvaluateSet*> OEvaluateSetList; - typedef ::std::pair< ::vos::ORef<OPredicateCompiler>,::vos::ORef<OPredicateInterpreter> > TPredicates; + typedef ::std::pair< ::rtl::Reference<OPredicateCompiler>,::rtl::Reference<OPredicateInterpreter> > TPredicates; ::std::vector< TPredicates > m_aSelectionEvaluations; - ::vos::ORef<OPredicateCompiler> m_aCompiler; - ::vos::ORef<OPredicateInterpreter> m_aInterpreter; + ::rtl::Reference<OPredicateCompiler> m_aCompiler; + ::rtl::Reference<OPredicateInterpreter> m_aInterpreter; OConnection* m_pConnection; mutable sal_Bool m_bHasSelectionCode; @@ -64,7 +64,7 @@ namespace connectivity { } OConnection* getConnection() const { return m_pConnection; } - void describeParam(::vos::ORef<OSQLColumns> rParameterColumns); // genauere Beschreibung der Parameter + void describeParam(::rtl::Reference<OSQLColumns> rParameterColumns); // genauere Beschreibung der Parameter ::std::vector<sal_Int32>* bindEvaluationRow(OValueRefRow& _pRow); // Anbinden einer Ergebniszeile an die Restrictions /** bind the select columns if they contain a function which needs a row value @param _pRow the result row diff --git a/connectivity/source/inc/file/fcode.hxx b/connectivity/source/inc/file/fcode.hxx index 7a2125206549..a13069264c77 100644 --- a/connectivity/source/inc/file/fcode.hxx +++ b/connectivity/source/inc/file/fcode.hxx @@ -130,7 +130,7 @@ namespace connectivity { public: OOperandParam(connectivity::OSQLParseNode* pNode, sal_Int32 _nPos); - void describe(const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet>& _xColumn, ::vos::ORef<connectivity::OSQLColumns> _xParamColumns); + void describe(const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet>& _xColumn, ::rtl::Reference<connectivity::OSQLColumns> _xParamColumns); TYPEINFO(); }; diff --git a/connectivity/source/inc/file/fcomp.hxx b/connectivity/source/inc/file/fcomp.hxx index b46d24ddd089..6b8778de6082 100644 --- a/connectivity/source/inc/file/fcomp.hxx +++ b/connectivity/source/inc/file/fcomp.hxx @@ -43,7 +43,7 @@ namespace connectivity class OSQLAnalyzer; typedef::std::vector<OCode*> OCodeList; - class OPredicateCompiler : public ::vos::OReference + class OPredicateCompiler : public ::salhelper::SimpleReferenceObject { friend class OPredicateInterpreter; friend class OSQLAnalyzer; @@ -90,13 +90,13 @@ namespace connectivity class OPredicateInterpreter : - public ::vos::OReference + public ::salhelper::SimpleReferenceObject { OCodeStack m_aStack; - ::vos::ORef<OPredicateCompiler> m_rCompiler; + ::rtl::Reference<OPredicateCompiler> m_rCompiler; public: - OPredicateInterpreter(const ::vos::ORef<OPredicateCompiler>& rComp) : m_rCompiler(rComp){} + OPredicateInterpreter(const ::rtl::Reference<OPredicateCompiler>& rComp) : m_rCompiler(rComp){} virtual ~OPredicateInterpreter(); sal_Bool evaluate(OCodeList& rCodeList); diff --git a/connectivity/source/parse/PColumn.cxx b/connectivity/source/parse/PColumn.cxx index a34749dd0c27..25eddfd52f47 100644 --- a/connectivity/source/parse/PColumn.cxx +++ b/connectivity/source/parse/PColumn.cxx @@ -99,11 +99,11 @@ OParseColumn::OParseColumn( const ::rtl::OUString& _Name, } // ------------------------------------------------------------------------- -::vos::ORef< OSQLColumns > OParseColumn::createColumnsForResultSet( const Reference< XResultSetMetaData >& _rxResMetaData, +::rtl::Reference< OSQLColumns > OParseColumn::createColumnsForResultSet( const Reference< XResultSetMetaData >& _rxResMetaData, const Reference< XDatabaseMetaData >& _rxDBMetaData,const Reference< XNameAccess>& i_xQueryColumns ) { sal_Int32 nColumnCount = _rxResMetaData->getColumnCount(); - ::vos::ORef< OSQLColumns > aReturn( new OSQLColumns ); aReturn->get().reserve( nColumnCount ); + ::rtl::Reference< OSQLColumns > aReturn( new OSQLColumns ); aReturn->get().reserve( nColumnCount ); StringMap aColumnMap; for ( sal_Int32 i = 1; i <= nColumnCount; ++i ) diff --git a/connectivity/source/parse/sqliterator.cxx b/connectivity/source/parse/sqliterator.cxx index 38f47d4e3b8b..ef07f908836a 100644 --- a/connectivity/source/parse/sqliterator.cxx +++ b/connectivity/source/parse/sqliterator.cxx @@ -329,7 +329,7 @@ void OSQLParseTreeIterator::impl_getQueryParameterColumns( const OSQLTable& _rQu // parameters not to be included in the traversal return; - ::vos::ORef< OSQLColumns > pSubQueryParameterColumns( new OSQLColumns() ); + ::rtl::Reference< OSQLColumns > pSubQueryParameterColumns( new OSQLColumns() ); // get the command and the EscapeProcessing properties from the sub query ::rtl::OUString sSubQueryCommand; @@ -1689,7 +1689,7 @@ OSQLTable OSQLParseTreeIterator::impl_createTableObject( const ::rtl::OUString& return aReturnTable; } //----------------------------------------------------------------------------- -void OSQLParseTreeIterator::appendColumns(::vos::ORef<OSQLColumns>& _rColumns,const ::rtl::OUString& _rTableAlias,const OSQLTable& _rTable) +void OSQLParseTreeIterator::appendColumns(::rtl::Reference<OSQLColumns>& _rColumns,const ::rtl::OUString& _rTableAlias,const OSQLTable& _rTable) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "parse", "Ocke.Janssen@sun.com", "OSQLParseTreeIterator::appendColumns" ); @@ -1733,7 +1733,7 @@ void OSQLParseTreeIterator::appendColumns(::vos::ORef<OSQLColumns>& _rColumns,co } } //----------------------------------------------------------------------------- -void OSQLParseTreeIterator::setSelectColumnName(::vos::ORef<OSQLColumns>& _rColumns,const ::rtl::OUString & rColumnName,const ::rtl::OUString & rColumnAlias, const ::rtl::OUString & rTableRange,sal_Bool bFkt,sal_Int32 _nType,sal_Bool bAggFkt) +void OSQLParseTreeIterator::setSelectColumnName(::rtl::Reference<OSQLColumns>& _rColumns,const ::rtl::OUString & rColumnName,const ::rtl::OUString & rColumnAlias, const ::rtl::OUString & rTableRange,sal_Bool bFkt,sal_Int32 _nType,sal_Bool bAggFkt) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "parse", "Ocke.Janssen@sun.com", "OSQLParseTreeIterator::setSelectColumnName" ); if(rColumnName.toChar() == '*' && !rTableRange.getLength()) |