summaryrefslogtreecommitdiff
path: root/package/source/zippackage/ZipPackageFolder.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-05-23 12:03:21 +0200
committerNoel Grandin <noel@peralex.com>2014-05-23 15:06:00 +0200
commite7bc3cab019fbf040f9fb8b53ae2cf3f977d200b (patch)
treebc507bccee9fb71134e362b72d22991561e32aa0 /package/source/zippackage/ZipPackageFolder.cxx
parentc5d47c327a57df55fa3dac0fff6b65888d0345e4 (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 'package/source/zippackage/ZipPackageFolder.cxx')
-rw-r--r--package/source/zippackage/ZipPackageFolder.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/package/source/zippackage/ZipPackageFolder.cxx b/package/source/zippackage/ZipPackageFolder.cxx
index 8c2a53b7f285..e232f1afeec9 100644
--- a/package/source/zippackage/ZipPackageFolder.cxx
+++ b/package/source/zippackage/ZipPackageFolder.cxx
@@ -186,7 +186,7 @@ void SAL_CALL ZipPackageFolder::insertByName( const OUString& aName, const uno::
throw(IllegalArgumentException, ElementExistException, WrappedTargetException, uno::RuntimeException, std::exception)
{
if (hasByName(aName))
- throw ElementExistException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw ElementExistException(THROW_WHERE );
else
{
uno::Reference < XUnoTunnel > xRef;
@@ -221,7 +221,7 @@ void SAL_CALL ZipPackageFolder::removeByName( const OUString& Name )
{
ContentHash::iterator aIter = maContents.find ( Name );
if ( aIter == maContents.end() )
- throw NoSuchElementException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw NoSuchElementException(THROW_WHERE );
maContents.erase( aIter );
}
// XEnumerationAccess
@@ -247,7 +247,7 @@ ContentInfo& ZipPackageFolder::doGetByName( const OUString& aName )
{
ContentHash::iterator aIter = maContents.find ( aName );
if ( aIter == maContents.end())
- throw NoSuchElementException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw NoSuchElementException(THROW_WHERE );
return *(*aIter).second;
}
uno::Any SAL_CALL ZipPackageFolder::getByName( const OUString& aName )
@@ -278,7 +278,7 @@ void SAL_CALL ZipPackageFolder::replaceByName( const OUString& aName, const uno:
if ( hasByName( aName ) )
removeByName( aName );
else
- throw NoSuchElementException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw NoSuchElementException(THROW_WHERE );
insertByName(aName, aElement);
}
@@ -729,7 +729,7 @@ void ZipPackageFolder::saveContents( OUString &rPath, std::vector < uno::Sequenc
}
if( bWritingFailed )
- throw uno::RuntimeException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw uno::RuntimeException(THROW_WHERE );
}
void ZipPackageFolder::releaseUpwardRef( void )
@@ -777,7 +777,7 @@ void SAL_CALL ZipPackageFolder::setPropertyValue( const OUString& aPropertyName,
{
// TODO/LATER: activate when zip ucp is ready
// if ( m_nFormat != embed::StorageFormats::PACKAGE )
- // throw UnknownPropertyException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ // throw UnknownPropertyException(THROW_WHERE );
aValue >>= sMediaType;
}
@@ -786,7 +786,7 @@ void SAL_CALL ZipPackageFolder::setPropertyValue( const OUString& aPropertyName,
else if ( aPropertyName == "Size" )
aValue >>= aEntry.nSize;
else
- throw UnknownPropertyException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw UnknownPropertyException(THROW_WHERE );
}
uno::Any SAL_CALL ZipPackageFolder::getPropertyValue( const OUString& PropertyName )
throw(UnknownPropertyException, WrappedTargetException, uno::RuntimeException, std::exception)
@@ -795,7 +795,7 @@ uno::Any SAL_CALL ZipPackageFolder::getPropertyValue( const OUString& PropertyNa
{
// TODO/LATER: activate when zip ucp is ready
// if ( m_nFormat != embed::StorageFormats::PACKAGE )
- // throw UnknownPropertyException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ // throw UnknownPropertyException(THROW_WHERE );
return uno::makeAny ( sMediaType );
}
@@ -804,7 +804,7 @@ uno::Any SAL_CALL ZipPackageFolder::getPropertyValue( const OUString& PropertyNa
else if ( PropertyName == "Size" )
return uno::makeAny ( aEntry.nSize );
else
- throw UnknownPropertyException(THROW_WHERE, uno::Reference< uno::XInterface >() );
+ throw UnknownPropertyException(THROW_WHERE );
}
void ZipPackageFolder::doInsertByName ( ZipPackageEntry *pEntry, bool bSetParent )