summaryrefslogtreecommitdiff
path: root/connectivity/source/drivers/ado/ATables.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'connectivity/source/drivers/ado/ATables.cxx')
-rw-r--r--connectivity/source/drivers/ado/ATables.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/connectivity/source/drivers/ado/ATables.cxx b/connectivity/source/drivers/ado/ATables.cxx
index 9ce87634e425..48a82ceee2d5 100644
--- a/connectivity/source/drivers/ado/ATables.cxx
+++ b/connectivity/source/drivers/ado/ATables.cxx
@@ -44,7 +44,7 @@ using namespace com::sun::star::beans;
using namespace com::sun::star::sdbc;
using namespace com::sun::star::container;
-sdbcx::ObjectType OTables::createObject(const OUString& _rName)
+css::uno::Reference< css::beans::XPropertySet > OTables::createObject(const OUString& _rName)
{
OSL_ENSURE(m_aCollection.IsValid(),"Collection isn't valid");
return new OAdoTable(this,isCaseSensitive(),m_pCatalog,m_aCollection.GetItem(_rName));
@@ -63,15 +63,15 @@ Reference< XPropertySet > OTables::createDescriptor()
}
// XAppend
-sdbcx::ObjectType OTables::appendObject( const OUString&, const Reference< XPropertySet >& descriptor )
+css::uno::Reference< css::beans::XPropertySet > OTables::appendObject( const OUString&, const Reference< XPropertySet >& descriptor )
{
- OAdoTable* pTable = getUnoTunnelImplementation<OAdoTable>( descriptor );
+ OAdoTable* pTable = dynamic_cast<OAdoTable*>( descriptor.get() );
if ( pTable == nullptr )
m_pCatalog->getConnection()->throwGenericSQLException( STR_INVALID_TABLE_DESCRIPTOR_ERROR,static_cast<XTypeProvider*>(this) );
OSL_ENSURE(m_aCollection.IsValid(),"Collection isn't valid");
if(!m_aCollection.Append(pTable->getImpl()))
- ADOS::ThrowException(*m_pCatalog->getConnection()->getConnection(),static_cast<XTypeProvider*>(this));
+ ADOS::ThrowException(m_pCatalog->getConnection()->getConnection(),static_cast<XTypeProvider*>(this));
m_aCollection.Refresh();
return new OAdoTable(this,isCaseSensitive(),m_pCatalog,pTable->getImpl());
@@ -82,7 +82,7 @@ void OTables::dropObject(sal_Int32 /*_nPos*/,const OUString& _sElementName)
{
OSL_ENSURE(m_aCollection.IsValid(),"Collection isn't valid");
if ( !m_aCollection.Delete(_sElementName) )
- ADOS::ThrowException(*m_pCatalog->getConnection()->getConnection(),static_cast<XTypeProvider*>(this));
+ ADOS::ThrowException(m_pCatalog->getConnection()->getConnection(),static_cast<XTypeProvider*>(this));
}
void OTables::appendNew(const OUString& _rsNewTable)
@@ -93,10 +93,10 @@ void OTables::appendNew(const OUString& _rsNewTable)
insertElement(_rsNewTable,nullptr);
// notify our container listeners
- ContainerEvent aEvent(static_cast<XContainer*>(this), makeAny(_rsNewTable), Any(), Any());
- OInterfaceIteratorHelper2 aListenerLoop(m_aContainerListeners);
+ ContainerEvent aEvent(static_cast<XContainer*>(this), Any(_rsNewTable), Any(), Any());
+ OInterfaceIteratorHelper3 aListenerLoop(m_aContainerListeners);
while (aListenerLoop.hasMoreElements())
- static_cast<XContainerListener*>(aListenerLoop.next())->elementInserted(aEvent);
+ aListenerLoop.next()->elementInserted(aEvent);
}