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 /svl | |
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 'svl')
-rw-r--r-- | svl/source/fsstor/fsstorage.cxx | 4 | ||||
-rw-r--r-- | svl/source/items/itemprop.cxx | 8 | ||||
-rw-r--r-- | svl/source/numbers/numfmuno.cxx | 6 |
3 files changed, 9 insertions, 9 deletions
diff --git a/svl/source/fsstor/fsstorage.cxx b/svl/source/fsstor/fsstorage.cxx index 6ba2a66baf3b..0b566b2ac15d 100644 --- a/svl/source/fsstor/fsstorage.cxx +++ b/svl/source/fsstor/fsstorage.cxx @@ -1003,7 +1003,7 @@ void SAL_CALL FSStorage::setPropertyValue( const OUString& aPropertyName, const if ( aPropertyName == "URL" || aPropertyName == "OpenMode" ) throw beans::PropertyVetoException(); // TODO else - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO } @@ -1019,7 +1019,7 @@ uno::Any SAL_CALL FSStorage::getPropertyValue( const OUString& aPropertyName ) else if ( aPropertyName == "OpenMode" ) return uno::makeAny( m_pImpl->m_nMode ); - throw beans::UnknownPropertyException(); // TODO + throw beans::UnknownPropertyException(aPropertyName); // TODO } diff --git a/svl/source/items/itemprop.cxx b/svl/source/items/itemprop.cxx index 6e0d046b93ed..5f4a4aacb6d5 100644 --- a/svl/source/items/itemprop.cxx +++ b/svl/source/items/itemprop.cxx @@ -107,7 +107,7 @@ beans::Property SfxItemPropertyMap::getPropertyByName( const OUString & rName ) { SfxItemPropertyHashMap_t::const_iterator aIter = m_pImpl->find(rName); if( aIter == m_pImpl->end() ) - throw UnknownPropertyException(); + throw UnknownPropertyException(rName); const SfxItemPropertySimpleEntry* pEntry = &aIter->second; beans::Property aProp; aProp.Name = rName; @@ -191,7 +191,7 @@ void SfxItemPropertySet::getPropertyValue( const OUString &rName, // detect which-id const SfxItemPropertySimpleEntry* pEntry = m_aMap.getByName( rName ); if ( !pEntry ) - throw UnknownPropertyException(); + throw UnknownPropertyException(rName); getPropertyValue( *pEntry,rSet, rAny ); } @@ -235,7 +235,7 @@ void SfxItemPropertySet::setPropertyValue( const OUString &rName, const SfxItemPropertySimpleEntry* pEntry = m_aMap.getByName( rName ); if ( !pEntry ) { - throw UnknownPropertyException(); + throw UnknownPropertyException(rName); } setPropertyValue(*pEntry, aVal, rSet); } @@ -264,7 +264,7 @@ PropertyState SfxItemPropertySet::getPropertyState(const OUString& rName, cons const SfxItemPropertySimpleEntry* pEntry = m_aMap.getByName( rName ); if( !pEntry || !pEntry->nWID ) { - throw UnknownPropertyException(); + throw UnknownPropertyException(rName); } sal_uInt16 nWhich = pEntry->nWID; diff --git a/svl/source/numbers/numfmuno.cxx b/svl/source/numbers/numfmuno.cxx index aa0d08584f12..5ed7aaa5137e 100644 --- a/svl/source/numbers/numfmuno.cxx +++ b/svl/source/numbers/numfmuno.cxx @@ -694,7 +694,7 @@ uno::Any SAL_CALL SvNumberFormatObj::getPropertyValue( const OUString& aProperty aRet <<= OUString(); } else - throw beans::UnknownPropertyException(); + throw beans::UnknownPropertyException(aPropertyName); return aRet; } @@ -847,7 +847,7 @@ void SAL_CALL SvNumberFormatSettingsObj::setPropertyValue( const OUString& aProp pFormatter->SetYear2000( nInt16 ); } else - throw beans::UnknownPropertyException(); + throw beans::UnknownPropertyException(aPropertyName); } @@ -874,7 +874,7 @@ uno::Any SAL_CALL SvNumberFormatSettingsObj::getPropertyValue( const OUString& a else if (aPropertyName == PROPERTYNAME_TWODIGIT) aRet <<= static_cast<sal_Int16>( pFormatter->GetYear2000() ); else - throw beans::UnknownPropertyException(); + throw beans::UnknownPropertyException(aPropertyName); return aRet; } |