diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-01-26 12:28:58 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-01-26 12:54:43 +0000 |
commit | e57ca02849c3d87142ff5ff9099a212e72b8139c (patch) | |
tree | bcce66b27261553c308779f3e8663a269ed3a671 /stoc/source/uriproc | |
parent | 8802ebd5172ec4bc412a59d136c82b77ab452281 (diff) |
Remove dynamic exception specifications
...(for now, from LIBO_INTERNAL_CODE only). See the mail thread starting at
<https://lists.freedesktop.org/archives/libreoffice/2017-January/076665.html>
"Dynamic Exception Specifications" for details.
Most changes have been done automatically by the rewriting loplugin:dynexcspec
(after enabling the rewriting mode, to be committed shortly). The way it only
removes exception specs from declarations if it also sees a definition, it
identified some dead declarations-w/o-definitions (that have been removed
manually) and some cases where a definition appeared in multiple include files
(which have also been cleaned up manually). There's also been cases of macro
paramters (that were used to abstract over exception specs) that have become
unused now (and been removed).
Furthermore, some code needed to be cleaned up manually
(avmedia/source/quicktime/ and connectivity/source/drivers/kab/), as I had no
configurations available that would actually build that code. Missing @throws
documentation has not been applied in such manual clean-up.
Change-Id: I3408691256c9b0c12bc5332de976743626e13960
Reviewed-on: https://gerrit.libreoffice.org/33574
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'stoc/source/uriproc')
-rw-r--r-- | stoc/source/uriproc/ExternalUriReferenceTranslator.cxx | 19 | ||||
-rw-r--r-- | stoc/source/uriproc/UriReference.cxx | 29 | ||||
-rw-r--r-- | stoc/source/uriproc/UriReference.hxx | 39 | ||||
-rw-r--r-- | stoc/source/uriproc/UriReferenceFactory.cxx | 74 | ||||
-rw-r--r-- | stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTexpand.cxx | 66 | ||||
-rw-r--r-- | stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx | 87 | ||||
-rw-r--r-- | stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx | 15 |
7 files changed, 112 insertions, 217 deletions
diff --git a/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx b/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx index c6ff6bbffa64..f618b4a7ae1c 100644 --- a/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx +++ b/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx @@ -49,41 +49,34 @@ public: Translator(const Translator&) = delete; Translator& operator=(const Translator&) = delete; - virtual OUString SAL_CALL getImplementationName() - throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getImplementationName() override; - virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) override; + virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) override; virtual css::uno::Sequence< OUString > SAL_CALL - getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) override; + getSupportedServiceNames() override; virtual OUString SAL_CALL - translateToInternal(OUString const & externalUriReference) - throw (css::uno::RuntimeException, std::exception) override; + translateToInternal(OUString const & externalUriReference) override; virtual OUString SAL_CALL - translateToExternal(OUString const & internalUriReference) - throw (css::uno::RuntimeException, std::exception) override; + translateToExternal(OUString const & internalUriReference) override; private: virtual ~Translator() override {} }; OUString Translator::getImplementationName() - throw (css::uno::RuntimeException, std::exception) { return OUString("com.sun.star.comp.uri.ExternalUriReferenceTranslator"); } sal_Bool Translator::supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) { return cppu::supportsService(this, serviceName); } css::uno::Sequence< OUString > Translator::getSupportedServiceNames() - throw (css::uno::RuntimeException, std::exception) { css::uno::Sequence< OUString > s { "com.sun.star.uri.ExternalUriReferenceTranslator" }; return s; @@ -91,7 +84,6 @@ css::uno::Sequence< OUString > Translator::getSupportedServiceNames() OUString Translator::translateToInternal( OUString const & externalUriReference) - throw (css::uno::RuntimeException, std::exception) { if (!externalUriReference.matchIgnoreAsciiCase("file:/")) { @@ -140,7 +132,6 @@ OUString Translator::translateToInternal( OUString Translator::translateToExternal( OUString const & internalUriReference) - throw (css::uno::RuntimeException, std::exception) { if (!internalUriReference.matchIgnoreAsciiCase("file://")) { diff --git a/stoc/source/uriproc/UriReference.cxx b/stoc/source/uriproc/UriReference.cxx index 57d950e842ba..2baa1f3b9b20 100644 --- a/stoc/source/uriproc/UriReference.cxx +++ b/stoc/source/uriproc/UriReference.cxx @@ -51,7 +51,7 @@ UriReference::UriReference( UriReference::~UriReference() {} -OUString UriReference::getUriReference() throw (css::uno::RuntimeException) +OUString UriReference::getUriReference() { osl::MutexGuard g(m_mutex); OUStringBuffer buf; @@ -67,13 +67,12 @@ OUString UriReference::getUriReference() throw (css::uno::RuntimeException) return buf.makeStringAndClear(); } -bool UriReference::isAbsolute() throw (css::uno::RuntimeException) { +bool UriReference::isAbsolute() { return !m_scheme.isEmpty(); } OUString UriReference::getSchemeSpecificPart() - throw (css::uno::RuntimeException) { osl::MutexGuard g(m_mutex); OUStringBuffer buf; @@ -81,33 +80,33 @@ OUString UriReference::getSchemeSpecificPart() return buf.makeStringAndClear(); } -bool UriReference::isHierarchical() throw (css::uno::RuntimeException) { +bool UriReference::isHierarchical() { osl::MutexGuard g(m_mutex); return m_isHierarchical; } -bool UriReference::hasAuthority() throw (css::uno::RuntimeException) { +bool UriReference::hasAuthority() { osl::MutexGuard g(m_mutex); return m_hasAuthority; } -OUString UriReference::getAuthority() throw (css::uno::RuntimeException) { +OUString UriReference::getAuthority() { osl::MutexGuard g(m_mutex); return m_authority; } -OUString UriReference::getPath() throw (css::uno::RuntimeException) { +OUString UriReference::getPath() { osl::MutexGuard g(m_mutex); return m_path; } -bool UriReference::hasRelativePath() throw (css::uno::RuntimeException) { +bool UriReference::hasRelativePath() { osl::MutexGuard g(m_mutex); return m_isHierarchical && !m_hasAuthority && (m_path.isEmpty() || m_path[0] != '/'); } -sal_Int32 UriReference::getPathSegmentCount() throw (css::uno::RuntimeException) +sal_Int32 UriReference::getPathSegmentCount() { osl::MutexGuard g(m_mutex); if (!m_isHierarchical || m_path.isEmpty()) { @@ -126,7 +125,6 @@ sal_Int32 UriReference::getPathSegmentCount() throw (css::uno::RuntimeException) } OUString UriReference::getPathSegment(sal_Int32 index) - throw (css::uno::RuntimeException) { osl::MutexGuard g(m_mutex); if (m_isHierarchical && !m_path.isEmpty() && index >= 0) { @@ -144,35 +142,34 @@ OUString UriReference::getPathSegment(sal_Int32 index) return OUString(); } -bool UriReference::hasQuery() throw (css::uno::RuntimeException) { +bool UriReference::hasQuery() { osl::MutexGuard g(m_mutex); return m_hasQuery; } -OUString UriReference::getQuery() throw (css::uno::RuntimeException) { +OUString UriReference::getQuery() { osl::MutexGuard g(m_mutex); return m_query; } -bool UriReference::hasFragment() throw (css::uno::RuntimeException) { +bool UriReference::hasFragment() { osl::MutexGuard g(m_mutex); return m_hasFragment; } -OUString UriReference::getFragment() throw (css::uno::RuntimeException) { +OUString UriReference::getFragment() { osl::MutexGuard g(m_mutex); return m_fragment; } void UriReference::setFragment(OUString const & fragment) - throw (css::uno::RuntimeException) { osl::MutexGuard g(m_mutex); m_hasFragment = true; m_fragment = fragment; } -void UriReference::clearFragment() throw (css::uno::RuntimeException) { +void UriReference::clearFragment() { osl::MutexGuard g(m_mutex); m_hasFragment = false; m_fragment.clear(); diff --git a/stoc/source/uriproc/UriReference.hxx b/stoc/source/uriproc/UriReference.hxx index e052eee03f52..05fdc37f6e09 100644 --- a/stoc/source/uriproc/UriReference.hxx +++ b/stoc/source/uriproc/UriReference.hxx @@ -38,60 +38,55 @@ public: ~UriReference(); /// @throws css::uno::RuntimeException - OUString getUriReference() - throw (css::uno::RuntimeException); + OUString getUriReference(); /// @throws css::uno::RuntimeException - bool isAbsolute() throw (css::uno::RuntimeException); + bool isAbsolute(); /// @throws css::uno::RuntimeException - const OUString& getScheme() throw (css::uno::RuntimeException) { return m_scheme;} + const OUString& getScheme() { return m_scheme;} /// @throws css::uno::RuntimeException - OUString getSchemeSpecificPart() - throw (css::uno::RuntimeException); + OUString getSchemeSpecificPart(); /// @throws css::uno::RuntimeException - bool isHierarchical() throw (css::uno::RuntimeException); + bool isHierarchical(); /// @throws css::uno::RuntimeException - bool hasAuthority() throw (css::uno::RuntimeException); + bool hasAuthority(); /// @throws css::uno::RuntimeException - OUString getAuthority() throw (css::uno::RuntimeException); + OUString getAuthority(); /// @throws css::uno::RuntimeException - OUString getPath() throw (css::uno::RuntimeException); + OUString getPath(); /// @throws css::uno::RuntimeException - bool hasRelativePath() throw (css::uno::RuntimeException); + bool hasRelativePath(); /// @throws css::uno::RuntimeException - sal_Int32 getPathSegmentCount() - throw (css::uno::RuntimeException); + sal_Int32 getPathSegmentCount(); /// @throws css::uno::RuntimeException - OUString getPathSegment(sal_Int32 index) - throw (css::uno::RuntimeException); + OUString getPathSegment(sal_Int32 index); /// @throws css::uno::RuntimeException - bool hasQuery() throw (css::uno::RuntimeException); + bool hasQuery(); /// @throws css::uno::RuntimeException - OUString getQuery() throw (css::uno::RuntimeException); + OUString getQuery(); /// @throws css::uno::RuntimeException - bool hasFragment() throw (css::uno::RuntimeException); + bool hasFragment(); /// @throws css::uno::RuntimeException - OUString getFragment() throw (css::uno::RuntimeException); + OUString getFragment(); /// @throws css::uno::RuntimeException - void setFragment(OUString const & fragment) - throw (css::uno::RuntimeException); + void setFragment(OUString const & fragment); /// @throws css::uno::RuntimeException - void clearFragment() throw (css::uno::RuntimeException); + void clearFragment(); osl::Mutex m_mutex; OUString m_scheme; diff --git a/stoc/source/uriproc/UriReferenceFactory.cxx b/stoc/source/uriproc/UriReferenceFactory.cxx index 11f02ca50b3e..71efcf275945 100644 --- a/stoc/source/uriproc/UriReferenceFactory.cxx +++ b/stoc/source/uriproc/UriReferenceFactory.cxx @@ -107,72 +107,55 @@ public: UriReference(const UriReference&) = delete; UriReference& operator=(const UriReference&) = delete; - virtual OUString SAL_CALL getUriReference() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getUriReference() override { return m_base.getUriReference(); } - virtual sal_Bool SAL_CALL isAbsolute() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL isAbsolute() override { return m_base.isAbsolute(); } - virtual OUString SAL_CALL getScheme() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getScheme() override { return m_base.getScheme(); } - virtual OUString SAL_CALL getSchemeSpecificPart() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getSchemeSpecificPart() override { return m_base.getSchemeSpecificPart(); } - virtual sal_Bool SAL_CALL isHierarchical() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL isHierarchical() override { return m_base.isHierarchical(); } - virtual sal_Bool SAL_CALL hasAuthority() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasAuthority() override { return m_base.hasAuthority(); } - virtual OUString SAL_CALL getAuthority() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getAuthority() override { return m_base.getAuthority(); } - virtual OUString SAL_CALL getPath() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getPath() override { return m_base.getPath(); } - virtual sal_Bool SAL_CALL hasRelativePath() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasRelativePath() override { return m_base.hasRelativePath(); } - virtual sal_Int32 SAL_CALL getPathSegmentCount() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Int32 SAL_CALL getPathSegmentCount() override { return m_base.getPathSegmentCount(); } - virtual OUString SAL_CALL getPathSegment(sal_Int32 index) - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getPathSegment(sal_Int32 index) override { return m_base.getPathSegment(index); } - virtual sal_Bool SAL_CALL hasQuery() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasQuery() override { return m_base.hasQuery(); } - virtual OUString SAL_CALL getQuery() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getQuery() override { return m_base.getQuery(); } - virtual sal_Bool SAL_CALL hasFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasFragment() override { return m_base.hasFragment(); } - virtual OUString SAL_CALL getFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getFragment() override { return m_base.getFragment(); } - virtual void SAL_CALL setFragment(OUString const & fragment) - throw (css::uno::RuntimeException, std::exception) override + virtual void SAL_CALL setFragment(OUString const & fragment) override { m_base.setFragment(fragment); } - virtual void SAL_CALL clearFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual void SAL_CALL clearFragment() override { m_base.clearFragment(); } private: @@ -269,26 +252,22 @@ public: Factory(const Factory&) = delete; Factory& operator=(const Factory&) = delete; - virtual OUString SAL_CALL getImplementationName() - throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getImplementationName() override; - virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) override; + virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) override; virtual css::uno::Sequence< OUString > SAL_CALL - getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) override; + getSupportedServiceNames() override; virtual css::uno::Reference< css::uri::XUriReference > SAL_CALL - parse(OUString const & uriReference) - throw (css::uno::RuntimeException, std::exception) override; + parse(OUString const & uriReference) override; virtual css::uno::Reference< css::uri::XUriReference > SAL_CALL makeAbsolute( css::uno::Reference< css::uri::XUriReference > const & baseUriReference, css::uno::Reference< css::uri::XUriReference > const & uriReference, sal_Bool processSpecialBaseSegments, - css::uri::RelativeUriExcessParentSegments excessParentSegments) - throw (css::uno::RuntimeException, std::exception) override; + css::uri::RelativeUriExcessParentSegments excessParentSegments) override; virtual css::uno::Reference< css::uri::XUriReference > SAL_CALL makeRelative( @@ -296,8 +275,7 @@ public: css::uno::Reference< css::uri::XUriReference > const & uriReference, sal_Bool preferAuthorityOverRelativePath, sal_Bool preferAbsoluteOverRelativePath, - sal_Bool encodeRetainedSpecialSegments) - throw (css::uno::RuntimeException, std::exception) override; + sal_Bool encodeRetainedSpecialSegments) override; private: virtual ~Factory() override {} @@ -310,19 +288,16 @@ private: }; OUString Factory::getImplementationName() - throw (css::uno::RuntimeException, std::exception) { return OUString("com.sun.star.comp.uri.UriReferenceFactory"); } sal_Bool Factory::supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) { return cppu::supportsService(this, serviceName); } css::uno::Sequence< OUString > Factory::getSupportedServiceNames() - throw (css::uno::RuntimeException, std::exception) { css::uno::Sequence< OUString > s { "com.sun.star.uri.UriReferenceFactory" }; return s; @@ -330,7 +305,6 @@ css::uno::Sequence< OUString > Factory::getSupportedServiceNames() css::uno::Reference< css::uri::XUriReference > Factory::parse( OUString const & uriReference) - throw (css::uno::RuntimeException, std::exception) { sal_Int32 fragment = uriReference.indexOf('#'); if (fragment == -1) { @@ -402,7 +376,6 @@ css::uno::Reference< css::uri::XUriReference > Factory::makeAbsolute( css::uno::Reference< css::uri::XUriReference > const & uriReference, sal_Bool processSpecialBaseSegments, css::uri::RelativeUriExcessParentSegments excessParentSegments) - throw (css::uno::RuntimeException, std::exception) { if (!baseUriReference.is() || !baseUriReference->isAbsolute() || !baseUriReference->isHierarchical() || !uriReference.is()) { @@ -518,7 +491,6 @@ css::uno::Reference< css::uri::XUriReference > Factory::makeRelative( sal_Bool preferAuthorityOverRelativePath, sal_Bool preferAbsoluteOverRelativePath, sal_Bool encodeRetainedSpecialSegments) - throw (css::uno::RuntimeException, std::exception) { if (!baseUriReference.is() || !baseUriReference->isAbsolute() || !baseUriReference->isHierarchical() || !uriReference.is()) { diff --git a/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTexpand.cxx b/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTexpand.cxx index 1bc7bbefcf42..d246f07c9221 100644 --- a/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTexpand.cxx +++ b/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTexpand.cxx @@ -67,73 +67,59 @@ public: UrlReference(const UrlReference&) = delete; UrlReference& operator=(const UrlReference&) = delete; - virtual OUString SAL_CALL getUriReference() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getUriReference() override { return base_.getUriReference(); } - virtual sal_Bool SAL_CALL isAbsolute() throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL isAbsolute() override { return base_.isAbsolute(); } - virtual OUString SAL_CALL getScheme() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getScheme() override { return base_.getScheme(); } - virtual OUString SAL_CALL getSchemeSpecificPart() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getSchemeSpecificPart() override { return base_.getSchemeSpecificPart(); } - virtual sal_Bool SAL_CALL isHierarchical() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL isHierarchical() override { return base_.isHierarchical(); } - virtual sal_Bool SAL_CALL hasAuthority() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasAuthority() override { return base_.hasAuthority(); } - virtual OUString SAL_CALL getAuthority() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getAuthority() override { return base_.getAuthority(); } - virtual OUString SAL_CALL getPath() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getPath() override { return base_.getPath(); } - virtual sal_Bool SAL_CALL hasRelativePath() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasRelativePath() override { return base_.hasRelativePath(); } - virtual ::sal_Int32 SAL_CALL getPathSegmentCount() - throw (css::uno::RuntimeException, std::exception) override + virtual ::sal_Int32 SAL_CALL getPathSegmentCount() override { return base_.getPathSegmentCount(); } - virtual OUString SAL_CALL getPathSegment(sal_Int32 index) - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getPathSegment(sal_Int32 index) override { return base_.getPathSegment(index); } - virtual sal_Bool SAL_CALL hasQuery() throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasQuery() override { return base_.hasQuery(); } - virtual OUString SAL_CALL getQuery() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getQuery() override { return base_.getQuery(); } - virtual sal_Bool SAL_CALL hasFragment() throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasFragment() override { return base_.hasFragment(); } - virtual OUString SAL_CALL getFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getFragment() override { return base_.getFragment(); } - virtual void SAL_CALL setFragment(OUString const & fragment) - throw (css::uno::RuntimeException, std::exception) override + virtual void SAL_CALL setFragment(OUString const & fragment) override { base_.setFragment(fragment); } - virtual void SAL_CALL clearFragment() throw (css::uno::RuntimeException, std::exception) override + virtual void SAL_CALL clearFragment() override { base_.clearFragment(); } virtual OUString SAL_CALL expand( - css::uno::Reference< css::util::XMacroExpander > const & expander) - throw (css::lang::IllegalArgumentException, css::uno::RuntimeException, std::exception) override; + css::uno::Reference< css::util::XMacroExpander > const & expander) override; private: virtual ~UrlReference() override {} @@ -143,7 +129,6 @@ private: OUString UrlReference::expand( css::uno::Reference< css::util::XMacroExpander > const & expander) - throw (css::lang::IllegalArgumentException, css::uno::RuntimeException, std::exception) { OSL_ASSERT(expander.is()); return expander->expandMacros( @@ -161,40 +146,34 @@ public: Parser(const Parser&) = delete; Parser& operator=(const Parser&) = delete; - virtual OUString SAL_CALL getImplementationName() - throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getImplementationName() override; virtual sal_Bool SAL_CALL supportsService( - OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) override; + OUString const & serviceName) override; virtual css::uno::Sequence< OUString > SAL_CALL - getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) override; + getSupportedServiceNames() override; virtual css::uno::Reference< css::uri::XUriReference > SAL_CALL parse( OUString const & scheme, - OUString const & schemeSpecificPart) - throw (css::uno::RuntimeException, std::exception) override; + OUString const & schemeSpecificPart) override; private: virtual ~Parser() override {} }; OUString Parser::getImplementationName() - throw (css::uno::RuntimeException, std::exception) { return OUString("com.sun.star.comp.uri.UriSchemeParser_vndDOTsunDOTstarDOTexpand"); } sal_Bool Parser::supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) { return cppu::supportsService(this, serviceName); } css::uno::Sequence< OUString > Parser::getSupportedServiceNames() - throw (css::uno::RuntimeException, std::exception) { css::uno::Sequence< OUString > s { "com.sun.star.uri.UriSchemeParser_vndDOTsunDOTstarDOTexpand" }; return s; @@ -202,7 +181,6 @@ css::uno::Sequence< OUString > Parser::getSupportedServiceNames() css::uno::Reference< css::uri::XUriReference > Parser::parse( OUString const & scheme, OUString const & schemeSpecificPart) - throw (css::uno::RuntimeException, std::exception) { if (!parseSchemeSpecificPart(schemeSpecificPart)) { return css::uno::Reference< css::uri::XUriReference >(); diff --git a/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx b/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx index c63093d79ce7..c57670e27f20 100644 --- a/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx +++ b/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx @@ -201,87 +201,66 @@ public: UrlReference(const UrlReference&) = delete; UrlReference& operator=(const UrlReference&) = delete; - virtual OUString SAL_CALL getUriReference() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getUriReference() override { return m_base.getUriReference(); } - virtual sal_Bool SAL_CALL isAbsolute() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL isAbsolute() override { return m_base.isAbsolute(); } - virtual OUString SAL_CALL getScheme() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getScheme() override { return m_base.getScheme(); } - virtual OUString SAL_CALL getSchemeSpecificPart() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getSchemeSpecificPart() override { return m_base.getSchemeSpecificPart(); } - virtual sal_Bool SAL_CALL isHierarchical() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL isHierarchical() override { return m_base.isHierarchical(); } - virtual sal_Bool SAL_CALL hasAuthority() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasAuthority() override { return m_base.hasAuthority(); } - virtual OUString SAL_CALL getAuthority() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getAuthority() override { return m_base.getAuthority(); } - virtual OUString SAL_CALL getPath() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getPath() override { return m_base.getPath(); } - virtual sal_Bool SAL_CALL hasRelativePath() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasRelativePath() override { return m_base.hasRelativePath(); } - virtual sal_Int32 SAL_CALL getPathSegmentCount() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Int32 SAL_CALL getPathSegmentCount() override { return m_base.getPathSegmentCount(); } - virtual OUString SAL_CALL getPathSegment(sal_Int32 index) - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getPathSegment(sal_Int32 index) override { return m_base.getPathSegment(index); } - virtual sal_Bool SAL_CALL hasQuery() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasQuery() override { return m_base.hasQuery(); } - virtual OUString SAL_CALL getQuery() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getQuery() override { return m_base.getQuery(); } - virtual sal_Bool SAL_CALL hasFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual sal_Bool SAL_CALL hasFragment() override { return m_base.hasFragment(); } - virtual OUString SAL_CALL getFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual OUString SAL_CALL getFragment() override { return m_base.getFragment(); } - virtual void SAL_CALL setFragment(OUString const & fragment) - throw (css::uno::RuntimeException, std::exception) override + virtual void SAL_CALL setFragment(OUString const & fragment) override { m_base.setFragment(fragment); } - virtual void SAL_CALL clearFragment() - throw (css::uno::RuntimeException, std::exception) override + virtual void SAL_CALL clearFragment() override { m_base.clearFragment(); } - virtual OUString SAL_CALL getName() throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getName() override; - virtual void SAL_CALL setName(OUString const & name) - throw (css::uno::RuntimeException, css::lang::IllegalArgumentException, std::exception) override; + virtual void SAL_CALL setName(OUString const & name) override; - virtual sal_Bool SAL_CALL hasParameter(OUString const & key) - throw (css::uno::RuntimeException, std::exception) override; + virtual sal_Bool SAL_CALL hasParameter(OUString const & key) override; - virtual OUString SAL_CALL getParameter(OUString const & key) - throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getParameter(OUString const & key) override; - virtual void SAL_CALL setParameter(OUString const & key, OUString const & value) - throw (css::uno::RuntimeException, css::lang::IllegalArgumentException, std::exception) override; + virtual void SAL_CALL setParameter(OUString const & key, OUString const & value) override; private: virtual ~UrlReference() override {} @@ -291,13 +270,13 @@ private: stoc::uriproc::UriReference m_base; }; -OUString UrlReference::getName() throw (css::uno::RuntimeException, std::exception) { +OUString UrlReference::getName() { osl::MutexGuard g(m_base.m_mutex); sal_Int32 i = 0; return parsePart(m_base.m_path, true, &i); } -void SAL_CALL UrlReference::setName(OUString const & name) throw (css::uno::RuntimeException, css::lang::IllegalArgumentException, std::exception) +void SAL_CALL UrlReference::setName(OUString const & name) { if (name.isEmpty()) throw css::lang::IllegalArgumentException( @@ -314,14 +293,12 @@ void SAL_CALL UrlReference::setName(OUString const & name) throw (css::uno::Runt } sal_Bool UrlReference::hasParameter(OUString const & key) - throw (css::uno::RuntimeException, std::exception) { osl::MutexGuard g(m_base.m_mutex); return findParameter(key) >= 0; } OUString UrlReference::getParameter(OUString const & key) - throw (css::uno::RuntimeException, std::exception) { osl::MutexGuard g(m_base.m_mutex); sal_Int32 i = findParameter(key); @@ -329,7 +306,6 @@ OUString UrlReference::getParameter(OUString const & key) } void UrlReference::setParameter(OUString const & key, OUString const & value) - throw (css::uno::RuntimeException, css::lang::IllegalArgumentException, std::exception) { if (key.isEmpty()) throw css::lang::IllegalArgumentException( @@ -386,38 +362,32 @@ public: Parser(const Parser&) = delete; Parser& operator=(const Parser&) = delete; - virtual OUString SAL_CALL getImplementationName() - throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getImplementationName() override; - virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) override; + virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) override; virtual css::uno::Sequence< OUString > SAL_CALL - getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) override; + getSupportedServiceNames() override; virtual css::uno::Reference< css::uri::XUriReference > SAL_CALL parse( - OUString const & scheme, OUString const & schemeSpecificPart) - throw (css::uno::RuntimeException, std::exception) override; + OUString const & scheme, OUString const & schemeSpecificPart) override; private: virtual ~Parser() override {} }; OUString Parser::getImplementationName() - throw (css::uno::RuntimeException, std::exception) { return OUString("com.sun.star.comp.uri.UriSchemeParser_vndDOTsunDOTstarDOTscript"); } sal_Bool Parser::supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) { return cppu::supportsService(this, serviceName); } css::uno::Sequence< OUString > Parser::getSupportedServiceNames() - throw (css::uno::RuntimeException, std::exception) { css::uno::Sequence< OUString > s { "com.sun.star.uri.UriSchemeParser_vndDOTsunDOTstarDOTscript" }; return s; @@ -426,7 +396,6 @@ css::uno::Sequence< OUString > Parser::getSupportedServiceNames() css::uno::Reference< css::uri::XUriReference > Parser::parse( OUString const & scheme, OUString const & schemeSpecificPart) - throw (css::uno::RuntimeException, std::exception) { if (!parseSchemeSpecificPart(schemeSpecificPart)) { return nullptr; diff --git a/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx b/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx index 5d2b25852fa4..dc7fbf0015ff 100644 --- a/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx +++ b/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx @@ -54,19 +54,16 @@ public: Factory(const Factory&) = delete; Factory& operator=(const Factory&) = delete; - virtual OUString SAL_CALL getImplementationName() - throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL getImplementationName() override; - virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) override; + virtual sal_Bool SAL_CALL supportsService(OUString const & serviceName) override; virtual css::uno::Sequence< OUString > SAL_CALL - getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) override; + getSupportedServiceNames() override; virtual css::uno::Reference< css::uri::XUriReference > SAL_CALL createVndSunStarPkgUrlReference( - css::uno::Reference< css::uri::XUriReference > const & authority) - throw (css::uno::RuntimeException, std::exception) override; + css::uno::Reference< css::uri::XUriReference > const & authority) override; private: virtual ~Factory() override {} @@ -75,19 +72,16 @@ private: }; OUString Factory::getImplementationName() - throw (css::uno::RuntimeException, std::exception) { return OUString("com.sun.star.comp.uri.VndSunStarPkgUrlReferenceFactory"); } sal_Bool Factory::supportsService(OUString const & serviceName) - throw (css::uno::RuntimeException, std::exception) { return cppu::supportsService(this, serviceName); } css::uno::Sequence< OUString > Factory::getSupportedServiceNames() - throw (css::uno::RuntimeException, std::exception) { css::uno::Sequence< OUString > s { "com.sun.star.uri.VndSunStarPkgUrlReferenceFactory" }; return s; @@ -96,7 +90,6 @@ css::uno::Sequence< OUString > Factory::getSupportedServiceNames() css::uno::Reference< css::uri::XUriReference > Factory::createVndSunStarPkgUrlReference( css::uno::Reference< css::uri::XUriReference > const & authority) - throw (css::uno::RuntimeException, std::exception) { OSL_ASSERT(authority.is()); if (authority->isAbsolute() && !authority->hasFragment()) { |