diff options
Diffstat (limited to 'comphelper/source/xml')
-rw-r--r-- | comphelper/source/xml/attributelist.cxx | 14 | ||||
-rw-r--r-- | comphelper/source/xml/ofopxmlhelper.cxx | 32 |
2 files changed, 16 insertions, 30 deletions
diff --git a/comphelper/source/xml/attributelist.cxx b/comphelper/source/xml/attributelist.cxx index cefede87dfc9..64daa2a14320 100644 --- a/comphelper/source/xml/attributelist.cxx +++ b/comphelper/source/xml/attributelist.cxx @@ -53,17 +53,17 @@ struct AttributeList_Impl ::std::vector<struct TagAttribute_Impl> vecAttribute; }; -sal_Int16 SAL_CALL AttributeList::getLength() throw( css::uno::RuntimeException, std::exception ) +sal_Int16 SAL_CALL AttributeList::getLength() { return (sal_Int16)(m_pImpl->vecAttribute.size()); } -OUString SAL_CALL AttributeList::getNameByIndex(sal_Int16 i) throw( css::uno::RuntimeException, std::exception ) +OUString SAL_CALL AttributeList::getNameByIndex(sal_Int16 i) { return ( i < static_cast < sal_Int16 > (m_pImpl->vecAttribute.size()) ) ? m_pImpl->vecAttribute[i].sName : OUString(); } -OUString SAL_CALL AttributeList::getTypeByIndex(sal_Int16 i) throw( css::uno::RuntimeException, std::exception ) +OUString SAL_CALL AttributeList::getTypeByIndex(sal_Int16 i) { if( i < static_cast < sal_Int16 > (m_pImpl->vecAttribute.size() ) ) { return m_pImpl->vecAttribute[i].sType; @@ -71,12 +71,12 @@ OUString SAL_CALL AttributeList::getTypeByIndex(sal_Int16 i) throw( css::uno::Ru return OUString(); } -OUString SAL_CALL AttributeList::getValueByIndex(sal_Int16 i) throw( css::uno::RuntimeException, std::exception ) +OUString SAL_CALL AttributeList::getValueByIndex(sal_Int16 i) { return ( i < static_cast < sal_Int16 > (m_pImpl->vecAttribute.size() ) ) ? m_pImpl->vecAttribute[i].sValue : OUString(); } -OUString SAL_CALL AttributeList::getTypeByName( const OUString& sName ) throw( css::uno::RuntimeException, std::exception ) +OUString SAL_CALL AttributeList::getTypeByName( const OUString& sName ) { ::std::vector<struct TagAttribute_Impl>::iterator ii = m_pImpl->vecAttribute.begin(); @@ -88,7 +88,7 @@ OUString SAL_CALL AttributeList::getTypeByName( const OUString& sName ) throw( c return OUString(); } -OUString SAL_CALL AttributeList::getValueByName(const OUString& sName) throw( css::uno::RuntimeException, std::exception ) +OUString SAL_CALL AttributeList::getValueByName(const OUString& sName) { ::std::vector<struct TagAttribute_Impl>::iterator ii = m_pImpl->vecAttribute.begin(); @@ -127,7 +127,7 @@ void AttributeList::Clear() m_pImpl->vecAttribute.clear(); } -css::uno::Reference< css::util::XCloneable > AttributeList::createClone() throw (css::uno::RuntimeException, std::exception) +css::uno::Reference< css::util::XCloneable > AttributeList::createClone() { AttributeList *p = new AttributeList( *this ); diff --git a/comphelper/source/xml/ofopxmlhelper.cxx b/comphelper/source/xml/ofopxmlhelper.cxx index eebe3c2e6186..e1633fe3432b 100644 --- a/comphelper/source/xml/ofopxmlhelper.cxx +++ b/comphelper/source/xml/ofopxmlhelper.cxx @@ -72,14 +72,14 @@ public: explicit OFOPXMLHelper_Impl( sal_uInt16 nFormat ); // must not be created directly // XDocumentHandler - virtual void SAL_CALL startDocument() throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL endDocument() throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL startElement( const OUString& aName, const css::uno::Reference< css::xml::sax::XAttributeList >& xAttribs ) throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL endElement( const OUString& aName ) throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL characters( const OUString& aChars ) throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL ignorableWhitespace( const OUString& aWhitespaces ) throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL processingInstruction( const OUString& aTarget, const OUString& aData ) throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; - virtual void SAL_CALL setDocumentLocator( const css::uno::Reference< css::xml::sax::XLocator >& xLocator ) throw (css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override; + virtual void SAL_CALL startDocument() override; + virtual void SAL_CALL endDocument() override; + virtual void SAL_CALL startElement( const OUString& aName, const css::uno::Reference< css::xml::sax::XAttributeList >& xAttribs ) override; + virtual void SAL_CALL endElement( const OUString& aName ) override; + virtual void SAL_CALL characters( const OUString& aChars ) override; + virtual void SAL_CALL ignorableWhitespace( const OUString& aWhitespaces ) override; + virtual void SAL_CALL processingInstruction( const OUString& aTarget, const OUString& aData ) override; + virtual void SAL_CALL setDocumentLocator( const css::uno::Reference< css::xml::sax::XLocator >& xLocator ) override; }; @@ -89,14 +89,12 @@ namespace OFOPXMLHelper { static uno::Sequence<uno::Sequence< beans::StringPair>> ReadSequence_Impl( const uno::Reference<io::XInputStream>& xInStream, const OUString& aStringID, sal_uInt16 nFormat, - const uno::Reference<uno::XComponentContext>& xContext) -throw (uno::Exception); + const uno::Reference<uno::XComponentContext>& xContext); uno::Sequence< uno::Sequence< beans::StringPair > > ReadRelationsInfoSequence( const uno::Reference< io::XInputStream >& xInStream, const OUString & aStreamName, const uno::Reference< uno::XComponentContext >& rContext ) - throw( uno::Exception ) { OUString aStringID = "_rels/" + aStreamName; return ReadSequence_Impl( xInStream, aStringID, RELATIONINFO_FORMAT, rContext ); @@ -106,7 +104,6 @@ uno::Sequence< uno::Sequence< beans::StringPair > > ReadRelationsInfoSequence( uno::Sequence< uno::Sequence< beans::StringPair > > ReadContentTypeSequence( const uno::Reference< io::XInputStream >& xInStream, const uno::Reference< uno::XComponentContext >& rContext ) - throw( uno::Exception ) { OUString aStringID = "[Content_Types].xml"; return ReadSequence_Impl( xInStream, aStringID, CONTENTTYPE_FORMAT, rContext ); @@ -117,7 +114,6 @@ void WriteRelationsInfoSequence( const uno::Reference< io::XOutputStream >& xOutStream, const uno::Sequence< uno::Sequence< beans::StringPair > >& aSequence, const uno::Reference< uno::XComponentContext >& rContext ) - throw( uno::Exception ) { if ( !xOutStream.is() ) throw uno::RuntimeException(); @@ -178,7 +174,6 @@ void WriteContentSequence( const uno::Sequence< beans::StringPair >& aDefaultsSequence, const uno::Sequence< beans::StringPair >& aOverridesSequence, const uno::Reference< uno::XComponentContext >& rContext ) - throw( uno::Exception ) { if ( !xOutStream.is() ) throw uno::RuntimeException(); @@ -239,7 +234,6 @@ uno::Sequence< uno::Sequence< beans::StringPair > > ReadSequence_Impl( const uno::Reference< io::XInputStream >& xInStream, const OUString& aStringID, sal_uInt16 nFormat, const uno::Reference< uno::XComponentContext >& rContext ) - throw( uno::Exception ) { if ( !rContext.is() || !xInStream.is() || nFormat > FORMAT_MAX_ID ) throw uno::RuntimeException(); @@ -287,19 +281,16 @@ uno::Sequence< uno::Sequence< beans::StringPair > > const & OFOPXMLHelper_Impl:: void SAL_CALL OFOPXMLHelper_Impl::startDocument() - throw(css::xml::sax::SAXException, uno::RuntimeException, std::exception) { } void SAL_CALL OFOPXMLHelper_Impl::endDocument() - throw(css::xml::sax::SAXException, uno::RuntimeException, std::exception) { } void SAL_CALL OFOPXMLHelper_Impl::startElement( const OUString& aName, const uno::Reference< css::xml::sax::XAttributeList >& xAttribs ) - throw( css::xml::sax::SAXException, uno::RuntimeException, std::exception ) { if ( m_nFormat == RELATIONINFO_FORMAT ) { @@ -442,7 +433,6 @@ void SAL_CALL OFOPXMLHelper_Impl::startElement( const OUString& aName, const uno void SAL_CALL OFOPXMLHelper_Impl::endElement( const OUString& aName ) - throw( css::xml::sax::SAXException, uno::RuntimeException, std::exception ) { if ( m_nFormat == RELATIONINFO_FORMAT || m_nFormat == CONTENTTYPE_FORMAT ) { @@ -459,25 +449,21 @@ void SAL_CALL OFOPXMLHelper_Impl::endElement( const OUString& aName ) void SAL_CALL OFOPXMLHelper_Impl::characters( const OUString& /*aChars*/ ) - throw(css::xml::sax::SAXException, uno::RuntimeException, std::exception) { } void SAL_CALL OFOPXMLHelper_Impl::ignorableWhitespace( const OUString& /*aWhitespaces*/ ) - throw(css::xml::sax::SAXException, uno::RuntimeException, std::exception) { } void SAL_CALL OFOPXMLHelper_Impl::processingInstruction( const OUString& /*aTarget*/, const OUString& /*aData*/ ) - throw(css::xml::sax::SAXException, uno::RuntimeException, std::exception) { } void SAL_CALL OFOPXMLHelper_Impl::setDocumentLocator( const uno::Reference< css::xml::sax::XLocator >& /*xLocator*/ ) - throw(css::xml::sax::SAXException, uno::RuntimeException, std::exception) { } |