/** throws an SQLException saying that no Mac OS installation was found
*/ void throwNoMacOSException()
{
::connectivity::SharedResources aResources; const OUString sError( aResources.getResourceString(
STR_NO_MAC_OS_FOUND
) );
throwGenericSQLException( sError );
}
if ( !_rFunction )
{ // did not find the symbol
SAL_WARN( "connectivity.macab", "lcl_getFunctionFromModuleOrUnload: could not find the symbol " << _pAsciiSymbolName );
osl_unloadModule( _rModule );
_rModule = nullptr;
}
}
}
}
// when driver will be destroyed so all our connections have to be destroyed as well for (auto& rxConnection : m_xConnections)
{
Reference< XComponent > xComp(rxConnection.get(), UNO_QUERY); if (xComp.is())
xComp->dispose();
}
m_xConnections.clear();
Sequence< OUString > SAL_CALL MacabDriver::getSupportedServiceNames( )
{ // which service is supported // for more information @see com.sun.star.sdbc.Driver return { "com.sun.star.sdbc.Driver" };
}
// create a new connection with the given properties and append it to our vector
MacabConnection* pConnection = m_aImplModule.createConnection( this );
SAL_WARN_IF( !pConnection, "connectivity.macab", "MacabDriver::connect: no connection has been created by the factory!" );
// by definition, the factory function returned an object which was acquired once
Reference< XConnection > xConnection = pConnection;
pConnection->release();
// late constructor call which can throw exception and allows a correct dtor call when so
pConnection->construct( url, info );
// remember it
m_xConnections.push_back( WeakReferenceHelper( *pConnection ) );
if ( !m_aImplModule.isMacOSPresent() ) returnfalse;
// here we have to look whether we support this URL format return url == "sdbc:address:macab";
}
Sequence< DriverPropertyInfo > SAL_CALL MacabDriver::getPropertyInfo( const OUString&, const Sequence< PropertyValue >& )
{ // if you have something special to say, return it here :-) return Sequence< DriverPropertyInfo >();
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.