diff options
author | Noel Grandin <noel@peralex.com> | 2014-05-23 12:03:21 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2014-05-23 15:06:00 +0200 |
commit | e7bc3cab019fbf040f9fb8b53ae2cf3f977d200b (patch) | |
tree | bc507bccee9fb71134e362b72d22991561e32aa0 /basic/source | |
parent | c5d47c327a57df55fa3dac0fff6b65888d0345e4 (diff) |
remove boilerplate in UNO Exception constructor calls
Now that we have default values for Exception constructor params,
remove lots of boilerplate code.
Change-Id: I620bd641eecfed38e6123873b3b94aaf47922e74
Diffstat (limited to 'basic/source')
-rw-r--r-- | basic/source/classes/errobject.cxx | 2 | ||||
-rw-r--r-- | basic/source/classes/sbunoobj.cxx | 6 | ||||
-rw-r--r-- | basic/source/uno/namecont.cxx | 2 |
3 files changed, 4 insertions, 6 deletions
diff --git a/basic/source/classes/errobject.cxx b/basic/source/classes/errobject.cxx index e66560a6672a..d5843fe634c9 100644 --- a/basic/source/classes/errobject.cxx +++ b/basic/source/classes/errobject.cxx @@ -164,7 +164,7 @@ void ErrObject::setData( const uno::Any& Number, const uno::Any& Source, const u throw (uno::RuntimeException) { if ( !Number.hasValue() ) - throw uno::RuntimeException("Missing Required Parameter", uno::Reference< uno::XInterface >() ); + throw uno::RuntimeException("Missing Required Parameter" ); Number >>= m_nNumber; Description >>= m_sDescription; Source >>= m_sSource; diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx index 86881eeca526..7e5dcfd10ba9 100644 --- a/basic/source/classes/sbunoobj.cxx +++ b/basic/source/classes/sbunoobj.cxx @@ -212,8 +212,7 @@ Reference< XHierarchicalNameAccess > getTypeProvider_Impl( void ) if( !xAccess.is() ) { throw DeploymentException( - OUString("/singletons/com.sun.star.reflection.theTypeDescriptionManager singleton not accessible"), - Reference< XInterface >() ); + "/singletons/com.sun.star.reflection.theTypeDescriptionManager singleton not accessible" ); } } return xAccess; @@ -236,8 +235,7 @@ Reference< XTypeConverter > getTypeConverter_Impl( void ) if( !xTypeConverter.is() ) { throw DeploymentException( - OUString("com.sun.star.script.Converter service not accessible"), - Reference< XInterface >() ); + "com.sun.star.script.Converter service not accessible" ); } } return xTypeConverter; diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx index 6bbe98854f61..924c48886887 100644 --- a/basic/source/uno/namecont.cxx +++ b/basic/source/uno/namecont.cxx @@ -242,7 +242,7 @@ void NameContainer::removeByName( const OUString& aName ) if( aIt == mHashMap.end() ) { OUString sMessage = "\"" + aName + "\" not found"; - throw NoSuchElementException(sMessage, uno::Reference< uno::XInterface >()); + throw NoSuchElementException(sMessage); } sal_Int32 iHashResult = (*aIt).second; |