summaryrefslogtreecommitdiff
path: root/vbahelper
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-01-19 17:48:05 +0100
committerStephan Bergmann <sbergman@redhat.com>2017-01-19 18:03:10 +0100
commit9439844a795e32c67bdb0b0d83f7d9c200866df4 (patch)
tree4e324d513c88a9e75bfe0d7e8e638a5b42d86125 /vbahelper
parent7c58ebaa025d6b8852608045af23239f7402a8be (diff)
New loplugin:dynexcspec: Add @throws documentation, vbahelper
Change-Id: I44f1c8f7f2ffdbd050ea219c6b89b246fcbd2473
Diffstat (limited to 'vbahelper')
-rw-r--r--vbahelper/source/msforms/vbacontrol.hxx11
-rw-r--r--vbahelper/source/msforms/vbalistcontrolhelper.hxx6
-rw-r--r--vbahelper/source/msforms/vbanewfont.hxx1
-rw-r--r--vbahelper/source/msforms/vbapages.hxx1
-rw-r--r--vbahelper/source/msforms/vbauserform.hxx2
-rw-r--r--vbahelper/source/vbahelper/vbacommandbar.hxx2
-rw-r--r--vbahelper/source/vbahelper/vbacommandbarcontrol.hxx4
-rw-r--r--vbahelper/source/vbahelper/vbacommandbarcontrols.hxx2
-rw-r--r--vbahelper/source/vbahelper/vbacommandbarhelper.hxx10
-rw-r--r--vbahelper/source/vbahelper/vbacommandbars.cxx1
-rw-r--r--vbahelper/source/vbahelper/vbacommandbars.hxx1
-rw-r--r--vbahelper/source/vbahelper/vbadocumentsbase.cxx3
-rw-r--r--vbahelper/source/vbahelper/vbafillformat.hxx2
-rw-r--r--vbahelper/source/vbahelper/vbahelper.cxx1
-rw-r--r--vbahelper/source/vbahelper/vbalineformat.hxx1
-rw-r--r--vbahelper/source/vbahelper/vbapictureformat.hxx3
16 files changed, 51 insertions, 0 deletions
diff --git a/vbahelper/source/msforms/vbacontrol.hxx b/vbahelper/source/msforms/vbacontrol.hxx
index c2ee4db8f4e9..acbe760e9f8a 100644
--- a/vbahelper/source/msforms/vbacontrol.hxx
+++ b/vbahelper/source/msforms/vbacontrol.hxx
@@ -51,6 +51,7 @@ protected:
css::uno::Reference< css::uno::XInterface > m_xControl;
css::uno::Reference< css::frame::XModel > m_xModel;
+ /// @throws css::uno::RuntimeException
css::uno::Reference< css::awt::XWindowPeer > getWindowPeer() throw (css::uno::RuntimeException);
void fireChangeEvent();
void fireClickEvent();
@@ -97,29 +98,39 @@ public:
virtual ::sal_Int32 SAL_CALL getMousePointer() throw (css::uno::RuntimeException, std::exception) override;
virtual void SAL_CALL setMousePointer( ::sal_Int32 _mousepointer ) throw (css::uno::RuntimeException, std::exception) override;
//remove resource because ooo.vba.excel.XControl is a wrapper of com.sun.star.drawing.XControlShape
+ /// @throws css::uno::RuntimeException
void removeResource() throw( css::uno::RuntimeException );
+ /// @throws css::uno::RuntimeException
virtual ::sal_Int32 SAL_CALL getForeColor() throw (css::uno::RuntimeException);
//XHelperInterface
virtual OUString getServiceImplName() override;
virtual css::uno::Sequence<OUString> getServiceNames() override;
//General helper methods for properties (may or may not be relevant for all
//controls)
+ /// @throws css::uno::RuntimeException
sal_Int32 getBackColor() throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void setBackColor( sal_Int32 nBackColor ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
bool getAutoSize() throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void setAutoSize( bool bAutoSize ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
bool getLocked() throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void setLocked( bool bAutoSize ) throw (css::uno::RuntimeException);
};
namespace ScVbaControlFactory
{
+ /// @throws css::uno::RuntimeException
css::uno::Reference< ov::msforms::XControl > createShapeControl(
const css::uno::Reference< css::uno::XComponentContext >& xContext,
const css::uno::Reference< css::drawing::XControlShape >& xControlShape,
const css::uno::Reference< css::frame::XModel >& xModel ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
css::uno::Reference< ov::msforms::XControl > createUserformControl(
const css::uno::Reference< css::uno::XComponentContext >& xContext,
const css::uno::Reference< css::awt::XControl >& xControl,
diff --git a/vbahelper/source/msforms/vbalistcontrolhelper.hxx b/vbahelper/source/msforms/vbalistcontrolhelper.hxx
index e60b52b9a133..d83734d93802 100644
--- a/vbahelper/source/msforms/vbalistcontrolhelper.hxx
+++ b/vbahelper/source/msforms/vbalistcontrolhelper.hxx
@@ -28,11 +28,17 @@ class ListControlHelper final
public:
explicit ListControlHelper( const css::uno::Reference< css::beans::XPropertySet >& rxControl ) : m_xProps( rxControl ){}
+ /// @throws css::uno::RuntimeException
void SAL_CALL AddItem( const css::uno::Any& pvargItem, const css::uno::Any& pvargIndex ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void SAL_CALL removeItem( const css::uno::Any& index ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void SAL_CALL setRowSource( const OUString& _rowsource ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
::sal_Int32 SAL_CALL getListCount() throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
css::uno::Any SAL_CALL List( const css::uno::Any& pvargIndex, const css::uno::Any& pvarColumn ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void SAL_CALL Clear( ) throw (css::uno::RuntimeException);
};
diff --git a/vbahelper/source/msforms/vbanewfont.hxx b/vbahelper/source/msforms/vbanewfont.hxx
index ceebd68c56f9..3a95c1cbc282 100644
--- a/vbahelper/source/msforms/vbanewfont.hxx
+++ b/vbahelper/source/msforms/vbanewfont.hxx
@@ -30,6 +30,7 @@ typedef cppu::WeakImplHelper< ov::msforms::XNewFont > VbaNewFont_BASE;
class VbaNewFont : public VbaNewFont_BASE
{
public:
+ /// @throws css::uno::RuntimeException
explicit VbaNewFont(
const css::uno::Reference< css::beans::XPropertySet >& rxModelProps ) throw (css::uno::RuntimeException);
diff --git a/vbahelper/source/msforms/vbapages.hxx b/vbahelper/source/msforms/vbapages.hxx
index c3906dde4085..b71da38d9d10 100644
--- a/vbahelper/source/msforms/vbapages.hxx
+++ b/vbahelper/source/msforms/vbapages.hxx
@@ -34,6 +34,7 @@ protected:
virtual OUString getServiceImplName() override;
virtual css::uno::Sequence<OUString> getServiceNames() override;
public:
+ /// @throws css::lang::IllegalArgumentException
ScVbaPages( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::container::XIndexAccess >& xPages ) throw ( css::lang::IllegalArgumentException );
virtual ~ScVbaPages() override {}
// XEnumerationAccess
diff --git a/vbahelper/source/msforms/vbauserform.hxx b/vbahelper/source/msforms/vbauserform.hxx
index ce249bc95071..8bf1586e833a 100644
--- a/vbahelper/source/msforms/vbauserform.hxx
+++ b/vbahelper/source/msforms/vbauserform.hxx
@@ -39,6 +39,8 @@ private:
OUString m_sLibName;
protected:
public:
+ /// @throws css::lang::IllegalArgumentException
+ /// @throws css::uno::RuntimeException
ScVbaUserForm( css::uno::Sequence< css::uno::Any > const& aArgs, css::uno::Reference< css::uno::XComponentContext >const& xContext ) throw ( css::lang::IllegalArgumentException, css::uno::RuntimeException );
virtual ~ScVbaUserForm() override;
static css::uno::Reference< css::awt::XControl > nestedSearch( const OUString& aPropertyName, css::uno::Reference< css::awt::XControlContainer >& xContainer );
diff --git a/vbahelper/source/vbahelper/vbacommandbar.hxx b/vbahelper/source/vbahelper/vbacommandbar.hxx
index 5c66988fb407..8510abf5ba83 100644
--- a/vbahelper/source/vbahelper/vbacommandbar.hxx
+++ b/vbahelper/source/vbahelper/vbacommandbar.hxx
@@ -39,6 +39,7 @@ private:
bool m_bIsMenu;
public:
+ /// @throws css::uno::RuntimeException
ScVbaCommandBar( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, VbaCommandBarHelperRef const & pHelper, const css::uno::Reference< css::container::XIndexAccess >& xBarSettings, const OUString& sResourceUrl, bool bIsMenu ) throw( css::uno::RuntimeException );
// Attributes
@@ -64,6 +65,7 @@ public:
class VbaDummyCommandBar : public CommandBar_BASE
{
public:
+ /// @throws css::uno::RuntimeException
VbaDummyCommandBar(
const css::uno::Reference< ov::XHelperInterface >& xParent,
const css::uno::Reference< css::uno::XComponentContext >& xContext,
diff --git a/vbahelper/source/vbahelper/vbacommandbarcontrol.hxx b/vbahelper/source/vbahelper/vbacommandbarcontrol.hxx
index eeeb1aafbb23..2033fe40912b 100644
--- a/vbahelper/source/vbahelper/vbacommandbarcontrol.hxx
+++ b/vbahelper/source/vbahelper/vbacommandbarcontrol.hxx
@@ -43,9 +43,11 @@ protected:
bool m_bTemporary;
private:
+ /// @throws css::uno::RuntimeException
void ApplyChange() throw (css::uno::RuntimeException);
public:
+ /// @throws css::uno::RuntimeException
ScVbaCommandBarControl( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::container::XIndexAccess >& xSettings, const VbaCommandBarHelperRef& pHelper, const css::uno::Reference< css::container::XIndexAccess >& xBarSettings, const OUString& sResourceUrl ) throw (css::uno::RuntimeException);
// Attributes
@@ -77,6 +79,7 @@ typedef cppu::ImplInheritanceHelper< ScVbaCommandBarControl, ov::XCommandBarPopu
class ScVbaCommandBarPopup : public CommandBarPopup_BASE
{
public:
+ /// @throws css::uno::RuntimeException
ScVbaCommandBarPopup( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::container::XIndexAccess >& xSettings, const VbaCommandBarHelperRef& pHelper, const css::uno::Reference< css::container::XIndexAccess >& xBarSettings, const OUString& sResourceUrl, sal_Int32 nPosition, bool bTemporary ) throw (css::uno::RuntimeException);
virtual sal_Int32 SAL_CALL getType() throw (css::uno::RuntimeException, std::exception) override
@@ -92,6 +95,7 @@ typedef cppu::ImplInheritanceHelper< ScVbaCommandBarControl, ov::XCommandBarButt
class ScVbaCommandBarButton : public CommandBarButton_BASE
{
public:
+ /// @throws css::uno::RuntimeException
ScVbaCommandBarButton( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::container::XIndexAccess >& xSettings, const VbaCommandBarHelperRef& pHelper, const css::uno::Reference< css::container::XIndexAccess >& xBarSettings, const OUString& sResourceUrl, sal_Int32 nPosition, bool bTemporary ) throw (css::uno::RuntimeException);
virtual sal_Int32 SAL_CALL getType() throw (css::uno::RuntimeException, std::exception) override
diff --git a/vbahelper/source/vbahelper/vbacommandbarcontrols.hxx b/vbahelper/source/vbahelper/vbacommandbarcontrols.hxx
index 28ec91fdb29e..e329a1d00988 100644
--- a/vbahelper/source/vbahelper/vbacommandbarcontrols.hxx
+++ b/vbahelper/source/vbahelper/vbacommandbarcontrols.hxx
@@ -45,6 +45,7 @@ private:
static css::uno::Sequence< css::beans::PropertyValue > CreateToolbarItemData( const OUString& sCommandURL, const OUString& sHelpURL, const OUString& sLabel, sal_uInt16 nType, const css::uno::Any& aSubMenu, bool isVisible, sal_Int32 nStyle );
public:
+ /// @throws css::uno::RuntimeException
ScVbaCommandBarControls( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::container::XIndexAccess >& xIndexAccess, VbaCommandBarHelperRef const & pHelper, const css::uno::Reference< css::container::XIndexAccess >& xBarSettings, const OUString& sResourceUrl ) throw( css::uno::RuntimeException );
// XEnumerationAccess
@@ -63,6 +64,7 @@ public:
class VbaDummyCommandBarControls : public CommandBarControls_BASE
{
public:
+ /// @throws css::uno::RuntimeException
VbaDummyCommandBarControls(
const css::uno::Reference< ov::XHelperInterface >& xParent,
const css::uno::Reference< css::uno::XComponentContext >& xContext ) throw( css::uno::RuntimeException );
diff --git a/vbahelper/source/vbahelper/vbacommandbarhelper.hxx b/vbahelper/source/vbahelper/vbacommandbarhelper.hxx
index 43f2f80e69c8..a06b2887f0e0 100644
--- a/vbahelper/source/vbahelper/vbacommandbarhelper.hxx
+++ b/vbahelper/source/vbahelper/vbacommandbarhelper.hxx
@@ -58,25 +58,35 @@ private:
css::uno::Reference< css::container::XNameAccess > m_xWindowState;
OUString maModuleId;
+ /// @throws css::uno::RuntimeException
void Init() throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
bool hasToolbar( const OUString& sResourceUrl, const OUString& sName ) throw (css::uno::RuntimeException);
public:
+ /// @throws css::uno::RuntimeException
VbaCommandBarHelper( const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::frame::XModel >& xModel ) throw( css::uno::RuntimeException );
const css::uno::Reference< css::frame::XModel >& getModel() const { return mxModel; }
+ /// @throws css::uno::RuntimeException
const css::uno::Reference< css::container::XNameAccess >& getPersistentWindowState() const throw (css::uno::RuntimeException)
{
return m_xWindowState;
}
+ /// @throws css::uno::RuntimeException
css::uno::Reference< css::container::XIndexAccess > getSettings( const OUString& sResourceUrl ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void removeSettings( const OUString& sResourceUrl ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
void ApplyTempChange( const OUString& sResourceUrl, const css::uno::Reference< css::container::XIndexAccess >& xSettings) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
css::uno::Reference< css::frame::XLayoutManager > getLayoutManager() throw (css::uno::RuntimeException);
const OUString& getModuleId() const { return maModuleId; }
+ /// @throws css::uno::RuntimeException
OUString findToolbarByName( const css::uno::Reference< css::container::XNameAccess >& xNameAccess, const OUString& sName ) throw (css::uno::RuntimeException);
+ /// @throws css::uno::RuntimeException
static sal_Int32 findControlByName( const css::uno::Reference< css::container::XIndexAccess >& xIndexAccess, const OUString& sName, bool bMenu ) throw (css::uno::RuntimeException);
static OUString generateCustomURL();
};
diff --git a/vbahelper/source/vbahelper/vbacommandbars.cxx b/vbahelper/source/vbahelper/vbacommandbars.cxx
index 33ca3d3243f9..e22c524b1237 100644
--- a/vbahelper/source/vbahelper/vbacommandbars.cxx
+++ b/vbahelper/source/vbahelper/vbacommandbars.cxx
@@ -41,6 +41,7 @@ class CommandBarEnumeration : public ::cppu::WeakImplHelper< container::XEnumera
uno::Sequence< OUString > m_sNames;
sal_Int32 m_nCurrentPosition;
public:
+ /// @throws uno::RuntimeException
CommandBarEnumeration( const uno::Reference< XHelperInterface >& xParent, const uno::Reference< uno::XComponentContext >& xContext, const VbaCommandBarHelperRef& pHelper) throw ( uno::RuntimeException ) : m_xParent( xParent ), m_xContext( xContext ), m_pCBarHelper( pHelper ) , m_nCurrentPosition( 0 )
{
uno::Reference< container::XNameAccess > xNameAccess = m_pCBarHelper->getPersistentWindowState();
diff --git a/vbahelper/source/vbahelper/vbacommandbars.hxx b/vbahelper/source/vbahelper/vbacommandbars.hxx
index cb5e57fbed95..2c3fca4b5c82 100644
--- a/vbahelper/source/vbahelper/vbacommandbars.hxx
+++ b/vbahelper/source/vbahelper/vbacommandbars.hxx
@@ -34,6 +34,7 @@ private:
VbaCommandBarHelperRef m_pCBarHelper;
public:
+ /// @throws css::uno::RuntimeException
ScVbaCommandBars( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::container::XIndexAccess >& xIndexAccess, const css::uno::Reference< css::frame::XModel >& xModel ) throw (css::uno::RuntimeException);
virtual ~ScVbaCommandBars() override;
diff --git a/vbahelper/source/vbahelper/vbadocumentsbase.cxx b/vbahelper/source/vbahelper/vbadocumentsbase.cxx
index 28169927e813..10bfe880adcc 100644
--- a/vbahelper/source/vbahelper/vbadocumentsbase.cxx
+++ b/vbahelper/source/vbahelper/vbadocumentsbase.cxx
@@ -70,10 +70,12 @@ class DocumentsEnumImpl : public ::cppu::WeakImplHelper< container::XEnumeration
Documents::const_iterator m_it;
public:
+ /// @throws uno::RuntimeException
DocumentsEnumImpl( const uno::Reference< uno::XComponentContext >& xContext, const Documents& docs ) throw ( uno::RuntimeException ) : m_xContext( xContext ), m_documents( docs )
{
m_it = m_documents.begin();
}
+ /// @throws uno::RuntimeException
explicit DocumentsEnumImpl( const uno::Reference< uno::XComponentContext >& xContext ) throw ( uno::RuntimeException ) : m_xContext( xContext )
{
uno::Reference< frame::XDesktop2 > xDesktop = frame::Desktop::create( m_xContext );
@@ -120,6 +122,7 @@ class DocumentsAccessImpl : public DocumentsAccessImpl_BASE
NameIndexHash namesToIndices;
VbaDocumentsBase::DOCUMENT_TYPE meDocType;
public:
+ /// @throws uno::RuntimeException
DocumentsAccessImpl( const uno::Reference< uno::XComponentContext >& xContext, VbaDocumentsBase::DOCUMENT_TYPE eDocType ) throw (uno::RuntimeException, std::exception) :m_xContext( xContext ), meDocType( eDocType )
{
uno::Reference< container::XEnumeration > xEnum = new DocumentsEnumImpl( m_xContext );
diff --git a/vbahelper/source/vbahelper/vbafillformat.hxx b/vbahelper/source/vbahelper/vbafillformat.hxx
index ed9b1192c1ec..8789560e18ee 100644
--- a/vbahelper/source/vbahelper/vbafillformat.hxx
+++ b/vbahelper/source/vbahelper/vbafillformat.hxx
@@ -36,6 +36,7 @@ private:
sal_Int32 m_nForeColor;
sal_Int16 m_nGradientAngle;
private:
+ /// @throws css::uno::RuntimeException
void setFillStyle( css::drawing::FillStyle nFillStyle ) throw (css::uno::RuntimeException);
protected:
virtual OUString getServiceImplName() override;
@@ -44,6 +45,7 @@ protected:
public:
ScVbaFillFormat( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::drawing::XShape >& xShape );
+ /// @throws css::uno::RuntimeException
void setForeColorAndInternalStyle( sal_Int32 nForeColor ) throw (css::uno::RuntimeException);
// Attributes
virtual sal_Bool SAL_CALL getVisible() throw (css::uno::RuntimeException, std::exception) override;
diff --git a/vbahelper/source/vbahelper/vbahelper.cxx b/vbahelper/source/vbahelper/vbahelper.cxx
index 598907a5d575..a1a30d1b43c7 100644
--- a/vbahelper/source/vbahelper/vbahelper.cxx
+++ b/vbahelper/source/vbahelper/vbahelper.cxx
@@ -234,6 +234,7 @@ getCurrentDoc( const OUString& sKey ) throw (uno::RuntimeException)
return xModel;
}
+/// @throws uno::RuntimeException
uno::Reference< frame::XModel >
getCurrentDocCtx( const OUString& ctxName, const uno::Reference< uno::XComponentContext >& xContext ) throw (uno::RuntimeException)
{
diff --git a/vbahelper/source/vbahelper/vbalineformat.hxx b/vbahelper/source/vbahelper/vbalineformat.hxx
index 3154b32f7c2c..eca78e8d4105 100644
--- a/vbahelper/source/vbahelper/vbalineformat.hxx
+++ b/vbahelper/source/vbahelper/vbalineformat.hxx
@@ -37,6 +37,7 @@ protected:
virtual OUString getServiceImplName() override;
virtual css::uno::Sequence<OUString> getServiceNames() override;
static sal_Int32 convertLineStartEndNameToArrowheadStyle( const OUString& sLineName );
+ /// @throws css::uno::RuntimeException
static OUString convertArrowheadStyleToLineStartEndName( sal_Int32 nArrowheadStyle ) throw (css::uno::RuntimeException);
public:
ScVbaLineFormat( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::drawing::XShape >& xShape );
diff --git a/vbahelper/source/vbahelper/vbapictureformat.hxx b/vbahelper/source/vbahelper/vbapictureformat.hxx
index b7d54e83c8b3..73cb5e98a355 100644
--- a/vbahelper/source/vbahelper/vbapictureformat.hxx
+++ b/vbahelper/source/vbahelper/vbapictureformat.hxx
@@ -35,8 +35,11 @@ protected:
virtual OUString getServiceImplName() override;
virtual css::uno::Sequence<OUString> getServiceNames() override;
private:
+ /// @throws css::uno::RuntimeException
static void checkParameterRangeInDouble( double nRange, double nMin, double nMax ) throw (css::uno::RuntimeException);
public:
+ /// @throws css::lang::IllegalArgumentException
+ /// @throws css::uno::RuntimeException
ScVbaPictureFormat( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, css::uno::Reference< css::drawing::XShape > const & xShape )
throw (css::lang::IllegalArgumentException, css::uno::RuntimeException);