diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-09-26 14:52:33 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-09-26 18:32:25 +0200 |
commit | b56a4eaf5eb856c36d3539dc7d2e6fa94b6551f8 (patch) | |
tree | d37ee64847c6e4eb5f748ef1d180d2651226ec53 /package | |
parent | e51a2917ab19156f5a5d2b9474a5a46a52e9e527 (diff) |
add property name when throwing css::uno::UnknownPropertyException
Change-Id: I17f06c9415b9d43b6d8896360e07216c2856367a
Reviewed-on: https://gerrit.libreoffice.org/79627
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'package')
-rw-r--r-- | package/source/xstor/ocompinstream.cxx | 6 | ||||
-rw-r--r-- | package/source/xstor/owriteablestream.cxx | 4 | ||||
-rw-r--r-- | package/source/xstor/xstorage.cxx | 10 | ||||
-rw-r--r-- | package/source/zippackage/ZipPackage.cxx | 6 | ||||
-rw-r--r-- | package/source/zippackage/ZipPackageFolder.cxx | 4 | ||||
-rw-r--r-- | package/source/zippackage/ZipPackageStream.cxx | 4 |
6 files changed, 17 insertions, 17 deletions
diff --git a/package/source/xstor/ocompinstream.cxx b/package/source/xstor/ocompinstream.cxx index ac4e3f101a07..8f15962d3bf0 100644 --- a/package/source/xstor/ocompinstream.cxx +++ b/package/source/xstor/ocompinstream.cxx @@ -509,7 +509,7 @@ void SAL_CALL OInputCompStream::setPropertyValue( const OUString& aPropertyName, [&aPropertyName](const beans::PropertyValue& rProp) { return rProp.Name == aPropertyName; })) throw beans::PropertyVetoException(); // TODO - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO } uno::Any SAL_CALL OInputCompStream::getPropertyValue( const OUString& aProp ) @@ -529,7 +529,7 @@ uno::Any SAL_CALL OInputCompStream::getPropertyValue( const OUString& aProp ) aPropertyName = aProp; if ( aPropertyName == "RelationsInfo" ) - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO // all the provided properties are accessible auto pProp = std::find_if(std::cbegin(m_aProperties), std::cend(m_aProperties), @@ -537,7 +537,7 @@ uno::Any SAL_CALL OInputCompStream::getPropertyValue( const OUString& aProp ) if (pProp != std::cend(m_aProperties)) return pProp->Value; - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO } void SAL_CALL OInputCompStream::addPropertyChangeListener( diff --git a/package/source/xstor/owriteablestream.cxx b/package/source/xstor/owriteablestream.cxx index 27a3d4daa5b7..e4935b94c81d 100644 --- a/package/source/xstor/owriteablestream.cxx +++ b/package/source/xstor/owriteablestream.cxx @@ -2878,7 +2878,7 @@ void SAL_CALL OWriteStream::setPropertyValue( const OUString& aPropertyName, con aValue >>= m_pImpl->m_nRelId; } else - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO m_pImpl->m_bHasDataToFlush = true; ModifyParentUnlockMutex_Impl( aGuard ); @@ -2937,7 +2937,7 @@ uno::Any SAL_CALL OWriteStream::getPropertyValue( const OUString& aProp ) return uno::makeAny( m_xSeekable->getLength() ); } - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO } void SAL_CALL OWriteStream::addPropertyChangeListener( diff --git a/package/source/xstor/xstorage.cxx b/package/source/xstor/xstorage.cxx index f87927339152..5a375e4bfcfa 100644 --- a/package/source/xstor/xstorage.cxx +++ b/package/source/xstor/xstorage.cxx @@ -4367,7 +4367,7 @@ void SAL_CALL OStorage::setPropertyValue( const OUString& aPropertyName, const u throw uno::RuntimeException( THROW_WHERE ); // TODO: Access denied if ( m_pData->m_nStorageType == embed::StorageFormats::ZIP ) - throw beans::UnknownPropertyException( THROW_WHERE ); + throw beans::UnknownPropertyException( aPropertyName ); else if ( m_pData->m_nStorageType == embed::StorageFormats::PACKAGE ) { if ( aPropertyName == "MediaType" ) @@ -4400,7 +4400,7 @@ void SAL_CALL OStorage::setPropertyValue( const OUString& aPropertyName, const u || aPropertyName == MEDIATYPE_FALLBACK_USED_PROPERTY ) throw beans::PropertyVetoException( THROW_WHERE ); else - throw beans::UnknownPropertyException( THROW_WHERE ); + throw beans::UnknownPropertyException( aPropertyName ); } else if ( m_pData->m_nStorageType == embed::StorageFormats::OFOPXML ) { @@ -4439,10 +4439,10 @@ void SAL_CALL OStorage::setPropertyValue( const OUString& aPropertyName, const u || aPropertyName == "IsRoot" ) throw beans::PropertyVetoException( THROW_WHERE ); else - throw beans::UnknownPropertyException( THROW_WHERE ); + throw beans::UnknownPropertyException( aPropertyName ); } else - throw beans::UnknownPropertyException( THROW_WHERE ); + throw beans::UnknownPropertyException( aPropertyName ); BroadcastModifiedIfNecessary(); } @@ -4538,7 +4538,7 @@ uno::Any SAL_CALL OStorage::getPropertyValue( const OUString& aPropertyName ) } } - throw beans::UnknownPropertyException( THROW_WHERE ); + throw beans::UnknownPropertyException(aPropertyName); } void SAL_CALL OStorage::addPropertyChangeListener( diff --git a/package/source/zippackage/ZipPackage.cxx b/package/source/zippackage/ZipPackage.cxx index 3f3858070a0c..7b2e705e45e5 100644 --- a/package/source/zippackage/ZipPackage.cxx +++ b/package/source/zippackage/ZipPackage.cxx @@ -1729,7 +1729,7 @@ uno::Reference< XPropertySetInfo > SAL_CALL ZipPackage::getPropertySetInfo() void SAL_CALL ZipPackage::setPropertyValue( const OUString& aPropertyName, const Any& aValue ) { if ( m_nFormat != embed::StorageFormats::PACKAGE ) - throw UnknownPropertyException(THROW_WHERE ); + throw UnknownPropertyException(aPropertyName); if (aPropertyName == HAS_ENCRYPTED_ENTRIES_PROPERTY ||aPropertyName == HAS_NONENCRYPTED_ENTRIES_PROPERTY @@ -1833,7 +1833,7 @@ void SAL_CALL ZipPackage::setPropertyValue( const OUString& aPropertyName, const m_nChecksumDigestID = xml::crypto::DigestID::SHA512_1K; } else - throw UnknownPropertyException(THROW_WHERE ); + throw UnknownPropertyException(aPropertyName); } Any SAL_CALL ZipPackage::getPropertyValue( const OUString& PropertyName ) @@ -1878,7 +1878,7 @@ Any SAL_CALL ZipPackage::getPropertyValue( const OUString& PropertyName ) { return Any(m_bMediaTypeFallbackUsed); } - throw UnknownPropertyException(THROW_WHERE ); + throw UnknownPropertyException(PropertyName); } void SAL_CALL ZipPackage::addPropertyChangeListener( const OUString& /*aPropertyName*/, const uno::Reference< XPropertyChangeListener >& /*xListener*/ ) { diff --git a/package/source/zippackage/ZipPackageFolder.cxx b/package/source/zippackage/ZipPackageFolder.cxx index 2dfbb72dc567..fdc7231059a6 100644 --- a/package/source/zippackage/ZipPackageFolder.cxx +++ b/package/source/zippackage/ZipPackageFolder.cxx @@ -377,7 +377,7 @@ void SAL_CALL ZipPackageFolder::setPropertyValue( const OUString& aPropertyName, else if ( aPropertyName == "Size" ) aValue >>= aEntry.nSize; else - throw UnknownPropertyException(THROW_WHERE ); + throw UnknownPropertyException(aPropertyName); } uno::Any SAL_CALL ZipPackageFolder::getPropertyValue( const OUString& PropertyName ) { @@ -394,7 +394,7 @@ uno::Any SAL_CALL ZipPackageFolder::getPropertyValue( const OUString& PropertyNa else if ( PropertyName == "Size" ) return uno::makeAny ( aEntry.nSize ); else - throw UnknownPropertyException(THROW_WHERE ); + throw UnknownPropertyException(PropertyName); } void ZipPackageFolder::doInsertByName ( ZipPackageEntry *pEntry, bool bSetParent ) diff --git a/package/source/zippackage/ZipPackageStream.cxx b/package/source/zippackage/ZipPackageStream.cxx index f685f891c649..745157cfd02e 100644 --- a/package/source/zippackage/ZipPackageStream.cxx +++ b/package/source/zippackage/ZipPackageStream.cxx @@ -1271,7 +1271,7 @@ void SAL_CALL ZipPackageStream::setPropertyValue( const OUString& aPropertyName, m_bCompressedIsSetFromOutside = true; } else - throw beans::UnknownPropertyException(THROW_WHERE ); + throw beans::UnknownPropertyException(aPropertyName); } Any SAL_CALL ZipPackageStream::getPropertyValue( const OUString& PropertyName ) @@ -1305,7 +1305,7 @@ Any SAL_CALL ZipPackageStream::getPropertyValue( const OUString& PropertyName ) return Any(m_aStorageEncryptionKeys); } else - throw beans::UnknownPropertyException(THROW_WHERE ); + throw beans::UnknownPropertyException(PropertyName); } void ZipPackageStream::setSize ( const sal_Int64 nNewSize ) |