summaryrefslogtreecommitdiff
path: root/connectivity/source/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'connectivity/source/drivers')
-rw-r--r--connectivity/source/drivers/file/FStatement.cxx3
-rw-r--r--connectivity/source/drivers/flat/ETable.cxx2
-rw-r--r--connectivity/source/drivers/jdbc/JConnection.cxx2
-rw-r--r--connectivity/source/drivers/kab/KDriver.hxx5
-rw-r--r--connectivity/source/drivers/kab/KStatement.cxx2
-rw-r--r--connectivity/source/drivers/mork/MStatement.cxx3
-rw-r--r--connectivity/source/drivers/odbcbase/OPreparedStatement.cxx3
7 files changed, 12 insertions, 8 deletions
diff --git a/connectivity/source/drivers/file/FStatement.cxx b/connectivity/source/drivers/file/FStatement.cxx
index c606bbfe9dfc..49c604664d9b 100644
--- a/connectivity/source/drivers/file/FStatement.cxx
+++ b/connectivity/source/drivers/file/FStatement.cxx
@@ -29,6 +29,7 @@
#include <com/sun/star/sdbc/ResultSetType.hpp>
#include <com/sun/star/sdbc/FetchDirection.hpp>
#include <com/sun/star/lang/DisposedException.hpp>
+#include <comphelper/processfactory.hxx>
#include <comphelper/sequence.hxx>
#include <cppuhelper/typeprovider.hxx>
#include "connectivity/dbexception.hxx"
@@ -57,7 +58,7 @@ OStatement_Base::OStatement_Base(OConnection* _pConnection )
:OStatement_BASE(m_aMutex)
,::comphelper::OPropertyContainer(OStatement_BASE::rBHelper)
,m_xDBMetaData(_pConnection->getMetaData())
- ,m_aParser(_pConnection->getDriver()->getFactory())
+ ,m_aParser( comphelper::getComponentContext(_pConnection->getDriver()->getFactory()) )
,m_aSQLIterator( _pConnection, _pConnection->createCatalog()->getTables(), m_aParser, NULL )
,m_pConnection(_pConnection)
,m_pParseTree(NULL)
diff --git a/connectivity/source/drivers/flat/ETable.cxx b/connectivity/source/drivers/flat/ETable.cxx
index 110f40195be4..0d57cb18b971 100644
--- a/connectivity/source/drivers/flat/ETable.cxx
+++ b/connectivity/source/drivers/flat/ETable.cxx
@@ -109,7 +109,7 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale)
m_aScales.assign(nFieldCount+1,-1);
const sal_Bool bCase = m_pConnection->getMetaData()->supportsMixedCaseQuotedIdentifiers();
- CharClass aCharClass(pConnection->getDriver()->getFactory(),_aLocale);
+ CharClass aCharClass( comphelper::getComponentContext(pConnection->getDriver()->getFactory()), _aLocale);
// read description
const sal_Unicode cDecimalDelimiter = pConnection->getDecimalDelimiter();
const sal_Unicode cThousandDelimiter = pConnection->getThousandDelimiter();
diff --git a/connectivity/source/drivers/jdbc/JConnection.cxx b/connectivity/source/drivers/jdbc/JConnection.cxx
index 6921c0d96050..a814c1b6665d 100644
--- a/connectivity/source/drivers/jdbc/JConnection.cxx
+++ b/connectivity/source/drivers/jdbc/JConnection.cxx
@@ -469,7 +469,7 @@ Reference< XStatement > SAL_CALL java_sql_Connection::createStatement( ) throw(
{
try
{
- OSQLParser aParser( m_pDriver->getContext().getLegacyServiceFactory() );
+ OSQLParser aParser( m_pDriver->getContext().getUNOContext() );
::rtl::OUString sErrorMessage;
::rtl::OUString sNewSql;
OSQLParseNode* pNode = aParser.parseTree(sErrorMessage,_sSQL);
diff --git a/connectivity/source/drivers/kab/KDriver.hxx b/connectivity/source/drivers/kab/KDriver.hxx
index b51058151279..1243f7425185 100644
--- a/connectivity/source/drivers/kab/KDriver.hxx
+++ b/connectivity/source/drivers/kab/KDriver.hxx
@@ -23,6 +23,7 @@
#include <com/sun/star/sdbc/XDriver.hpp>
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <com/sun/star/frame/XTerminateListener.hpp>
+#include <comphelper/processfactory.hxx>
#include <cppuhelper/compbase3.hxx>
#include <osl/module.h>
@@ -161,8 +162,8 @@ namespace connectivity
static ::rtl::OUString getImplementationName_Static( ) throw(::com::sun::star::uno::RuntimeException);
static ::com::sun::star::uno::Sequence< ::rtl::OUString > getSupportedServiceNames_Static( ) throw (::com::sun::star::uno::RuntimeException);
- const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >&
- getMSFactory() const { return m_xMSFactory; }
+ ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >
+ getComponentContext() const { return comphelper::getComponentContext(m_xMSFactory); }
/** returns the driver's implementation name (being pure ASCII) for reference in various places
*/
diff --git a/connectivity/source/drivers/kab/KStatement.cxx b/connectivity/source/drivers/kab/KStatement.cxx
index e898ee48f62f..a5babf0c2de3 100644
--- a/connectivity/source/drivers/kab/KStatement.cxx
+++ b/connectivity/source/drivers/kab/KStatement.cxx
@@ -62,7 +62,7 @@ IMPLEMENT_SERVICE_INFO(KabStatement, "com.sun.star.sdbc.drivers.KabStatement", "
KabCommonStatement::KabCommonStatement(KabConnection* _pConnection )
: KabCommonStatement_BASE(m_aMutex),
OPropertySetHelper(KabCommonStatement_BASE::rBHelper),
- m_aParser(_pConnection->getDriver()->getMSFactory()),
+ m_aParser(_pConnection->getDriver()->getComponentContext()),
m_aSQLIterator(_pConnection, _pConnection->createCatalog()->getTables(), m_aParser, NULL ),
m_pParseTree(NULL),
m_pConnection(_pConnection),
diff --git a/connectivity/source/drivers/mork/MStatement.cxx b/connectivity/source/drivers/mork/MStatement.cxx
index 342ac2add17b..2beacfecd95a 100644
--- a/connectivity/source/drivers/mork/MStatement.cxx
+++ b/connectivity/source/drivers/mork/MStatement.cxx
@@ -30,6 +30,7 @@
#include <com/sun/star/lang/DisposedException.hpp>
#include <comphelper/sequence.hxx>
#include <cppuhelper/typeprovider.hxx>
+#include <comphelper/processfactory.hxx>
#include <comphelper/extract.hxx>
#include <comphelper/types.hxx>
#include <connectivity/dbexception.hxx>
@@ -79,7 +80,7 @@ OCommonStatement::OCommonStatement(OConnection* _pConnection )
,OCommonStatement_SBASE((::cppu::OWeakObject*)_pConnection, this)
,m_pTable(NULL)
,m_pConnection(_pConnection)
- ,m_aParser(_pConnection->getDriver()->getFactory())
+ ,m_aParser( comphelper::getComponentContext(_pConnection->getDriver()->getFactory()) )
,m_pSQLIterator( new OSQLParseTreeIterator( _pConnection, _pConnection->createCatalog()->getTables(), m_aParser, NULL ) )
,rBHelper(OCommonStatement_IBASE::rBHelper)
{
diff --git a/connectivity/source/drivers/odbcbase/OPreparedStatement.cxx b/connectivity/source/drivers/odbcbase/OPreparedStatement.cxx
index 206369840936..f5c05b80f76f 100644
--- a/connectivity/source/drivers/odbcbase/OPreparedStatement.cxx
+++ b/connectivity/source/drivers/odbcbase/OPreparedStatement.cxx
@@ -30,6 +30,7 @@
#include "odbc/OResultSet.hxx"
#include "odbc/OResultSetMetaData.hxx"
#include <cppuhelper/typeprovider.hxx>
+#include <comphelper/processfactory.hxx>
#include <comphelper/sequence.hxx>
#include <com/sun/star/lang/DisposedException.hpp>
#include "connectivity/dbtools.hxx"
@@ -73,7 +74,7 @@ OPreparedStatement::OPreparedStatement( OConnection* _pConnection,const ::rtl::O
{
if(_pConnection->isParameterSubstitutionEnabled())
{
- OSQLParser aParser(_pConnection->getDriver()->getORB());
+ OSQLParser aParser( comphelper::getComponentContext(_pConnection->getDriver()->getORB()) );
::rtl::OUString sErrorMessage;
::rtl::OUString sNewSql;
::std::auto_ptr<OSQLParseNode> pNode( aParser.parseTree(sErrorMessage,sql) );