summaryrefslogtreecommitdiff
path: root/cppuhelper/source
diff options
context:
space:
mode:
Diffstat (limited to 'cppuhelper/source')
-rw-r--r--cppuhelper/source/component.cxx14
-rw-r--r--cppuhelper/source/exc_thrower.cxx23
-rw-r--r--cppuhelper/source/factory.cxx96
-rw-r--r--cppuhelper/source/implbase.cxx27
-rw-r--r--cppuhelper/source/interfacecontainer.cxx31
-rw-r--r--cppuhelper/source/propshlp.cxx143
-rw-r--r--cppuhelper/source/servicefactory.cxx8
-rw-r--r--cppuhelper/source/shlib.cxx38
-rw-r--r--cppuhelper/source/stdidlclass.cxx13
-rw-r--r--cppuhelper/source/typeprovider.cxx21
-rw-r--r--cppuhelper/source/weak.cxx46
11 files changed, 248 insertions, 212 deletions
diff --git a/cppuhelper/source/component.cxx b/cppuhelper/source/component.cxx
index 755b19c4a..eb761e517 100644
--- a/cppuhelper/source/component.cxx
+++ b/cppuhelper/source/component.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: component.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: dbo $ $Date: 2000-12-20 09:35:42 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -80,7 +80,7 @@ namespace cppu
// ----------------------------------------------------
// class OComponentHelper
// ----------------------------------------------------
-OComponentHelper::OComponentHelper( Mutex & rMutex )
+OComponentHelper::OComponentHelper( Mutex & rMutex ) SAL_THROW( () )
: rBHelper( rMutex )
{
}
@@ -88,7 +88,7 @@ OComponentHelper::OComponentHelper( Mutex & rMutex )
/**
* Call dispose if not previous called.
*/
-OComponentHelper::~OComponentHelper()
+OComponentHelper::~OComponentHelper() SAL_THROW( (RuntimeException) )
{
}
@@ -191,7 +191,8 @@ void OComponentHelper::dispose()
}
// XComponent
-void OComponentHelper::addEventListener(const Reference<XEventListener > & rxListener)
+void OComponentHelper::addEventListener(
+ const Reference<XEventListener > & rxListener )
throw(::com::sun::star::uno::RuntimeException)
{
if (rBHelper.bDisposed || rBHelper.bInDispose)
@@ -205,7 +206,8 @@ void OComponentHelper::addEventListener(const Reference<XEventListener > & rxLis
}
// XComponent
-void OComponentHelper::removeEventListener(const Reference<XEventListener > & rxListener)
+void OComponentHelper::removeEventListener(
+ const Reference<XEventListener > & rxListener )
throw(::com::sun::star::uno::RuntimeException)
{
rBHelper.removeListener( ::getCppuType( &rxListener ) , rxListener );
diff --git a/cppuhelper/source/exc_thrower.cxx b/cppuhelper/source/exc_thrower.cxx
index cae575596..6cc5fefab 100644
--- a/cppuhelper/source/exc_thrower.cxx
+++ b/cppuhelper/source/exc_thrower.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: exc_thrower.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: hr $ $Date: 2000-10-25 14:44:37 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -90,11 +90,13 @@ class XThrower : public ::com::sun::star::uno::XInterface
public:
// Methods
- virtual void SAL_CALL throwException( const ::com::sun::star::uno::Any& rExc ) throw(::com::sun::star::uno::Exception) = 0;
+ virtual void SAL_CALL throwException( const ::com::sun::star::uno::Any& rExc )
+ SAL_THROW( (::com::sun::star::uno::Exception) ) = 0;
};
static
const ::com::sun::star::uno::Type& getCppuType( const ::com::sun::star::uno::Reference< ::cppu::XThrower >* )
+ SAL_THROW( () )
{
static ::com::sun::star::uno::Type * pType_cppu_XThrower = 0;
@@ -164,15 +166,17 @@ struct ExceptionThrower : public uno_Interface
{
oslInterlockedCount nRef;
- inline ExceptionThrower();
+ inline ExceptionThrower() SAL_THROW( () );
};
+extern "C"
+{
//--------------------------------------------------------------------------------------------------
-void SAL_CALL ExceptionThrower_acquire( uno_Interface * pUnoI )
+static void SAL_CALL ExceptionThrower_acquire( uno_Interface * pUnoI ) SAL_THROW( () )
{
osl_incrementInterlockedCount( & SAL_STATIC_CAST( ExceptionThrower *, pUnoI )->nRef );
}
//--------------------------------------------------------------------------------------------------
-void SAL_CALL ExceptionThrower_release( uno_Interface * pUnoI )
+static void SAL_CALL ExceptionThrower_release( uno_Interface * pUnoI ) SAL_THROW( () )
{
if (! osl_decrementInterlockedCount( & SAL_STATIC_CAST( ExceptionThrower *, pUnoI )->nRef ))
delete SAL_STATIC_CAST( ExceptionThrower *, pUnoI );
@@ -181,6 +185,7 @@ void SAL_CALL ExceptionThrower_release( uno_Interface * pUnoI )
static void SAL_CALL ExceptionThrower_dispatch(
uno_Interface * pUnoI, const typelib_TypeDescription * pMemberType,
void * pReturn, void * pArgs[], uno_Any ** ppException )
+ SAL_THROW( () )
{
OSL_ASSERT( pMemberType->eTypeClass == typelib_TypeClass_INTERFACE_METHOD );
@@ -231,8 +236,9 @@ static void SAL_CALL ExceptionThrower_dispatch(
OSL_ENSHURE( sal_False, "### illegal member called!" );
}
}
+} // extern "C"
//__________________________________________________________________________________________________
-inline ExceptionThrower::ExceptionThrower()
+inline ExceptionThrower::ExceptionThrower() SAL_THROW( () )
: nRef( 0 )
{
uno_Interface::acquire = ExceptionThrower_acquire;
@@ -241,8 +247,7 @@ inline ExceptionThrower::ExceptionThrower()
}
//==================================================================================================
-void SAL_CALL throwException( const Any & rExc )
- throw (Exception)
+void SAL_CALL throwException( const Any & rExc ) SAL_THROW( (Exception) )
{
if (rExc.getValueTypeClass() == TypeClass_EXCEPTION)
{
diff --git a/cppuhelper/source/factory.cxx b/cppuhelper/source/factory.cxx
index 52098838c..5ff8a4de9 100644
--- a/cppuhelper/source/factory.cxx
+++ b/cppuhelper/source/factory.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: factory.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: lla $ $Date: 2000-12-06 09:36:29 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -108,10 +108,12 @@ class OSingleFactoryHelper
, public XSingleServiceFactory
{
public:
- OSingleFactoryHelper( const Reference<XMultiServiceFactory > & rServiceManager,
- const OUString & rImplementationName_,
- ComponentInstantiation pCreateFunction_,
- const Sequence< OUString > * pServiceNames_ )
+ OSingleFactoryHelper(
+ const Reference<XMultiServiceFactory > & rServiceManager,
+ const OUString & rImplementationName_,
+ ComponentInstantiation pCreateFunction_,
+ const Sequence< OUString > * pServiceNames_ )
+ SAL_THROW( () )
: xSMgr( rServiceManager )
, aImplementationName( rImplementationName_ )
, pCreateFunction( pCreateFunction_ )
@@ -121,20 +123,21 @@ public:
}
// old function, only for backward compatibility
- OSingleFactoryHelper( const Reference<XMultiServiceFactory > & rServiceManager,
- const OUString & rImplementationName_ )
+ OSingleFactoryHelper(
+ const Reference<XMultiServiceFactory > & rServiceManager,
+ const OUString & rImplementationName_ )
+ SAL_THROW( () )
: xSMgr( rServiceManager )
, aImplementationName( rImplementationName_ )
, pCreateFunction( NULL )
- {
- }
+ {}
// XInterface
Any SAL_CALL queryInterface( const Type & rType )
throw(::com::sun::star::uno::RuntimeException);
// XSingleServiceFactory
- Reference<XInterface > SAL_CALL createInstance(void)
+ Reference<XInterface > SAL_CALL createInstance()
throw(::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
virtual Reference<XInterface > SAL_CALL createInstanceWithArguments(const Sequence<Any>& Arguments)
throw(::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
@@ -249,11 +252,13 @@ class OFactoryComponentHelper
, public OSingleFactoryHelper
{
public:
- OFactoryComponentHelper( const Reference<XMultiServiceFactory > & rServiceManager,
- const OUString & rImplementationName_,
- ComponentInstantiation pCreateFunction_,
- const Sequence< OUString > * pServiceNames_,
- sal_Bool bOneInstance_ = sal_False )
+ OFactoryComponentHelper(
+ const Reference<XMultiServiceFactory > & rServiceManager,
+ const OUString & rImplementationName_,
+ ComponentInstantiation pCreateFunction_,
+ const Sequence< OUString > * pServiceNames_,
+ sal_Bool bOneInstance_ = sal_False )
+ SAL_THROW( () )
: OComponentHelper( aMutex )
, OSingleFactoryHelper( rServiceManager, rImplementationName_, pCreateFunction_, pServiceNames_ )
, bOneInstance( bOneInstance_ )
@@ -261,9 +266,11 @@ public:
}
// old function, only for backward compatibility
- OFactoryComponentHelper( const Reference<XMultiServiceFactory > & rServiceManager,
- const OUString & rImplementationName_,
- sal_Bool bOneInstance_ = sal_False )
+ OFactoryComponentHelper(
+ const Reference<XMultiServiceFactory > & rServiceManager,
+ const OUString & rImplementationName_,
+ sal_Bool bOneInstance_ = sal_False )
+ SAL_THROW( () )
: OComponentHelper( aMutex )
, OSingleFactoryHelper( rServiceManager, rImplementationName_ )
, bOneInstance( bOneInstance_ )
@@ -397,10 +404,12 @@ class ORegistryFactoryHelper
: public OFactoryComponentHelper
{
public:
- ORegistryFactoryHelper( const Reference<XMultiServiceFactory > & rServiceManager,
- const OUString & rImplementationName_,
- const Reference<XRegistryKey > & xImplementationKey_,
- sal_Bool bOneInstance_ = sal_False )
+ ORegistryFactoryHelper(
+ const Reference<XMultiServiceFactory > & rServiceManager,
+ const OUString & rImplementationName_,
+ const Reference<XRegistryKey > & xImplementationKey_,
+ sal_Bool bOneInstance_ = sal_False )
+ SAL_THROW( () )
: OFactoryComponentHelper( rServiceManager, rImplementationName_, 0, 0, bOneInstance_ )
, xImplementationKey( xImplementationKey_ )
{}
@@ -595,8 +604,10 @@ class OFactoryProxyHelper : public WeakImplHelper2< XServiceInfo, XSingleService
public:
- OFactoryProxyHelper( const Reference<XMultiServiceFactory > & /*rServiceManager*/,
- const Reference<XSingleServiceFactory > & rFactory )
+ OFactoryProxyHelper(
+ const Reference<XMultiServiceFactory > & /*rServiceManager*/,
+ const Reference<XSingleServiceFactory > & rFactory )
+ SAL_THROW( () )
: xFactory( rFactory )
{}
@@ -666,60 +677,55 @@ Sequence< OUString > OFactoryProxyHelper::getSupportedServiceNames(void)
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// global function
-Reference<XSingleServiceFactory > SAL_CALL createSingleFactory
-(
+Reference<XSingleServiceFactory > SAL_CALL createSingleFactory(
const Reference<XMultiServiceFactory > & rServiceManager,
const OUString & rImplementationName,
ComponentInstantiation pCreateFunction,
- const Sequence< OUString > & rServiceNames
-)
+ const Sequence< OUString > & rServiceNames )
+ SAL_THROW( () )
{
return new OFactoryComponentHelper( rServiceManager, rImplementationName,
pCreateFunction, &rServiceNames, sal_False );
}
// global function
-Reference<XSingleServiceFactory > SAL_CALL createFactoryProxy
-(
+Reference<XSingleServiceFactory > SAL_CALL createFactoryProxy(
const Reference<XMultiServiceFactory > & rServiceManager,
- const Reference<XSingleServiceFactory > & rFactory
-)
+ const Reference<XSingleServiceFactory > & rFactory )
+ SAL_THROW( () )
{
return new OFactoryProxyHelper( rServiceManager, rFactory );
}
// global function
-Reference<XSingleServiceFactory > SAL_CALL createOneInstanceFactory
-(
+Reference<XSingleServiceFactory > SAL_CALL createOneInstanceFactory(
const Reference<XMultiServiceFactory > & rServiceManager,
const OUString & rImplementationName,
ComponentInstantiation pCreateFunction,
- const Sequence< OUString > & rServiceNames
-)
+ const Sequence< OUString > & rServiceNames )
+ SAL_THROW( () )
{
return new OFactoryComponentHelper( rServiceManager, rImplementationName,
pCreateFunction, &rServiceNames, sal_True );
}
// global function
-SAL_DLLEXPORT Reference<XSingleServiceFactory > SAL_CALL createSingleRegistryFactory
-(
+Reference<XSingleServiceFactory > SAL_CALL createSingleRegistryFactory(
const Reference<XMultiServiceFactory > & rServiceManager,
const OUString & rImplementationName,
- const Reference<XRegistryKey > & rImplementationKey
-)
+ const Reference<XRegistryKey > & rImplementationKey )
+ SAL_THROW( () )
{
return new ORegistryFactoryHelper( rServiceManager, rImplementationName,
rImplementationKey, sal_False );
}
// global function
-Reference<XSingleServiceFactory > SAL_CALL createOneInstanceRegistryFactory
-(
+Reference<XSingleServiceFactory > SAL_CALL createOneInstanceRegistryFactory(
const Reference<XMultiServiceFactory > & rServiceManager,
const OUString & rImplementationName,
- const Reference<XRegistryKey > & rImplementationKey
-)
+ const Reference<XRegistryKey > & rImplementationKey )
+ SAL_THROW( () )
{
return new ORegistryFactoryHelper( rServiceManager, rImplementationName,
rImplementationKey, sal_True );
diff --git a/cppuhelper/source/implbase.cxx b/cppuhelper/source/implbase.cxx
index aaaab8580..3e5913da8 100644
--- a/cppuhelper/source/implbase.cxx
+++ b/cppuhelper/source/implbase.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: implbase.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: dbo $ $Date: 2000-10-06 15:15:09 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -80,7 +80,7 @@ using namespace com::sun::star::lang;
namespace cppu
{
//==================================================================================================
-Mutex & SAL_CALL getImplHelperInitMutex(void)
+Mutex & SAL_CALL getImplHelperInitMutex(void) SAL_THROW( () )
{
static Mutex * s_pMutex = 0;
if (! s_pMutex)
@@ -97,7 +97,7 @@ Mutex & SAL_CALL getImplHelperInitMutex(void)
// ClassDataBase
//__________________________________________________________________________________________________
-ClassDataBase::ClassDataBase()
+ClassDataBase::ClassDataBase() SAL_THROW( () )
: bOffsetsInit( sal_False )
, nType2Offset( 0 )
, nClassCode( 0 )
@@ -106,7 +106,7 @@ ClassDataBase::ClassDataBase()
{
}
//__________________________________________________________________________________________________
-ClassDataBase::ClassDataBase( sal_Int32 nClassCode_ )
+ClassDataBase::ClassDataBase( sal_Int32 nClassCode_ ) SAL_THROW( () )
: bOffsetsInit( sal_False )
, nType2Offset( 0 )
, nClassCode( nClassCode_ )
@@ -115,7 +115,7 @@ ClassDataBase::ClassDataBase( sal_Int32 nClassCode_ )
{
}
//__________________________________________________________________________________________________
-ClassDataBase::~ClassDataBase()
+ClassDataBase::~ClassDataBase() SAL_THROW( () )
{
delete pTypes;
delete pId;
@@ -129,7 +129,7 @@ ClassDataBase::~ClassDataBase()
// ClassData
//__________________________________________________________________________________________________
-void ClassData::writeTypeOffset( const Type & rType, sal_Int32 nOffset )
+void ClassData::writeTypeOffset( const Type & rType, sal_Int32 nOffset ) SAL_THROW( () )
{
arType2Offset[nType2Offset].nOffset = nOffset;
@@ -149,7 +149,7 @@ void ClassData::writeTypeOffset( const Type & rType, sal_Int32 nOffset )
#endif
}
//__________________________________________________________________________________________________
-void ClassData::initTypeProvider()
+void ClassData::initTypeProvider() SAL_THROW( () )
{
::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
if (! pTypes)
@@ -190,14 +190,14 @@ void ClassData::initTypeProvider()
}
}
//__________________________________________________________________________________________________
-Sequence< Type > ClassData::getTypes()
+Sequence< Type > ClassData::getTypes() SAL_THROW( () )
{
if (! pTypes)
initTypeProvider();
return *pTypes;
}
//__________________________________________________________________________________________________
-Sequence< sal_Int8 > ClassData::getImplementationId()
+Sequence< sal_Int8 > ClassData::getImplementationId() SAL_THROW( () )
{
if (! pTypes)
initTypeProvider();
@@ -205,15 +205,16 @@ Sequence< sal_Int8 > ClassData::getImplementationId()
}
//--------------------------------------------------------------------------------------------------
-static inline sal_Bool td_equals( typelib_TypeDescription * pTD,
- typelib_TypeDescriptionReference * pType )
+static inline sal_Bool td_equals(
+ typelib_TypeDescription * pTD, typelib_TypeDescriptionReference * pType )
+ SAL_THROW( () )
{
return (pTD->pWeakRef == pType ||
(pTD->pTypeName->length == pType->pTypeName->length &&
rtl_ustr_compare( pTD->pTypeName->buffer, pType->pTypeName->buffer ) == 0));
}
//__________________________________________________________________________________________________
-Any ClassData::query( const Type & rType, XTypeProvider * pBase )
+Any ClassData::query( const Type & rType, XTypeProvider * pBase ) SAL_THROW( () )
{
if (rType == ::getCppuType( (const Reference< XInterface > *)0 ))
return Any( &pBase, ::getCppuType( (const Reference< XInterface > *)0 ) );
diff --git a/cppuhelper/source/interfacecontainer.cxx b/cppuhelper/source/interfacecontainer.cxx
index d012d16b3..880e64170 100644
--- a/cppuhelper/source/interfacecontainer.cxx
+++ b/cppuhelper/source/interfacecontainer.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: interfacecontainer.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: jbu $ $Date: 2001-02-05 13:21:38 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -86,6 +86,7 @@ namespace cppu
* Reallocate the sequence.
*/
static void realloc( Sequence< Reference< XInterface > > & rSeq, sal_Int32 nNewLen )
+ SAL_THROW( () )
{
Sequence< Reference< XInterface > > aNewSeq( nNewLen );
Reference< XInterface > * pDest = aNewSeq.getArray();
@@ -100,6 +101,7 @@ static void realloc( Sequence< Reference< XInterface > > & rSeq, sal_Int32 nNewL
* Remove an element from an interface sequence.
*/
static void sequenceRemoveElementAt( Sequence< Reference< XInterface > > & rSeq, sal_Int32 index )
+ SAL_THROW( () )
{
sal_Int32 nNewLen = rSeq.getLength() - 1;
@@ -127,6 +129,7 @@ static void sequenceRemoveElementAt( Sequence< Reference< XInterface > > & rSeq,
//===================================================================
//===================================================================
OInterfaceIteratorHelper::OInterfaceIteratorHelper( OInterfaceContainerHelper & rCont_ )
+ SAL_THROW( () )
: rCont( rCont_ )
{
MutexGuard aGuard( rCont.rMutex );
@@ -149,7 +152,7 @@ OInterfaceIteratorHelper::OInterfaceIteratorHelper( OInterfaceContainerHelper &
nRemain = 0;
}
-OInterfaceIteratorHelper::~OInterfaceIteratorHelper()
+OInterfaceIteratorHelper::~OInterfaceIteratorHelper() SAL_THROW( () )
{
sal_Bool bShared;
{
@@ -174,7 +177,7 @@ OInterfaceIteratorHelper::~OInterfaceIteratorHelper()
}
}
-XInterface * OInterfaceIteratorHelper::next()
+XInterface * OInterfaceIteratorHelper::next() SAL_THROW( () )
{
if( nRemain )
{
@@ -189,7 +192,7 @@ XInterface * OInterfaceIteratorHelper::next()
return 0;
}
-void OInterfaceIteratorHelper::remove()
+void OInterfaceIteratorHelper::remove() SAL_THROW( () )
{
if( bIsList )
{
@@ -211,7 +214,7 @@ void OInterfaceIteratorHelper::remove()
//===================================================================
-OInterfaceContainerHelper::OInterfaceContainerHelper( Mutex & rMutex_ )
+OInterfaceContainerHelper::OInterfaceContainerHelper( Mutex & rMutex_ ) SAL_THROW( () )
: rMutex( rMutex_ )
, bInUse( sal_False )
, bIsList( sal_False )
@@ -219,7 +222,7 @@ OInterfaceContainerHelper::OInterfaceContainerHelper( Mutex & rMutex_ )
{
}
-OInterfaceContainerHelper::~OInterfaceContainerHelper()
+OInterfaceContainerHelper::~OInterfaceContainerHelper() SAL_THROW( () )
{
OSL_ENSHURE( !bInUse, "~OInterfaceContainerHelper but is in use" );
if( bIsList )
@@ -228,7 +231,7 @@ OInterfaceContainerHelper::~OInterfaceContainerHelper()
((XInterface*)pData)->release();
}
-sal_Int32 OInterfaceContainerHelper::getLength() const
+sal_Int32 OInterfaceContainerHelper::getLength() const SAL_THROW( () )
{
MutexGuard aGuard( rMutex );
if( bIsList )
@@ -238,7 +241,7 @@ sal_Int32 OInterfaceContainerHelper::getLength() const
return 0;
}
-Sequence< Reference<XInterface> > OInterfaceContainerHelper::getElements() const
+Sequence< Reference<XInterface> > OInterfaceContainerHelper::getElements() const SAL_THROW( () )
{
MutexGuard aGuard( rMutex );
if( bIsList )
@@ -251,7 +254,7 @@ Sequence< Reference<XInterface> > OInterfaceContainerHelper::getElements() const
return Sequence< Reference< XInterface > >();
}
-void OInterfaceContainerHelper::copyAndResetInUse()
+void OInterfaceContainerHelper::copyAndResetInUse() SAL_THROW( () )
{
OSL_ENSHURE( bInUse, "OInterfaceContainerHelper not in use" );
if( bInUse )
@@ -267,7 +270,7 @@ void OInterfaceContainerHelper::copyAndResetInUse()
}
}
-sal_Int32 OInterfaceContainerHelper::addInterface( const Reference<XInterface> & rListener )
+sal_Int32 OInterfaceContainerHelper::addInterface( const Reference<XInterface> & rListener ) SAL_THROW( () )
{
assert( rListener.is() );
MutexGuard aGuard( rMutex );
@@ -301,7 +304,7 @@ sal_Int32 OInterfaceContainerHelper::addInterface( const Reference<XInterface> &
}
}
-sal_Int32 OInterfaceContainerHelper::removeInterface( const Reference<XInterface> & rListener )
+sal_Int32 OInterfaceContainerHelper::removeInterface( const Reference<XInterface> & rListener ) SAL_THROW( () )
{
assert( rListener.is() );
MutexGuard aGuard( rMutex );
@@ -357,7 +360,7 @@ sal_Int32 OInterfaceContainerHelper::removeInterface( const Reference<XInterface
return pData ? 1 : 0;
}
-void OInterfaceContainerHelper::disposeAndClear( const EventObject & rEvt )
+void OInterfaceContainerHelper::disposeAndClear( const EventObject & rEvt ) SAL_THROW( () )
{
ClearableMutexGuard aGuard( rMutex );
OInterfaceIteratorHelper aIt( *this );
@@ -387,7 +390,7 @@ void OInterfaceContainerHelper::disposeAndClear( const EventObject & rEvt )
}
-void OInterfaceContainerHelper::clear( )
+void OInterfaceContainerHelper::clear() SAL_THROW( () )
{
ClearableMutexGuard aGuard( rMutex );
OInterfaceIteratorHelper aIt( *this );
diff --git a/cppuhelper/source/propshlp.cxx b/cppuhelper/source/propshlp.cxx
index 383649d66..fced24f3d 100644
--- a/cppuhelper/source/propshlp.cxx
+++ b/cppuhelper/source/propshlp.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: propshlp.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: jbu $ $Date: 2000-10-06 16:01:45 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -85,20 +85,20 @@ IPropertyArrayHelper::~IPropertyArrayHelper()
{
}
-inline const ::com::sun::star::uno::Type & getPropertyTypeIdentifier( )
+inline const ::com::sun::star::uno::Type & getPropertyTypeIdentifier( ) SAL_THROW( () )
{
return ::getCppuType( (Reference< XPropertyChangeListener > *)0 );
}
-inline const ::com::sun::star::uno::Type & getPropertiesTypeIdentifier()
+inline const ::com::sun::star::uno::Type & getPropertiesTypeIdentifier() SAL_THROW( () )
{
return ::getCppuType( (Reference< XPropertiesChangeListener > *)0 );
}
-inline const ::com::sun::star::uno::Type & getVetoableTypeIdentifier()
+inline const ::com::sun::star::uno::Type & getVetoableTypeIdentifier() SAL_THROW( () )
{
return ::getCppuType( (Reference< XVetoableChangeListener > *)0 );
}
-int SAL_CALL compare_OUString_Property_Impl( const void *arg1, const void *arg2 )
+int SAL_CALL compare_OUString_Property_Impl( const void *arg1, const void *arg2 ) SAL_THROW( () )
{
return ((OUString *)arg1)->compareTo( ((Property *)arg2)->Name );
}
@@ -112,7 +112,7 @@ class OPropertySetHelperInfo_Impl
Sequence < Property > aInfos;
public:
- OPropertySetHelperInfo_Impl( IPropertyArrayHelper & rHelper_ );
+ OPropertySetHelperInfo_Impl( IPropertyArrayHelper & rHelper_ ) SAL_THROW( () );
// XPropertySetInfo-Methoden
virtual Sequence< Property > SAL_CALL getProperties(void);
@@ -124,8 +124,10 @@ public:
/**
* Create an object that implements XPropertySetInfo IPropertyArrayHelper.
*/
-OPropertySetHelperInfo_Impl::OPropertySetHelperInfo_Impl( IPropertyArrayHelper & rHelper_ )
- :aInfos( rHelper_.getProperties() )
+OPropertySetHelperInfo_Impl::OPropertySetHelperInfo_Impl(
+ IPropertyArrayHelper & rHelper_ )
+ SAL_THROW( () )
+ :aInfos( rHelper_.getProperties() )
{
}
@@ -169,7 +171,8 @@ sal_Bool OPropertySetHelperInfo_Impl::hasPropertyByName( const OUString & Proper
// class PropertySetHelper
// ----------------------------------------------------
OPropertySetHelper::OPropertySetHelper(
- OBroadcastHelper & rBHelper_ )
+ OBroadcastHelper & rBHelper_ )
+ SAL_THROW( () )
: rBHelper( rBHelper_ )
, aBoundLC( rBHelper_.rMutex )
, aVetoableLC( rBHelper_.rMutex )
@@ -179,7 +182,7 @@ OPropertySetHelper::OPropertySetHelper(
/**
* You must call disposing before.
*/
-OPropertySetHelper::~OPropertySetHelper()
+OPropertySetHelper::~OPropertySetHelper() SAL_THROW( () )
{
}
@@ -190,14 +193,15 @@ OPropertySetHelper::~OPropertySetHelper()
// XAggregation
Any OPropertySetHelper::queryInterface( const ::com::sun::star::uno::Type & rType )
{
- return ::cppu::queryInterface( rType,
- static_cast< XPropertySet * >( this ),
- static_cast< XMultiPropertySet * >( this ),
- static_cast< XFastPropertySet * >( this ) );
+ return ::cppu::queryInterface(
+ rType,
+ static_cast< XPropertySet * >( this ),
+ static_cast< XMultiPropertySet * >( this ),
+ static_cast< XFastPropertySet * >( this ) );
}
// ComponentHelper
-void OPropertySetHelper::disposing()
+void OPropertySetHelper::disposing() SAL_THROW( () )
{
// Create an event with this as sender
Reference < XPropertySet > rSource( SAL_STATIC_CAST( XPropertySet * , this ) , UNO_QUERY );
@@ -210,13 +214,16 @@ void OPropertySetHelper::disposing()
aVetoableLC.disposeAndClear( aEvt );
}
-Reference < XPropertySetInfo > OPropertySetHelper::createPropertySetInfo( IPropertyArrayHelper & rProperties )
+Reference < XPropertySetInfo > OPropertySetHelper::createPropertySetInfo(
+ IPropertyArrayHelper & rProperties ) SAL_THROW( () )
{
return static_cast< XPropertySetInfo * >( new OPropertySetHelperInfo_Impl( rProperties ) );
}
// XPropertySet
-void OPropertySetHelper::setPropertyValue( const OUString& rPropertyName, const Any& rValue )
+void OPropertySetHelper::setPropertyValue(
+ const OUString& rPropertyName, const Any& rValue )
+ throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
// get the map table
IPropertyArrayHelper & rPH = getInfoHelper();
@@ -227,7 +234,9 @@ void OPropertySetHelper::setPropertyValue( const OUString& rPropertyName, const
}
// XPropertySet
-Any OPropertySetHelper::getPropertyValue( const OUString& rPropertyName )
+Any OPropertySetHelper::getPropertyValue(
+ const OUString& rPropertyName )
+ throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
// get the map table
IPropertyArrayHelper & rPH = getInfoHelper();
@@ -238,8 +247,9 @@ Any OPropertySetHelper::getPropertyValue( const OUString& rPropertyName )
}
// XPropertySet
-void OPropertySetHelper::addPropertyChangeListener(const OUString& rPropertyName,
- const Reference < XPropertyChangeListener > & rxListener)
+void OPropertySetHelper::addPropertyChangeListener(
+ const OUString& rPropertyName,
+ const Reference < XPropertyChangeListener > & rxListener )
throw(::com::sun::star::beans::UnknownPropertyException,
::com::sun::star::lang::WrappedTargetException,
::com::sun::star::uno::RuntimeException)
@@ -285,11 +295,12 @@ void OPropertySetHelper::addPropertyChangeListener(const OUString& rPropertyName
// XPropertySet
-void OPropertySetHelper::removePropertyChangeListener(const OUString& rPropertyName,
- const Reference < XPropertyChangeListener >& rxListener)
- throw(::com::sun::star::beans::UnknownPropertyException,
- ::com::sun::star::lang::WrappedTargetException,
- ::com::sun::star::uno::RuntimeException)
+void OPropertySetHelper::removePropertyChangeListener(
+ const OUString& rPropertyName,
+ const Reference < XPropertyChangeListener >& rxListener )
+ throw(::com::sun::star::beans::UnknownPropertyException,
+ ::com::sun::star::lang::WrappedTargetException,
+ ::com::sun::star::uno::RuntimeException)
{
MutexGuard aGuard( rBHelper.rMutex );
OSL_ENSHURE( !rBHelper.bDisposed, "object is disposed" );
@@ -318,14 +329,12 @@ void OPropertySetHelper::removePropertyChangeListener(const OUString& rPropertyN
}
// XPropertySet
-void OPropertySetHelper::addVetoableChangeListener
-(
+void OPropertySetHelper::addVetoableChangeListener(
const OUString& rPropertyName,
- const Reference< XVetoableChangeListener > & rxListener
-)
- throw(::com::sun::star::beans::UnknownPropertyException,
- ::com::sun::star::lang::WrappedTargetException,
- ::com::sun::star::uno::RuntimeException)
+ const Reference< XVetoableChangeListener > & rxListener )
+ throw(::com::sun::star::beans::UnknownPropertyException,
+ ::com::sun::star::lang::WrappedTargetException,
+ ::com::sun::star::uno::RuntimeException)
{
MutexGuard aGuard( rBHelper.rMutex );
OSL_ENSHURE( !rBHelper.bInDispose, "do not addVetoableChangeListener in the dispose call" );
@@ -366,14 +375,12 @@ void OPropertySetHelper::addVetoableChangeListener
}
// XPropertySet
-void OPropertySetHelper::removeVetoableChangeListener
-(
+void OPropertySetHelper::removeVetoableChangeListener(
const OUString& rPropertyName,
- const Reference < XVetoableChangeListener > & rxListener
-)
- throw(::com::sun::star::beans::UnknownPropertyException,
- ::com::sun::star::lang::WrappedTargetException,
- ::com::sun::star::uno::RuntimeException)
+ const Reference < XVetoableChangeListener > & rxListener )
+ throw(::com::sun::star::beans::UnknownPropertyException,
+ ::com::sun::star::lang::WrappedTargetException,
+ ::com::sun::star::uno::RuntimeException)
{
MutexGuard aGuard( rBHelper.rMutex );
OSL_ENSHURE( !rBHelper.bDisposed, "object is disposed" );
@@ -587,14 +594,12 @@ void OPropertySetHelper::fire
}
// OPropertySetHelper
-void OPropertySetHelper::setFastPropertyValues
-(
+void OPropertySetHelper::setFastPropertyValues(
sal_Int32 nSeqLen,
sal_Int32 * pHandles,
const Any * pValues,
- sal_Int32 nHitCount
-)
-throw (Exception)
+ sal_Int32 nHitCount )
+ SAL_THROW( (::com::sun::star::uno::Exception) )
{
OSL_ENSHURE( !rBHelper.bInDispose, "do not getFastPropertyValue in the dispose call" );
OSL_ENSHURE( !rBHelper.bDisposed, "object is disposed" );
@@ -670,11 +675,10 @@ throw (Exception)
* The sequence may be conatain not known properties. The implementation
* must ignore these properties.
*/
-void OPropertySetHelper::setPropertyValues
-(
+void OPropertySetHelper::setPropertyValues(
const Sequence<OUString>& rPropertyNames,
- const Sequence<Any>& rValues
-)
+ const Sequence<Any>& rValues )
+ throw(::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
sal_Int32 * pHandles = NULL;
try
@@ -697,7 +701,8 @@ void OPropertySetHelper::setPropertyValues
}
// XMultiPropertySet
-Sequence<Any> OPropertySetHelper::getPropertyValues( const Sequence<OUString>& rPropertyNames )
+Sequence<Any> OPropertySetHelper::getPropertyValues( const Sequence<OUString>& rPropertyNames )
+ throw(::com::sun::star::uno::RuntimeException)
{
sal_Int32 nSeqLen = rPropertyNames.getLength();
sal_Int32 * pHandles = new sal_Int32[ nSeqLen ];
@@ -721,27 +726,27 @@ Sequence<Any> OPropertySetHelper::getPropertyValues( const Sequence<OUString>& r
}
// XMultiPropertySet
-void OPropertySetHelper::addPropertiesChangeListener (
- const Sequence<OUString> & ,
- const Reference < XPropertiesChangeListener > & rListener
- )
+void OPropertySetHelper::addPropertiesChangeListener(
+ const Sequence<OUString> & ,
+ const Reference < XPropertiesChangeListener > & rListener )
+ throw(::com::sun::star::uno::RuntimeException)
{
rBHelper.addListener( getCppuType(&rListener) , rListener );
}
// XMultiPropertySet
-void OPropertySetHelper::removePropertiesChangeListener
- ( const Reference < XPropertiesChangeListener > & rListener )
+void OPropertySetHelper::removePropertiesChangeListener(
+ const Reference < XPropertiesChangeListener > & rListener )
+ throw(::com::sun::star::uno::RuntimeException)
{
rBHelper.removeListener( getCppuType(&rListener) , rListener );
}
// XMultiPropertySet
-void OPropertySetHelper::firePropertiesChangeEvent
-(
+void OPropertySetHelper::firePropertiesChangeEvent(
const Sequence<OUString>& rPropertyNames,
- const Reference < XPropertiesChangeListener >& rListener
-)
+ const Reference < XPropertiesChangeListener >& rListener )
+ throw(::com::sun::star::uno::RuntimeException)
{
sal_Int32 nLen = rPropertyNames.getLength();
sal_Int32 * pHandles = new sal_Int32[nLen];
@@ -844,12 +849,12 @@ void OPropertySetHelper::removePropertyStateChangeListener( const OUString& aPro
// return ow;
// }
-int SAL_CALL compare_Property_Impl( const void *arg1, const void *arg2 )
+int SAL_CALL compare_Property_Impl( const void *arg1, const void *arg2 ) SAL_THROW( () )
{
return ((Property *)arg1)->Name.compareTo( ((Property *)arg2)->Name );
}
-void OPropertyArrayHelper::init( sal_Bool bSorted )
+void OPropertyArrayHelper::init( sal_Bool bSorted ) SAL_THROW( () )
{
sal_Int32 i, nElements = aInfos.getLength();
const Property* pProperties = aInfos.getConstArray();
@@ -874,23 +879,21 @@ void OPropertyArrayHelper::init( sal_Bool bSorted )
bRightOrdered = sal_True;
}
-OPropertyArrayHelper::OPropertyArrayHelper
-(
+OPropertyArrayHelper::OPropertyArrayHelper(
Property * pProps,
sal_Int32 nEle,
- sal_Bool bSorted
-)
+ sal_Bool bSorted )
+ SAL_THROW( () )
: aInfos(pProps, nEle)
, bRightOrdered( sal_False )
{
init( bSorted );
}
-OPropertyArrayHelper::OPropertyArrayHelper
-(
+OPropertyArrayHelper::OPropertyArrayHelper(
const Sequence< Property > & aProps,
- sal_Bool bSorted
-)
+ sal_Bool bSorted )
+ SAL_THROW( () )
: aInfos(aProps)
, bRightOrdered( sal_False )
{
diff --git a/cppuhelper/source/servicefactory.cxx b/cppuhelper/source/servicefactory.cxx
index bd265f015..ff18c0d53 100644
--- a/cppuhelper/source/servicefactory.cxx
+++ b/cppuhelper/source/servicefactory.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: servicefactory.cxx,v $
*
- * $Revision: 1.7 $
+ * $Revision: 1.8 $
*
- * last change: $Author: dbo $ $Date: 2001-02-15 11:46:17 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -171,7 +171,7 @@ static Reference< XMultiServiceFactory > createImplServiceFactory(
const OUString & rReadRegistry,
sal_Bool bReadOnly,
const OUString & rBootstrapPath )
- throw( ::com::sun::star::uno::Exception )
+ SAL_THROW( (::com::sun::star::uno::Exception) )
{
Reference< XSingleServiceFactory > xSMFac( loadLibComponentFactory(
OUString( RTL_CONSTASCII_USTRINGPARAM("smgr") ),
@@ -370,7 +370,7 @@ Reference< XMultiServiceFactory > SAL_CALL createRegistryServiceFactory(
const OUString & rReadRegistry,
sal_Bool bReadOnly,
const OUString & rBootstrapPath )
- throw( ::com::sun::star::uno::Exception )
+ SAL_THROW( (::com::sun::star::uno::Exception) )
{
return createImplServiceFactory( rWriteRegistry, rReadRegistry, bReadOnly, rBootstrapPath );
}
diff --git a/cppuhelper/source/shlib.cxx b/cppuhelper/source/shlib.cxx
index 63a4da39f..30bb04503 100644
--- a/cppuhelper/source/shlib.cxx
+++ b/cppuhelper/source/shlib.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: shlib.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: pluby $ $Date: 2001-02-10 17:52:00 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -89,7 +89,7 @@ namespace cppu
#ifdef DEBUG
//==================================================================================================
-static inline void out( const char * p ) throw ()
+static inline void out( const char * p ) SAL_THROW( () )
{
::fprintf( stderr, p );
}
@@ -101,7 +101,7 @@ static inline void out( const OUString & r ) throw ()
#endif
//==================================================================================================
-static const ::std::vector< OUString > * getAccessDPath() throw ()
+static const ::std::vector< OUString > * getAccessDPath() SAL_THROW( () )
{
static ::std::vector< OUString > * s_p = 0;
static bool s_bInit = false;
@@ -143,6 +143,13 @@ static const ::std::vector< OUString > * getAccessDPath() throw ()
#endif
s_p = & s_v;
}
+ else
+ {
+ // no access path env set
+#ifdef DEBUG
+ out( "=> no CPLD_ACCESSPATH set.\n" );
+#endif
+ }
s_bInit = true;
}
}
@@ -153,12 +160,6 @@ static const ::std::vector< OUString > * getAccessDPath() throw ()
//==================================================================================================
static bool checkAccessPath( OUString * pComp ) throw ()
{
-#ifdef DEBUG
- out( "> trying to access module: \"" );
- out( *pComp );
- out( "\"\n" );
-#endif
-
const ::std::vector< OUString > * pPath = getAccessDPath();
if (pPath)
@@ -221,15 +222,12 @@ static bool checkAccessPath( OUString * pComp ) throw ()
else
{
// no access path env set
-#ifdef DEBUG
- out( "=> no CPLD_ACCESSPATH set.\n" );
-#endif
return true;
}
}
//--------------------------------------------------------------------------------------------------
-static inline sal_Int32 endsWith( const OUString & rText, const OUString & rEnd ) throw ()
+static inline sal_Int32 endsWith( const OUString & rText, const OUString & rEnd ) SAL_THROW( () )
{
if (rText.getLength() >= rEnd.getLength() &&
rEnd.equalsIgnoreCase( rText.copy( rText.getLength() - rEnd.getLength() ) ))
@@ -239,9 +237,7 @@ static inline sal_Int32 endsWith( const OUString & rText, const OUString & rEnd
return -1;
}
//==================================================================================================
-static OUString makeComponentPath(
- const OUString & rLibName, const OUString & rPath
- ) throw ()
+static OUString makeComponentPath( const OUString & rLibName, const OUString & rPath ) SAL_THROW( () )
{
OUStringBuffer buf( rPath.getLength() + 32 );
@@ -307,7 +303,7 @@ Reference< XSingleServiceFactory > SAL_CALL loadSharedLibComponentFactory(
OUString const & rImplName,
Reference< XMultiServiceFactory > const & xMgr,
Reference< XRegistryKey > const & xKey )
- throw (CannotActivateFactoryException)
+ SAL_THROW( (CannotActivateFactoryException) )
{
OUString aModulePath( makeComponentPath( rLibName, rPath ) );
@@ -451,7 +447,9 @@ Reference< XSingleServiceFactory > SAL_CALL loadSharedLibComponentFactory(
{
::osl_unloadModule( lib );
#ifdef DEBUG
+ out( "### cannot activate factory: " );
out( aExcMsg );
+ out( "\n" );
#endif
throw CannotActivateFactoryException( aExcMsg, Reference< XInterface >() );
}
@@ -464,7 +462,7 @@ void SAL_CALL writeSharedLibComponentInfo(
OUString const & rLibName, OUString const & rPath,
Reference< XMultiServiceFactory > const & xMgr,
Reference< XRegistryKey > const & xKey )
- throw (CannotRegisterImplementationException)
+ SAL_THROW( (CannotRegisterImplementationException) )
{
OUString aModulePath( makeComponentPath( rLibName, rPath ) );
@@ -603,7 +601,9 @@ void SAL_CALL writeSharedLibComponentInfo(
{
::osl_unloadModule( lib );
#ifdef DEBUG
+ out( "### cannot write component info: " );
out( aExcMsg );
+ out( "\n" );
#endif
throw CannotRegisterImplementationException( aExcMsg, Reference< XInterface >() );
}
diff --git a/cppuhelper/source/stdidlclass.cxx b/cppuhelper/source/stdidlclass.cxx
index b48b401df..806f1cbbe 100644
--- a/cppuhelper/source/stdidlclass.cxx
+++ b/cppuhelper/source/stdidlclass.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: stdidlclass.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 15:26:10 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -88,7 +88,7 @@ public:
const OUString & sImplementationName ,
const Reference < XIdlClass > & rSuperClass,
const Sequence < OUString > &seq
- );
+ ) SAL_THROW( () );
// XInterface
Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType )
@@ -98,7 +98,8 @@ public:
void SAL_CALL release() { OWeakObject::release(); }
// XIdlClassProvider
- Sequence< Reference < XIdlClass > > SAL_CALL getIdlClasses(void);
+ Sequence< Reference < XIdlClass > > SAL_CALL getIdlClasses(void)
+ throw (RuntimeException);
// XIdlClass
virtual Sequence< Reference< XIdlClass > > SAL_CALL getClasses( ) throw(RuntimeException)
@@ -146,7 +147,7 @@ OStdIdlClass::OStdIdlClass(
const OUString & sImplementationName ,
const Reference < XIdlClass > & rSuperClass,
const Sequence < OUString > &seq
- ) :
+ ) SAL_THROW( () ) :
m_rSMgr( rSMgr ) ,
m_sImplementationName( sImplementationName ) ,
m_seqSupportedInterface( seq )
@@ -192,6 +193,7 @@ Sequence< Reference< XIdlClass > > SAL_CALL OStdIdlClass::getInterfaces( ) thro
// XIdlClassProvider
Sequence< Reference < XIdlClass > > SAL_CALL OStdIdlClass::getIdlClasses(void)
+ throw (RuntimeException)
{
// weak reference to cache the standard class
static WeakReference< XIdlClass > weakRef;
@@ -225,6 +227,7 @@ XIdlClass * SAL_CALL createStandardClassWithSequence(
const OUString & sImplementationName ,
const Reference < XIdlClass > & rSuperClass,
const Sequence < OUString > &seqInterfaceNames )
+ SAL_THROW( () )
{
return SAL_STATIC_CAST(
XIdlClass * ,
diff --git a/cppuhelper/source/typeprovider.cxx b/cppuhelper/source/typeprovider.cxx
index 895694748..606071f50 100644
--- a/cppuhelper/source/typeprovider.cxx
+++ b/cppuhelper/source/typeprovider.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: typeprovider.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 15:26:10 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -69,12 +69,12 @@ namespace cppu
{
//__________________________________________________________________________________________________
-OImplementationId::~OImplementationId()
+OImplementationId::~OImplementationId() SAL_THROW( () )
{
delete _pSeq;
}
//__________________________________________________________________________________________________
-Sequence< sal_Int8 > OImplementationId::getImplementationId() const
+Sequence< sal_Int8 > OImplementationId::getImplementationId() const SAL_THROW( () )
{
if (! _pSeq)
{
@@ -91,6 +91,7 @@ Sequence< sal_Int8 > OImplementationId::getImplementationId() const
//--------------------------------------------------------------------------------------------------
static inline void copy( Sequence< Type > & rDest, const Sequence< Type > & rSource, sal_Int32 nOffset )
+ SAL_THROW( () )
{
Type * pDest = rDest.getArray();
const Type * pSource = rSource.getConstArray();
@@ -103,6 +104,7 @@ static inline void copy( Sequence< Type > & rDest, const Sequence< Type > & rSou
OTypeCollection::OTypeCollection(
const Type & rType1,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 1 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -113,6 +115,7 @@ OTypeCollection::OTypeCollection(
const Type & rType1,
const Type & rType2,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 2 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -125,6 +128,7 @@ OTypeCollection::OTypeCollection(
const Type & rType2,
const Type & rType3,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 3 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -139,6 +143,7 @@ OTypeCollection::OTypeCollection(
const Type & rType3,
const Type & rType4,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 4 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -155,6 +160,7 @@ OTypeCollection::OTypeCollection(
const Type & rType4,
const Type & rType5,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 5 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -173,6 +179,7 @@ OTypeCollection::OTypeCollection(
const Type & rType5,
const Type & rType6,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 6 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -193,6 +200,7 @@ OTypeCollection::OTypeCollection(
const Type & rType6,
const Type & rType7,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 7 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -215,6 +223,7 @@ OTypeCollection::OTypeCollection(
const Type & rType7,
const Type & rType8,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 8 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -239,6 +248,7 @@ OTypeCollection::OTypeCollection(
const Type & rType8,
const Type & rType9,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 9 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -265,6 +275,7 @@ OTypeCollection::OTypeCollection(
const Type & rType9,
const Type & rType10,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 10 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -293,6 +304,7 @@ OTypeCollection::OTypeCollection(
const Type & rType10,
const Type & rType11,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 11 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
@@ -323,6 +335,7 @@ OTypeCollection::OTypeCollection(
const Type & rType11,
const Type & rType12,
const Sequence< Type > & rAddTypes )
+ SAL_THROW( () )
: _aTypes( 12 + rAddTypes.getLength() )
{
_aTypes[0] = rType1;
diff --git a/cppuhelper/source/weak.cxx b/cppuhelper/source/weak.cxx
index d0e756265..73c38bbec 100644
--- a/cppuhelper/source/weak.cxx
+++ b/cppuhelper/source/weak.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: weak.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: dbo $ $Date: 2001-02-14 10:17:32 $
+ * last change: $Author: dbo $ $Date: 2001-03-09 12:15:28 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -103,7 +103,7 @@ inline static Mutex & getWeakMutex() throw()
*/
// due to static Reflection destruction from usr, ther must be a mutex leak (#73272#)
-inline static Mutex & getWeakMutex() throw()
+inline static Mutex & getWeakMutex() SAL_THROW( () )
{
static Mutex * s_pMutex = 0;
if (! s_pMutex)
@@ -120,7 +120,7 @@ public:
/**
Hold the weak object without an acquire (only the pointer).
*/
- OWeakConnectionPoint( OWeakObject* pObj ) throw()
+ OWeakConnectionPoint( OWeakObject* pObj ) SAL_THROW( () )
: m_aRefCount( 0 )
, m_pObject(pObj)
, m_aReferences( getWeakMutex() )
@@ -252,7 +252,7 @@ void SAL_CALL OWeakObject::release() throw()
}
}
-OWeakObject::~OWeakObject() throw(::com::sun::star::uno::RuntimeException)
+OWeakObject::~OWeakObject() SAL_THROW( (::com::sun::star::uno::RuntimeException) )
{
}
@@ -279,7 +279,7 @@ Reference< XAdapter > SAL_CALL OWeakObject::queryAdapter()
//-- OWeakAggObject ----------------------------------------------------
//------------------------------------------------------------------------
OWeakAggObject::~OWeakAggObject()
- throw (::com::sun::star::uno::RuntimeException)
+ SAL_THROW( (::com::sun::star::uno::RuntimeException) )
{
}
@@ -358,13 +358,13 @@ namespace uno
class OWeakRefListener : public XReference
{
public:
- OWeakRefListener();
- OWeakRefListener(const OWeakRefListener& rRef);
- OWeakRefListener(const Reference< XInterface >& xInt);
- ~OWeakRefListener();
-
+ OWeakRefListener() SAL_THROW( () );
+ OWeakRefListener(const OWeakRefListener& rRef) SAL_THROW( () );
+ OWeakRefListener(const Reference< XInterface >& xInt) SAL_THROW( () );
+ ~OWeakRefListener() SAL_THROW( () );
+
// XInterface
- Any SAL_CALL queryInterface( const Type & rType ) throw();
+ Any SAL_CALL queryInterface( const Type & rType ) throw(RuntimeException);
void SAL_CALL acquire() throw();
void SAL_CALL release() throw();
@@ -377,15 +377,15 @@ public:
Reference< XAdapter > m_XWeakConnectionPoint;
private:
- OWeakRefListener& SAL_CALL operator=(const OWeakRefListener& rRef);
+ OWeakRefListener& SAL_CALL operator=(const OWeakRefListener& rRef) SAL_THROW( () );
};
-OWeakRefListener::OWeakRefListener()
+OWeakRefListener::OWeakRefListener() SAL_THROW( () )
: m_aRefCount( 0 )
{
}
-OWeakRefListener::OWeakRefListener(const OWeakRefListener& rRef)
+OWeakRefListener::OWeakRefListener(const OWeakRefListener& rRef) SAL_THROW( () )
: m_aRefCount( 0 )
{
m_XWeakConnectionPoint = rRef.m_XWeakConnectionPoint;
@@ -394,7 +394,7 @@ OWeakRefListener::OWeakRefListener(const OWeakRefListener& rRef)
m_XWeakConnectionPoint->addReference((XReference*)this);
}
-OWeakRefListener::OWeakRefListener(const Reference< XInterface >& xInt)
+OWeakRefListener::OWeakRefListener(const Reference< XInterface >& xInt) SAL_THROW( () )
: m_aRefCount( 0 )
{
Reference< XWeak > xWeak( Reference< XWeak >::query( xInt ) );
@@ -410,7 +410,7 @@ OWeakRefListener::OWeakRefListener(const Reference< XInterface >& xInt)
}
}
-OWeakRefListener::~OWeakRefListener()
+OWeakRefListener::~OWeakRefListener() SAL_THROW( () )
{
acquire(); // dont die again
if (m_XWeakConnectionPoint.is())
@@ -418,7 +418,7 @@ OWeakRefListener::~OWeakRefListener()
}
// XInterface
-Any SAL_CALL OWeakRefListener::queryInterface( const Type & rType ) throw()
+Any SAL_CALL OWeakRefListener::queryInterface( const Type & rType ) throw(RuntimeException)
{
return ::cppu::queryInterface(
rType, static_cast< XReference * >( this ), static_cast< XInterface * >( this ) );
@@ -457,7 +457,7 @@ void SAL_CALL OWeakRefListener::dispose()
//------------------------------------------------------------------------
//-- WeakReferenceHelper ----------------------------------------------------------
//------------------------------------------------------------------------
-WeakReferenceHelper::WeakReferenceHelper(const Reference< XInterface >& xInt)
+WeakReferenceHelper::WeakReferenceHelper(const Reference< XInterface >& xInt) SAL_THROW( () )
: m_pImpl( 0 )
{
if (xInt.is())
@@ -467,7 +467,7 @@ WeakReferenceHelper::WeakReferenceHelper(const Reference< XInterface >& xInt)
}
}
-WeakReferenceHelper::WeakReferenceHelper(const WeakReferenceHelper& rWeakRef)
+WeakReferenceHelper::WeakReferenceHelper(const WeakReferenceHelper& rWeakRef) SAL_THROW( () )
: m_pImpl( 0 )
{
Reference< XInterface > xInt( rWeakRef.get() );
@@ -478,7 +478,7 @@ WeakReferenceHelper::WeakReferenceHelper(const WeakReferenceHelper& rWeakRef)
}
}
-WeakReferenceHelper& WeakReferenceHelper::operator=(const WeakReferenceHelper& rWeakRef)
+WeakReferenceHelper& WeakReferenceHelper::operator=(const WeakReferenceHelper& rWeakRef) SAL_THROW( () )
{
if (this != &rWeakRef)
{
@@ -502,7 +502,7 @@ WeakReferenceHelper& WeakReferenceHelper::operator=(const WeakReferenceHelper& r
return *this;
}
-WeakReferenceHelper::~WeakReferenceHelper()
+WeakReferenceHelper::~WeakReferenceHelper() SAL_THROW( () )
{
if (m_pImpl)
{
@@ -516,7 +516,7 @@ WeakReferenceHelper::~WeakReferenceHelper()
}
}
-Reference< XInterface > WeakReferenceHelper::get() const
+Reference< XInterface > WeakReferenceHelper::get() const SAL_THROW( () )
{
Reference< XAdapter > xAdp;
{